feat: 门店评价
This commit is contained in:
@@ -23,7 +23,7 @@
|
|||||||
</ai-select>
|
</ai-select>
|
||||||
<ai-search label="录入时间">
|
<ai-search label="录入时间">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
v-model="search.createTime"
|
v-model="search.startTime"
|
||||||
type="date"
|
type="date"
|
||||||
size="small"
|
size="small"
|
||||||
value-format="yyyy-MM-dd"
|
value-format="yyyy-MM-dd"
|
||||||
@@ -31,7 +31,7 @@
|
|||||||
@change="search.current = 1, getList()">
|
@change="search.current = 1, getList()">
|
||||||
</el-date-picker>
|
</el-date-picker>
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
v-model="search.createTimeEnd"
|
v-model="search.endTime"
|
||||||
type="date"
|
type="date"
|
||||||
size="small"
|
size="small"
|
||||||
value-format="yyyy-MM-dd"
|
value-format="yyyy-MM-dd"
|
||||||
@@ -179,7 +179,7 @@ export default {
|
|||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
handleSelectionChange(e) {
|
handleSelectionChange(e) {
|
||||||
this.ids = e
|
this.ids = e.map(v=>v.id)
|
||||||
},
|
},
|
||||||
|
|
||||||
handleAdd() {
|
handleAdd() {
|
||||||
|
|||||||
@@ -76,7 +76,43 @@ export default {
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
created() {
|
||||||
|
this.getDetail()
|
||||||
|
this.getScoredetail()
|
||||||
|
},
|
||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
|
async getScoredetail(){
|
||||||
|
try {
|
||||||
|
const {code,data} = await this.instance.post('/app/appscoredetails/queryDetailById',null,{
|
||||||
|
params:{
|
||||||
|
id:this.params.id
|
||||||
|
}
|
||||||
|
})
|
||||||
|
if(code===0){
|
||||||
|
console.log('data',data)
|
||||||
|
}
|
||||||
|
}catch (e) {
|
||||||
|
console.error(e)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
async getDetail(){
|
||||||
|
try {
|
||||||
|
const {code,data} = await this.instance.post('/app/appshopassess/queryDetailById',null,{
|
||||||
|
params:{
|
||||||
|
id:this.params.id
|
||||||
|
}
|
||||||
|
})
|
||||||
|
if(code===0){
|
||||||
|
this.info = data
|
||||||
|
}
|
||||||
|
}catch (e) {
|
||||||
|
console.error(e)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
cancel() {
|
cancel() {
|
||||||
this.$emit('change', {
|
this.$emit('change', {
|
||||||
type: 'List',
|
type: 'List',
|
||||||
|
|||||||
@@ -8,20 +8,14 @@
|
|||||||
<template #left>
|
<template #left>
|
||||||
<el-input placeholder="请输入门店名称" size="small" clearable></el-input>
|
<el-input placeholder="请输入门店名称" size="small" clearable></el-input>
|
||||||
<ai-select
|
<ai-select
|
||||||
v-model="search.applyItemId"
|
v-model="search.shopName"
|
||||||
@change="(search.current = 1), getList()"
|
@change="(search.current = 1), getList()"
|
||||||
placeholder="评价人员类型"
|
placeholder="评价人员类型"
|
||||||
:selectList="dictList">
|
:selectList="[]">
|
||||||
</ai-select>
|
|
||||||
<ai-select
|
|
||||||
v-model="search.applyItemId"
|
|
||||||
@change="(search.current = 1), getList()"
|
|
||||||
placeholder="所属片区"
|
|
||||||
:selectList="dictList">
|
|
||||||
</ai-select>
|
</ai-select>
|
||||||
<ai-search label="评价时间">
|
<ai-search label="评价时间">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
v-model="search.createTimeStart"
|
v-model="search.startTime"
|
||||||
type="date"
|
type="date"
|
||||||
size="small"
|
size="small"
|
||||||
value-format="yyyy-MM-dd"
|
value-format="yyyy-MM-dd"
|
||||||
@@ -29,7 +23,7 @@
|
|||||||
@change="search.current = 1, getList()">
|
@change="search.current = 1, getList()">
|
||||||
</el-date-picker>
|
</el-date-picker>
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
v-model="search.createTimeEnd"
|
v-model="search.endTime"
|
||||||
type="date"
|
type="date"
|
||||||
size="small"
|
size="small"
|
||||||
value-format="yyyy-MM-dd"
|
value-format="yyyy-MM-dd"
|
||||||
@@ -65,7 +59,7 @@
|
|||||||
</ai-search-bar>
|
</ai-search-bar>
|
||||||
<ai-search-bar class="search-bar">
|
<ai-search-bar class="search-bar">
|
||||||
<template #left>
|
<template #left>
|
||||||
<el-button icon="iconfont iconDelete" @click="handleDelBatch">删除</el-button>
|
<el-button icon="iconfont iconDelete" @click="handleDelete" :disabled="!ids.length">删除</el-button>
|
||||||
</template>
|
</template>
|
||||||
<template #right>
|
<template #right>
|
||||||
<ai-download :instance="instance" url="/app/appintegraluser/girdIntegralExport" :params="search" fileName="门店评价"
|
<ai-download :instance="instance" url="/app/appintegraluser/girdIntegralExport" :params="search" fileName="门店评价"
|
||||||
@@ -79,6 +73,7 @@
|
|||||||
:total="total"
|
:total="total"
|
||||||
style="margin-top: 6px;"
|
style="margin-top: 6px;"
|
||||||
:current.sync="search.current"
|
:current.sync="search.current"
|
||||||
|
@handleSelectionChange="handleSelectionChange"
|
||||||
:size.sync="search.size"
|
:size.sync="search.size"
|
||||||
@getList="getList">
|
@getList="getList">
|
||||||
|
|
||||||
@@ -86,7 +81,7 @@
|
|||||||
<template slot-scope="{ row }">
|
<template slot-scope="{ row }">
|
||||||
<div class="table-options">
|
<div class="table-options">
|
||||||
<el-button type="text" @click="toDetail(row)">详情</el-button>
|
<el-button type="text" @click="toDetail(row)">详情</el-button>
|
||||||
<el-button type="text" @click="handleDelete(row)">删除</el-button>
|
<el-button type="text" @click="handleDelete(row.id)">删除</el-button>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
@@ -96,7 +91,6 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { MessageBox } from 'element-ui'
|
|
||||||
import { mapState } from 'vuex'
|
import { mapState } from 'vuex'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
@@ -111,26 +105,20 @@ export default {
|
|||||||
search: {
|
search: {
|
||||||
current: 1,
|
current: 1,
|
||||||
size: 10,
|
size: 10,
|
||||||
areaId: '',
|
shopName:''
|
||||||
applyItemId: '',
|
|
||||||
girdId: '',
|
|
||||||
createTimeStart: '',
|
|
||||||
createTimeEnd: '',
|
|
||||||
girdName: ''
|
|
||||||
},
|
},
|
||||||
userList: [],
|
|
||||||
dictList: [],
|
|
||||||
total: 10,
|
total: 10,
|
||||||
|
ids:[],
|
||||||
colConfigs: [
|
colConfigs: [
|
||||||
{type: "selection"},
|
{type: "selection"},
|
||||||
{ prop: 'integralUserName', label: '门店名称', align: 'center' },
|
{ prop: 'shopName', label: '门店名称', align: 'center' },
|
||||||
{ prop: 'areaName', label: '评价人', align: 'center' },
|
{ prop: 'evaluator', label: '评价人', align: 'center' },
|
||||||
{ prop: 'girdName', label: '评价时间', align: 'center' },
|
{ prop: 'evaluationTime', label: '评价时间', align: 'center' },
|
||||||
{ prop: 'createTime', label: '联系电话', align: 'center' },
|
{ prop: 'evaluatorPhone', label: '联系电话', align: 'center' },
|
||||||
{ prop: 'status', label: '评价人类型', align: 'center'},
|
{ prop: 'evaluatorType', label: '评价人类型', align: 'center'},
|
||||||
{ prop: 'auditUserName', label: '评价类型', align: 'center' },
|
{ prop: 'assessType', label: '评价类型', align: 'center' },
|
||||||
{ prop: 'auditUserName', label: '门店地址', align: 'center' },
|
{ prop: 'address', label: '门店地址', align: 'center' },
|
||||||
{ prop: 'auditUserName', label: '分数', align: 'center' },
|
{ prop: 'score', label: '分数', align: 'center' },
|
||||||
],
|
],
|
||||||
tableData: [],
|
tableData: [],
|
||||||
dateList: []
|
dateList: []
|
||||||
@@ -146,13 +134,16 @@ export default {
|
|||||||
|
|
||||||
created () {
|
created () {
|
||||||
this.search.areaId = this.user.info.areaId
|
this.search.areaId = this.user.info.areaId
|
||||||
this.$dict.load('appIntegralApplyEventStatus', 'appIntegralApplyEventPushStatus').then(() => {
|
this.$dict.load().then(() => {
|
||||||
this.getList()
|
this.getList()
|
||||||
this.getRulesList()
|
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
|
handleSelectionChange(e) {
|
||||||
|
this.ids = e.map(v=>v.id)
|
||||||
|
},
|
||||||
|
|
||||||
handleAdd(){
|
handleAdd(){
|
||||||
this.$emit('change', {
|
this.$emit('change', {
|
||||||
type: 'Add',
|
type: 'Add',
|
||||||
@@ -160,25 +151,8 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
handleDelBatch(){
|
|
||||||
|
|
||||||
},
|
|
||||||
|
|
||||||
getRulesList () {
|
|
||||||
this.instance.post(`/app/appintegralrule/listByAppletFD?current=1&size=3000`).then((res) => {
|
|
||||||
if (res.code === 0) {
|
|
||||||
this.dictList = res.data.records.map(v => {
|
|
||||||
return {
|
|
||||||
dictName: v.ruleName,
|
|
||||||
dictValue: v.id
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
|
||||||
|
|
||||||
getList () {
|
getList () {
|
||||||
this.instance.post(`/app/appintegraluserapply/list`, null, {
|
this.instance.post(`/app/appshopassess/list`, null, {
|
||||||
params: {
|
params: {
|
||||||
...this.search
|
...this.search
|
||||||
}
|
}
|
||||||
@@ -190,51 +164,6 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
changeArea () {
|
|
||||||
this.search.current = 1
|
|
||||||
|
|
||||||
this.$nextTick(() => {
|
|
||||||
this.getList()
|
|
||||||
})
|
|
||||||
},
|
|
||||||
|
|
||||||
push (id) {
|
|
||||||
MessageBox.confirm('是否将精选内容对全体居民公开,选则否将只对本村/社区居民公开。', '推送精选', {
|
|
||||||
distinguishCancelAndClose: true,
|
|
||||||
confirmButtonText: '是',
|
|
||||||
type: 'warning',
|
|
||||||
closeOnClickModal: false,
|
|
||||||
center: true,
|
|
||||||
customClass: 'AiConfirm',
|
|
||||||
cancelButtonText: '否'
|
|
||||||
}).then(() => {
|
|
||||||
this.instance.post(`/app/appintegraluserapply/pushById?id=${id}&status=1`).then(res => {
|
|
||||||
if (res.code == 0) {
|
|
||||||
this.getList()
|
|
||||||
this.$message.success('推送成功')
|
|
||||||
}
|
|
||||||
})
|
|
||||||
}).catch((e) => {
|
|
||||||
e === 'cancel' && this.instance.post(`/app/appintegraluserapply/pushById?id=${id}&status=0`).then(res => {
|
|
||||||
if (res.code == 0) {
|
|
||||||
this.getList()
|
|
||||||
this.$message.success('推送成功')
|
|
||||||
}
|
|
||||||
})
|
|
||||||
})
|
|
||||||
},
|
|
||||||
|
|
||||||
remove (id) {
|
|
||||||
this.$confirm('确定删除该帖子?').then((e) => {
|
|
||||||
this.instance.post(`/app/appintegraluserapply/delete?id=${id}`).then(res => {
|
|
||||||
if (res.code == 0) {
|
|
||||||
this.$message.success('删除成功!')
|
|
||||||
this.getList()
|
|
||||||
}
|
|
||||||
})
|
|
||||||
})
|
|
||||||
},
|
|
||||||
|
|
||||||
toDetail ({id}) {
|
toDetail ({id}) {
|
||||||
this.$emit('change', {
|
this.$emit('change', {
|
||||||
type: 'Detail',
|
type: 'Detail',
|
||||||
@@ -253,9 +182,21 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
handleDelete({id}){
|
handleDelete(ids=this.ids.join(',')){
|
||||||
this.$confirm('确定删除该数据?').then(() => {
|
this.$confirm('确定删除该数据?').then(async () => {
|
||||||
console.log(id)
|
try {
|
||||||
|
const {code} = await this.instance.post('/app/appshopassess/delete',null,{
|
||||||
|
params:{
|
||||||
|
ids
|
||||||
|
}
|
||||||
|
})
|
||||||
|
if(code===0){
|
||||||
|
this.$message.success('删除成功')
|
||||||
|
this.getList()
|
||||||
|
}
|
||||||
|
}catch (e) {
|
||||||
|
console.error(e)
|
||||||
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user