|
|
@ -5,10 +5,10 @@ |
|
|
|
<!-- <el-form-item> |
|
|
|
<el-input v-model="dataForm.id" placeholder="id" clearable></el-input> |
|
|
|
</el-form-item>--> |
|
|
|
<el-form-item> |
|
|
|
<el-form-item label="用户昵称"> |
|
|
|
<el-input v-model="dataForm.userName" placeholder="用户昵称" clearable></el-input> |
|
|
|
</el-form-item> |
|
|
|
<el-form-item> |
|
|
|
<el-form-item label="留言内容"> |
|
|
|
<el-input v-model="dataForm.messageContent" placeholder="留言内容" clearable></el-input> |
|
|
|
</el-form-item> |
|
|
|
<el-form-item> |
|
|
@ -26,39 +26,18 @@ |
|
|
|
</el-form-item> |
|
|
|
</el-form> |
|
|
|
<el-table v-loading="dataListLoading" :data="dataList" border @selection-change="dataListSelectionChangeHandle" style="width: 100%;"> |
|
|
|
<el-table-column type="selection" header-align="center" align="center" width="50"></el-table-column> |
|
|
|
<el-table-column prop="userName" label="用户昵称" header-align="center" align="center"></el-table-column> |
|
|
|
<el-table-column prop="messageContent" label="留言内容" header-align="center" align="center"></el-table-column> |
|
|
|
<el-table-column prop="img" label="用户头像" header-align="center" align="center"></el-table-column> |
|
|
|
<el-table-column type="index" width="50" label="序号" align="center"></el-table-column> |
|
|
|
<el-table-column prop="userName" label="用户昵称" header-align="center" align="center" show-overflow-tooltip></el-table-column> |
|
|
|
<el-table-column prop="messageContent" label="留言内容" header-align="center" align="center" show-overflow-tooltip></el-table-column> |
|
|
|
<!--<el-table-column prop="img" label="用户头像" header-align="center" align="center" show-overflow-tooltip></el-table-column>--> |
|
|
|
<el-table-column prop="auditIdentification" label="审核状态" header-align="center" align="center"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
{{ scope.row.auditIdentification === '1'? '待审核':scope.row.auditIdentification === '2'?'审核通过':"审核未通过" }} |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<!-- <el-table-column prop="delFlag" label="删除标识 0-否,1-是" header-align="center" align="center"></el-table-column> |
|
|
|
<el-table-column prop="auditIdentification" label="审核标识(1:待审核;2:通过;3:未通过)" header-align="center" align="center"></el-table-column> |
|
|
|
<el-table-column prop="revision" label="乐观锁" header-align="center" align="center"></el-table-column> |
|
|
|
<el-table-column prop="id" label="主键" header-align="center" align="center"></el-table-column> |
|
|
|
<el-table-column prop="userId" label="留言用户ID" header-align="center" align="center"></el-table-column> |
|
|
|
<el-table-column prop="createdBy" label="创建人" header-align="center" align="center"></el-table-column> |
|
|
|
<el-table-column prop="createdTime" label="创建时间" header-align="center" align="center"></el-table-column> |
|
|
|
<el-table-column prop="updatedBy" label="更新人" header-align="center" align="center"></el-table-column> |
|
|
|
<el-table-column prop="updatedTime" label="更新时间" header-align="center" align="center"></el-table-column>--> |
|
|
|
<el-table-column :label="$t('handle')" fixed="right" header-align="center" align="center" width="150"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<!-- v-if="$hasPermission('custom:servesuggestedmessage:update')" --> |
|
|
|
<!-- <el-button type="text" size="small" @click="addOrUpdateHandle(scope.row.id)">{{ $t('update') }}</el-button>--> |
|
|
|
<el-popconfirm |
|
|
|
confirm-button-text='通过' |
|
|
|
cancel-button-text='不通过' |
|
|
|
@confirm="toExamine(scope.row.id,2)" |
|
|
|
@cancel="toExamine(scope.row.id,3)" |
|
|
|
icon="el-icon-info" |
|
|
|
icon-color="red" |
|
|
|
title="请审核本条留言" |
|
|
|
> |
|
|
|
<el-button type="text" size="small" slot="reference" style="margin-right: 10px">审核</el-button> |
|
|
|
</el-popconfirm> |
|
|
|
<el-button type="text" size="small" :disabled="scope.row.auditIdentification !== '1'" @click="check(scope.row.id)" style="margin-right: 10px">审核</el-button> |
|
|
|
<el-button type="text" size="small" @click="deleteHandle(scope.row.id)">{{ $t('delete') }}</el-button> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
@ -74,6 +53,20 @@ |
|
|
|
</el-pagination> |
|
|
|
<!-- 弹窗, 新增 / 修改 --> |
|
|
|
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="getDataList"></add-or-update> |
|
|
|
<el-dialog title="审核操作" :visible.sync="dialogFormVisible"> |
|
|
|
<el-form :model="form"> |
|
|
|
<el-form-item label="审核" label-width="120px"> |
|
|
|
<el-select v-model="form.auditIdentification" placeholder="请选择审核项"> |
|
|
|
<el-option label="通过" value="2"></el-option> |
|
|
|
<el-option label="不通过" value="3"></el-option> |
|
|
|
</el-select> |
|
|
|
</el-form-item> |
|
|
|
</el-form> |
|
|
|
<div slot="footer" class="dialog-footer"> |
|
|
|
<el-button @click="dialogFormVisible = false">取 消</el-button> |
|
|
|
<el-button type="primary" @click="toExamine()">确 定</el-button> |
|
|
|
</div> |
|
|
|
</el-dialog> |
|
|
|
</div> |
|
|
|
</el-card> |
|
|
|
</template> |
|
|
@ -93,6 +86,11 @@ export default { |
|
|
|
}, |
|
|
|
dataForm: { |
|
|
|
id: '' |
|
|
|
}, |
|
|
|
dialogFormVisible: false, |
|
|
|
form: { |
|
|
|
id: '', |
|
|
|
auditIdentification: '2' |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
@ -100,16 +98,16 @@ export default { |
|
|
|
AddOrUpdate |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
toExamine(rowId,auditIdentification){ |
|
|
|
console.log(rowId) |
|
|
|
let params= { |
|
|
|
id:rowId, |
|
|
|
auditIdentification:auditIdentification, |
|
|
|
} |
|
|
|
this.$http.put('/custom/servesuggestedmessage',params).then(({ data: res })=>{ |
|
|
|
check (id) { |
|
|
|
this.form.id = id |
|
|
|
this.dialogFormVisible = true |
|
|
|
}, |
|
|
|
toExamine () { |
|
|
|
this.$http.put('/custom/servesuggestedmessage', this.form).then(({ data: res }) => { |
|
|
|
if (res.code === 0) { |
|
|
|
this.dialogFormVisible = false |
|
|
|
this.getDataList() |
|
|
|
}else { |
|
|
|
} else { |
|
|
|
return this.$message.error(res.msg) |
|
|
|
} |
|
|
|
}) |
|
|
|