|
|
|
@ -80,44 +80,45 @@
|
|
|
|
|
<div class="avue-crud__header"> |
|
|
|
|
<!-- 头部左侧按钮模块 --> |
|
|
|
|
<div class="avue-crud__left"> |
|
|
|
|
<el-button |
|
|
|
|
type="primary" |
|
|
|
|
@click="AddInfo" |
|
|
|
|
v-if="ButtonPermissions.add" |
|
|
|
|
> |
|
|
|
|
<!-- v-if="ButtonPermissions.add" --> |
|
|
|
|
<el-button type="primary" @click="AddInfo"> |
|
|
|
|
<el-icon><Plus /></el-icon>新 增</el-button |
|
|
|
|
> |
|
|
|
|
<!-- <el-button type="primary" @click="BatchDelete"> |
|
|
|
|
<el-icon><Delete /></el-icon>批量删除</el-button |
|
|
|
|
> --> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!-- v-if="ButtonPermissions.batchReject" --> |
|
|
|
|
<el-button |
|
|
|
|
type="primary" |
|
|
|
|
@click="BatchReturn" |
|
|
|
|
v-if="ButtonPermissions.batchReject" |
|
|
|
|
|
|
|
|
|
>批量打回</el-button |
|
|
|
|
> |
|
|
|
|
<el-button |
|
|
|
|
type="primary" |
|
|
|
|
@click="assign" |
|
|
|
|
v-if="ButtonPermissions.assignment" |
|
|
|
|
<!-- v-if="ButtonPermissions.assignment" --> |
|
|
|
|
<el-button type="primary" @click="assign" |
|
|
|
|
>工单指派</el-button |
|
|
|
|
> |
|
|
|
|
|
|
|
|
|
<!-- v-if="ButtonPermissions.applyArbitration" --> |
|
|
|
|
<el-button |
|
|
|
|
type="primary" |
|
|
|
|
@click="arbitrate" |
|
|
|
|
v-if="ButtonPermissions.applyArbitration" |
|
|
|
|
|
|
|
|
|
>申请仲裁</el-button |
|
|
|
|
> |
|
|
|
|
|
|
|
|
|
<!-- v-if="ButtonPermissions.batchFinish" --> |
|
|
|
|
<el-button |
|
|
|
|
type="primary" |
|
|
|
|
@click="Batchcompletion" |
|
|
|
|
v-if="ButtonPermissions.batchFinish" |
|
|
|
|
|
|
|
|
|
>批量完结</el-button |
|
|
|
|
> |
|
|
|
|
<el-button |
|
|
|
|
type="primary" |
|
|
|
|
@click="appeal" |
|
|
|
|
v-if="ButtonPermissions.appeal" |
|
|
|
|
|
|
|
|
|
<!-- v-if="ButtonPermissions.appeal" --> |
|
|
|
|
<el-button type="primary" @click="appeal" |
|
|
|
|
>申诉</el-button |
|
|
|
|
> |
|
|
|
|
<!-- v-if="details.query.workOrderStatus == 30" --> |
|
|
|
@ -154,11 +155,11 @@
|
|
|
|
|
@selection="selectionChange" |
|
|
|
|
> |
|
|
|
|
<template #default="slotProps"> |
|
|
|
|
<template v-if="slotProps.scope.column.label === '操作'" > |
|
|
|
|
<template v-if="slotProps.scope.column.label === '操作'"> |
|
|
|
|
<div class="ElBtnClass"> |
|
|
|
|
<div > |
|
|
|
|
<div> |
|
|
|
|
<!-- <el-button @click="addingRecord(slotProps.scope)">新增记录</el-button> --> |
|
|
|
|
<el-button v-if="TabPermissions !='4'" @click="view(slotProps.scope)" |
|
|
|
|
<el-button v-if="TabPermissions != '4'" @click="view(slotProps.scope)" |
|
|
|
|
>查看</el-button |
|
|
|
|
> |
|
|
|
|
<!-- <el-button @click="ViewEvent(slotProps.scope)">编辑</el-button> --> |
|
|
|
@ -169,7 +170,9 @@
|
|
|
|
|
>申诉</el-button |
|
|
|
|
> --> |
|
|
|
|
</div> |
|
|
|
|
<el-button v-if='TabPermissions==4' @click="BtnModifyAmount(slotProps.scope)" |
|
|
|
|
<el-button |
|
|
|
|
v-if="TabPermissions == 7" |
|
|
|
|
@click="BtnModifyAmount(slotProps.scope)" |
|
|
|
|
>修改金额</el-button |
|
|
|
|
> |
|
|
|
|
</div> |
|
|
|
@ -1309,12 +1312,10 @@ const {
|
|
|
|
|
// { label: '超时未处理', value: 7 }, |
|
|
|
|
// ]; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// // 按钮配置 |
|
|
|
|
// // 1.新增 2.批量打回 3.工单指派 4.申请仲裁 5.批量完结 6.申诉 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// // 角色配置 |
|
|
|
|
// // 角色配置 |
|
|
|
|
// // 1.仓库客服 |
|
|
|
|
// // 2.职能客服 |
|
|
|
|
// // 3.客服经理 |
|
|
|
@ -1337,7 +1338,6 @@ const {
|
|
|
|
|
// // 在value==2状态下的权限配置 |
|
|
|
|
// 隐藏所有按钮 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// // 在value==3状态下的权限配置 |
|
|
|
|
// 1.新增 隐藏 |
|
|
|
|
// 2.批量打回 只能仓库客服查看 |
|
|
|
@ -1354,7 +1354,6 @@ const {
|
|
|
|
|
// 5.批量完结 隐藏 |
|
|
|
|
// 6.申诉 仓库客服查看 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// // 在value==5状态下的权限配置 |
|
|
|
|
// 1.新增 隐藏 |
|
|
|
|
// 2.批量打回 隐藏 |
|
|
|
@ -1362,7 +1361,7 @@ const {
|
|
|
|
|
// 4.申请仲裁 隐藏 |
|
|
|
|
// 5.批量完结 隐藏 |
|
|
|
|
// 6.申诉 隐藏 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// // 在value==6状态下的权限配置 |
|
|
|
|
// 1.新增 隐藏 |
|
|
|
|
// 2.批量打回 隐藏 |
|
|
|
@ -1371,7 +1370,6 @@ const {
|
|
|
|
|
// 5.批量完结 隐藏 |
|
|
|
|
// 6.申诉 隐藏 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// // 在value== 7 状态下的权限配置 |
|
|
|
|
// 1.新增 隐藏 |
|
|
|
|
// 2.批量打回 隐藏 |
|
|
|
@ -1389,77 +1387,77 @@ const {
|
|
|
|
|
const ButtonPermissions = computed(() => { |
|
|
|
|
// 根据 TabPermissions 的状态,决定每个按钮的显示隐藏逻辑 |
|
|
|
|
switch (TabPermissions.value) { |
|
|
|
|
case 0://全部 |
|
|
|
|
case 0: //全部 |
|
|
|
|
return { |
|
|
|
|
add: UserPermissions.value == '仓库客服', //新增按钮 |
|
|
|
|
batchReject: UserPermissions.value == '职能客服',//批量打回 |
|
|
|
|
assignment: UserPermissions.value == '客服经理',//工单指派 |
|
|
|
|
applyArbitration: UserPermissions.value == '仓库客服',//申请仲裁 |
|
|
|
|
batchFinish: UserPermissions.value == '职能客服',//批量完结 |
|
|
|
|
appeal: false//申诉 |
|
|
|
|
batchReject: UserPermissions.value == '职能客服', //批量打回 |
|
|
|
|
assignment: UserPermissions.value == '客服经理', //工单指派 |
|
|
|
|
applyArbitration: UserPermissions.value == '仓库客服', //申请仲裁 |
|
|
|
|
batchFinish: UserPermissions.value == '职能客服', //批量完结 |
|
|
|
|
appeal: false, //申诉 |
|
|
|
|
}; |
|
|
|
|
case 1://处理中 |
|
|
|
|
case 1: //处理中 |
|
|
|
|
return { |
|
|
|
|
add: false,//新增按钮 |
|
|
|
|
batchReject: UserPermissions.value != '仓库客服',//批量打回 |
|
|
|
|
assignment: false,//工单指派 |
|
|
|
|
applyArbitration: UserPermissions.value == '仓库客服',//申请仲裁 |
|
|
|
|
batchFinish:UserPermissions.value != '仓库客服',//批量完结 |
|
|
|
|
appeal: false//申诉 |
|
|
|
|
add: false, //新增按钮 |
|
|
|
|
batchReject: UserPermissions.value != '仓库客服', //批量打回 |
|
|
|
|
assignment: false, //工单指派 |
|
|
|
|
applyArbitration: UserPermissions.value == '仓库客服', //申请仲裁 |
|
|
|
|
batchFinish: UserPermissions.value != '仓库客服', //批量完结 |
|
|
|
|
appeal: false, //申诉 |
|
|
|
|
}; |
|
|
|
|
case 2://处理完毕 |
|
|
|
|
case 2: //处理完毕 |
|
|
|
|
return { |
|
|
|
|
add: false,//新增按钮 |
|
|
|
|
batchReject: false,//批量打回 |
|
|
|
|
assignment: false,//工单指派 |
|
|
|
|
applyArbitration: false,//申请仲裁 |
|
|
|
|
batchFinish:false,//批量完结 |
|
|
|
|
appeal: UserPermissions.value == '仓库客服' && AppealStatusT.value//申诉 |
|
|
|
|
add: false, //新增按钮 |
|
|
|
|
batchReject: false, //批量打回 |
|
|
|
|
assignment: false, //工单指派 |
|
|
|
|
applyArbitration: false, //申请仲裁 |
|
|
|
|
batchFinish: false, //批量完结 |
|
|
|
|
appeal: UserPermissions.value == '仓库客服' && AppealStatusT.value, //申诉 |
|
|
|
|
}; |
|
|
|
|
case 3://待处理 |
|
|
|
|
case 3: //待处理 |
|
|
|
|
return { |
|
|
|
|
add: false,//新增按钮 |
|
|
|
|
batchReject: UserPermissions.value == '仓库客服',//批量打回 |
|
|
|
|
assignment:UserPermissions.value == '客服经理',//工单指派 |
|
|
|
|
applyArbitration: false,//申请仲裁 |
|
|
|
|
batchFinish:false,//批量完结 |
|
|
|
|
appeal: false//申诉 |
|
|
|
|
add: false, //新增按钮 |
|
|
|
|
batchReject: UserPermissions.value == '仓库客服', //批量打回 |
|
|
|
|
assignment: UserPermissions.value == '客服经理', //工单指派 |
|
|
|
|
applyArbitration: false, //申请仲裁 |
|
|
|
|
batchFinish: false, //批量完结 |
|
|
|
|
appeal: false, //申诉 |
|
|
|
|
}; |
|
|
|
|
case 4://理赔金额未出 |
|
|
|
|
case 4: //理赔金额未出 |
|
|
|
|
return { |
|
|
|
|
add: false,//新增按钮 |
|
|
|
|
batchReject: false,//批量打回 |
|
|
|
|
assignment:false,//工单指派 |
|
|
|
|
applyArbitration: false,//申请仲裁 |
|
|
|
|
batchFinish:false,//批量完结 |
|
|
|
|
appeal: UserPermissions.value == '仓库客服'//申诉 |
|
|
|
|
add: false, //新增按钮 |
|
|
|
|
batchReject: false, //批量打回 |
|
|
|
|
assignment: false, //工单指派 |
|
|
|
|
applyArbitration: false, //申请仲裁 |
|
|
|
|
batchFinish: false, //批量完结 |
|
|
|
|
appeal: UserPermissions.value == '仓库客服', //申诉 |
|
|
|
|
}; |
|
|
|
|
case 5://仲裁中 |
|
|
|
|
case 5: //仲裁中 |
|
|
|
|
return { |
|
|
|
|
add: false,//新增按钮 |
|
|
|
|
batchReject: false,//批量打回 |
|
|
|
|
assignment:false,//工单指派 |
|
|
|
|
applyArbitration: false,//申请仲裁 |
|
|
|
|
batchFinish:false,//批量完结 |
|
|
|
|
appeal:false//申诉 |
|
|
|
|
add: false, //新增按钮 |
|
|
|
|
batchReject: false, //批量打回 |
|
|
|
|
assignment: false, //工单指派 |
|
|
|
|
applyArbitration: false, //申请仲裁 |
|
|
|
|
batchFinish: false, //批量完结 |
|
|
|
|
appeal: false, //申诉 |
|
|
|
|
}; |
|
|
|
|
case 6://完结 |
|
|
|
|
case 6: //完结 |
|
|
|
|
return { |
|
|
|
|
add: false,//新增按钮 |
|
|
|
|
batchReject: false,//批量打回 |
|
|
|
|
assignment:false,//工单指派 |
|
|
|
|
applyArbitration: false,//申请仲裁 |
|
|
|
|
batchFinish:false,//批量完结 |
|
|
|
|
appeal:false//申诉 |
|
|
|
|
add: false, //新增按钮 |
|
|
|
|
batchReject: false, //批量打回 |
|
|
|
|
assignment: false, //工单指派 |
|
|
|
|
applyArbitration: false, //申请仲裁 |
|
|
|
|
batchFinish: false, //批量完结 |
|
|
|
|
appeal: false, //申诉 |
|
|
|
|
}; |
|
|
|
|
case 7://超时未处理 |
|
|
|
|
case 7: //超时未处理 |
|
|
|
|
return { |
|
|
|
|
add: false,//新增按钮 |
|
|
|
|
batchReject: false,//批量打回 |
|
|
|
|
assignment:false,//工单指派 |
|
|
|
|
applyArbitration: false,//申请仲裁 |
|
|
|
|
batchFinish:false,//批量完结 |
|
|
|
|
appeal:false//申诉 |
|
|
|
|
add: false, //新增按钮 |
|
|
|
|
batchReject: false, //批量打回 |
|
|
|
|
assignment: false, //工单指派 |
|
|
|
|
applyArbitration: false, //申请仲裁 |
|
|
|
|
batchFinish: false, //批量完结 |
|
|
|
|
appeal: false, //申诉 |
|
|
|
|
}; |
|
|
|
|
// 其他任何情况下的默认情况 |
|
|
|
|
default: |
|
|
|
@ -1469,12 +1467,11 @@ const ButtonPermissions = computed(() => {
|
|
|
|
|
assignment: false, |
|
|
|
|
applyArbitration: false, |
|
|
|
|
batchFinish: false, |
|
|
|
|
appeal: false |
|
|
|
|
appeal: false, |
|
|
|
|
}; |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const ProcessingResults = [ |
|
|
|
|
{ |
|
|
|
|
value: '0', |
|
|
|
@ -1542,6 +1539,7 @@ const IndexTable = val => {
|
|
|
|
|
data.size = page.value.pageSize; //条数 |
|
|
|
|
updateDictionary(columnList[2].checkarr, 'pc_work_order'); //异常类型 |
|
|
|
|
updateDictionary(columnList[3].checkarr, 'pc_discovery_node'); //发现环节 |
|
|
|
|
updateDictionary(columnList[17].checkarr, 'work_order_status'); //发现环节 |
|
|
|
|
// 获取角色权限 |
|
|
|
|
getDictionaryBiz('after_sales_visits').then(res => { |
|
|
|
|
console.log(res, '角色字典'); |
|
|
|
@ -1561,7 +1559,7 @@ const IndexTable = val => {
|
|
|
|
|
page.value.total = res.data.data.total; //总页数 |
|
|
|
|
if (res.data.data.records.length) { |
|
|
|
|
res.data.data.records.forEach(item => { |
|
|
|
|
console.log(item,'item'); |
|
|
|
|
console.log(item, 'item'); |
|
|
|
|
// 对为null的数据进行处理 |
|
|
|
|
for (const property in item) { |
|
|
|
|
if (item[property] == null) { |
|
|
|
@ -1598,6 +1596,25 @@ const IndexTable = val => {
|
|
|
|
|
} else if (item.discoveryNode == 8) { |
|
|
|
|
item.discoveryNodeNameS = columnList[3].checkarr[7].label; //安装环节 |
|
|
|
|
} |
|
|
|
|
if (item.workOrderStatus == 10) { |
|
|
|
|
item.workOrderStatusNameS = columnList[17].checkarr[0].label; //待处理 |
|
|
|
|
} else if (item.workOrderStatus == 20) { |
|
|
|
|
item.workOrderStatusNameS = columnList[17].checkarr[1].label; //处理中 |
|
|
|
|
} else if (item.workOrderStatus == 30) { |
|
|
|
|
item.workOrderStatusNameS = columnList[17].checkarr[2].label; //已处理 |
|
|
|
|
} else if (item.workOrderStatus == 40) { |
|
|
|
|
item.workOrderStatusNameS = columnList[17].checkarr[4].label; //待审核 |
|
|
|
|
} else if (item.workOrderStatus == 50) { |
|
|
|
|
item.workOrderStatusNameS = columnList[17].checkarr[5].label; //已审核 |
|
|
|
|
} else if (item.workOrderStatus == 60) { |
|
|
|
|
item.workOrderStatusNameS = columnList[17].checkarr[3].label; //超时未处理 |
|
|
|
|
} else if (item.workOrderStatus == 70) { |
|
|
|
|
item.workOrderStatusNameS = columnList[17].checkarr[6].label; //仲裁中 |
|
|
|
|
} else if (item.workOrderStatus == 80) { |
|
|
|
|
item.workOrderStatusNameS = columnList[17].checkarr[7].label; //完结 |
|
|
|
|
} else if (item.workOrderStatus == 90) { |
|
|
|
|
item.workOrderStatusNameS = columnList[17].checkarr[8].label; //理赔金未出 |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
details.data = res.data.data.records; |
|
|
|
|
} else { |
|
|
|
@ -1753,7 +1770,7 @@ const view = val => {
|
|
|
|
|
warehouseId: val.row.warehouseId, |
|
|
|
|
workOrderNumber: val.row.workOrderNumber, //添加异常记录包条码 |
|
|
|
|
businessId: val.row.businessId, |
|
|
|
|
ProcessType:TabPermissions.value==2?'2':TabPermissions.value==3?'1':'', //类型 1 待处理 2 已处理 |
|
|
|
|
ProcessType: TabPermissions.value == 2 ? '2' : TabPermissions.value == 3 ? '1' : '', //类型 1 待处理 2 已处理 |
|
|
|
|
}, |
|
|
|
|
}); |
|
|
|
|
return; |
|
|
|
@ -1877,14 +1894,14 @@ const appeal = val => {
|
|
|
|
|
}; |
|
|
|
|
// 工单申诉确认按钮 |
|
|
|
|
const Appealbutton = () => { |
|
|
|
|
console.log(details.selectionList,'当前申诉的东西'); |
|
|
|
|
console.log(details.selectionList, '当前申诉的东西'); |
|
|
|
|
loadingappeal.value = true; //开启加载效果 |
|
|
|
|
console.log(Appealselection.value, '当前选择的责任人'); |
|
|
|
|
console.log(warehouseData.value, '要循环处理的参数'); |
|
|
|
|
let data = { |
|
|
|
|
peopleEntityList: [], //参数一 |
|
|
|
|
}; |
|
|
|
|
data.workOrderId = details.selectionList[0].id; |
|
|
|
|
data.workOrderId = details.selectionList[0].lawoId; |
|
|
|
|
data.reason = Reasonforappeal.value; |
|
|
|
|
|
|
|
|
|
(data.appealPeopleName = warehouseData.value |
|
|
|
@ -1907,24 +1924,24 @@ const Appealbutton = () => {
|
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
console.log(data, '处理好的值'); |
|
|
|
|
// $_appealSubmit(data).then(res => { |
|
|
|
|
// dialogappeal.value = false; //关闭申诉弹窗 |
|
|
|
|
// loadingappeal.value = false; //关闭加载效果 |
|
|
|
|
// console.log(res, '申诉成功返回值'); |
|
|
|
|
// ProcessingPartyState.value = false; //关闭处理方 |
|
|
|
|
// data.workOrderStatus = 30; |
|
|
|
|
// details.query.workOrderStatus = 30; |
|
|
|
|
// ArbitrationStatus.value = false; //不可以申请仲裁 |
|
|
|
|
// tabValue.value = 2; |
|
|
|
|
// empty(); //清空搜索数据 |
|
|
|
|
// IndexTable({ workOrderStatus: 30 }); |
|
|
|
|
// if (res.data.code == 200) { |
|
|
|
|
// ElMessage({ |
|
|
|
|
// message: res.data.msg, |
|
|
|
|
// type: 'success', |
|
|
|
|
// }); |
|
|
|
|
// } |
|
|
|
|
// }); |
|
|
|
|
$_appealSubmit(data).then(res => { |
|
|
|
|
dialogappeal.value = false; //关闭申诉弹窗 |
|
|
|
|
loadingappeal.value = false; //关闭加载效果 |
|
|
|
|
console.log(res, '申诉成功返回值'); |
|
|
|
|
ProcessingPartyState.value = false; //关闭处理方 |
|
|
|
|
data.workOrderStatus = 30; |
|
|
|
|
details.query.workOrderStatus = 30; |
|
|
|
|
ArbitrationStatus.value = false; //不可以申请仲裁 |
|
|
|
|
tabValue.value = 2; |
|
|
|
|
empty(); //清空搜索数据 |
|
|
|
|
IndexTable({ workOrderStatus: 30 }); |
|
|
|
|
if (res.data.code == 200) { |
|
|
|
|
ElMessage({ |
|
|
|
|
message: res.data.msg, |
|
|
|
|
type: 'success', |
|
|
|
|
}); |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
// 异常类型事件 |
|
|
|
@ -2308,7 +2325,6 @@ const appealFn = val => {
|
|
|
|
|
|
|
|
|
|
// 申诉列表 |
|
|
|
|
const AppealTab = val => { |
|
|
|
|
|
|
|
|
|
if (val == 0) { |
|
|
|
|
AppealStatusT.value = false; //申诉列表开启 |
|
|
|
|
Tableheaderswitching(columnList); //切换表头 |
|
|
|
@ -2335,10 +2351,11 @@ const AppealTab = val => {
|
|
|
|
|
}; |
|
|
|
|
// 超时金额修改 |
|
|
|
|
const BtnModifyAmount = val => { |
|
|
|
|
console.log(val, '超时金额修改'); |
|
|
|
|
dialogModifyAmount.value = true; //开启超时金额弹窗修改 |
|
|
|
|
fromamount.value.title = val.row.workOrderNumber; //工单号 |
|
|
|
|
fromamount.value.ytimeout = val.row.money; //原本金额 |
|
|
|
|
fromamount.value.id = val.row.id; //id |
|
|
|
|
fromamount.value.id = val.row.lawoId; //id |
|
|
|
|
}; |
|
|
|
|
// 修改金额确定 |
|
|
|
|
const ModifyAmountFn = () => { |
|
|
|
|