Commit f86181cc authored by 沈翠玲's avatar 沈翠玲

字典改成调用接口

parent b928c284
...@@ -51,7 +51,8 @@ ...@@ -51,7 +51,8 @@
import { getPlatformPage } from '@/api/platform'; import { getPlatformPage } from '@/api/platform';
import { getManageOrgPage } from '@/api/manageOrg'; import { getManageOrgPage } from '@/api/manageOrg';
import { getTenantPage } from '@/api/tenant'; import { getTenantPage } from '@/api/tenant';
import { useDict } from '@/hooks/useDict';
const { PhoneResultStatus, ReduceType, FlowStatus, FollowStatus, DistributeStatus, CaseStatus } = useDict("PhoneResultStatus","ReduceType", "FlowStatus", "FollowStatus","DistributeStatus", "CaseStatus");
const allocationModalRef = ref(); const allocationModalRef = ref();
const caseLRef = ref(); const caseLRef = ref();
const selectdList = ref([]); const selectdList = ref([]);
...@@ -84,11 +85,6 @@ ...@@ -84,11 +85,6 @@
}); });
query(); query();
}; };
const caseStatusOpt = [
{ label: '正常', value: 'normal' },
{ label: '撤案', value: 'withdraw' },
{ label: '留案', value: 'stay' },
];
const paramCallback = (param) => { const paramCallback = (param) => {
const obj = JSON.parse(JSON.stringify(param)); const obj = JSON.parse(JSON.stringify(param));
if (obj.arealist && obj.arealist.length > 0) { if (obj.arealist && obj.arealist.length > 0) {
...@@ -111,11 +107,6 @@ ...@@ -111,11 +107,6 @@
getStatisis(obj); getStatisis(obj);
return obj; return obj;
}; };
const distributeStatusOpt = [
{ label: '未分派', value: 'undistributed' },
{ label: '分派到调解中心', value: 'tenant' },
{ label: '分派到CPE', value: 'CPE' },
];
const onCheckboxAll = (flag) => { const onCheckboxAll = (flag) => {
if (flag.checked) { if (flag.checked) {
selectdList.value = flag.records; selectdList.value = flag.records;
...@@ -199,7 +190,7 @@ ...@@ -199,7 +190,7 @@
title: '分派状态', title: '分派状态',
showOverflow: 'tooltip', showOverflow: 'tooltip',
width: 80, width: 80,
enum: distributeStatusOpt, enum: DistributeStatus,
search: { el: 'select', props: { filterable: true }, labelWidth: 78 }, search: { el: 'select', props: { filterable: true }, labelWidth: 78 },
fieldNames: { label: 'label', value: 'value' }, fieldNames: { label: 'label', value: 'value' },
slots: { slots: {
...@@ -207,7 +198,7 @@ ...@@ -207,7 +198,7 @@
return ( return (
<> <>
{row.distributeStatus {row.distributeStatus
? distributeStatusOpt.find((v) => v.value === row.distributeStatus)?.label ? DistributeStatus.value?.find((v) => v.value === row.distributeStatus)?.label
: ''} : ''}
</> </>
); );
...@@ -317,14 +308,14 @@ ...@@ -317,14 +308,14 @@
title: '案件状态', title: '案件状态',
showOverflow: 'tooltip', showOverflow: 'tooltip',
width: 80, width: 80,
enum: caseStatusOpt, enum: CaseStatus,
// search: { el: 'select', props: { filterable: true }, labelWidth: 80 }, // search: { el: 'select', props: { filterable: true }, labelWidth: 80 },
fieldNames: { label: 'label', value: 'value' }, fieldNames: { label: 'label', value: 'value' },
slots: { slots: {
default: ({ row }) => { default: ({ row }) => {
return ( return (
<> <>
{row.caseStatus ? caseStatusOpt.find((v) => v.value === row.caseStatus)?.label : ''} {row.caseStatus ? CaseStatus.value?.find((v) => v.value === row.caseStatus)?.label : ''}
</> </>
); );
}, },
......
...@@ -128,7 +128,7 @@ ...@@ -128,7 +128,7 @@
class="mr-2 mb-2" class="mr-2 mb-2"
:type="form.phoneResultStatus === item1.value ? 'primary' : null" :type="form.phoneResultStatus === item1.value ? 'primary' : null"
plain plain
v-for="(item1, index1) in statusArr" v-for="(item1, index1) in PhoneResultStatus"
:key="`btn${index1}`" :key="`btn${index1}`"
@click="form.phoneResultStatus = item1.value" @click="form.phoneResultStatus = item1.value"
>{{ item1.label }}</el-button >{{ item1.label }}</el-button
...@@ -233,6 +233,8 @@ ...@@ -233,6 +233,8 @@
import { Upload } from '@element-plus/icons-vue'; import { Upload } from '@element-plus/icons-vue';
import { getAppEnvConfig } from '@/utils/env'; import { getAppEnvConfig } from '@/utils/env';
import { saveTrackRecord } from '@/api/property'; import { saveTrackRecord } from '@/api/property';
import { useDict } from '@/hooks/useDict';
const { PhoneResultStatus, ReduceType, FlowStatus, FollowStatus, AuditStatus, CaseStatus } = useDict("PhoneResultStatus","ReduceType", "FlowStatus", "FollowStatus","AuditStatus", "CaseStatus");
const envs = getAppEnvConfig(); const envs = getAppEnvConfig();
const url = envs.VITE_GLOB_API_URL_PREFIX + '/sys/upload'; const url = envs.VITE_GLOB_API_URL_PREFIX + '/sys/upload';
const showModal = ref(false); const showModal = ref(false);
...@@ -309,40 +311,6 @@ ...@@ -309,40 +311,6 @@
const onHide = (done) => { const onHide = (done) => {
done(); done();
}; };
const statusArr = [
{
label: '后续再跟进',
value: 'later',
},
{
label: '承诺还款',
value: 'Promise_Repayment',
},
{
label: '暂无还款意愿',
value: 'No_Repay',
},
{
label: '要求停催',
value: 'Stop_Urging',
},
{
label: '情绪激动抗拒',
value: 'resistance',
},
{
label: '拒绝还款',
value: 'Refuse_Repayment',
},
{
label: '已还款',
value: 'Repaired',
},
{
label: '代履行还款',
value: 'repayment_others',
},
];
const selectdList = ref([]); const selectdList = ref([]);
const onCheckboxChange = (row) => { const onCheckboxChange = (row) => {
selectdList.value = row.records; selectdList.value = row.records;
......
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
<el-form-item class="w-full" label="减免类型:" prop="name" label-width="82px"> <el-form-item class="w-full" label="减免类型:" prop="name" label-width="82px">
<el-select v-model="form.reduceType" placeholder="请选择"> <el-select v-model="form.reduceType" placeholder="请选择">
<el-option <el-option
v-for="item in options" v-for="item in ReduceType"
:key="item.value" :key="item.value"
:label="item.label" :label="item.label"
:value="item.value" :value="item.value"
...@@ -92,6 +92,8 @@ ...@@ -92,6 +92,8 @@
import { onMounted } from 'vue'; import { onMounted } from 'vue';
import { watch } from 'vue'; import { watch } from 'vue';
import Decimal from 'decimal.js'; import Decimal from 'decimal.js';
import { useDict } from '@/hooks/useDict';
const { PhoneResultStatus, ReduceType, FlowStatus, FollowStatus, AuditStatus, CaseStatus } = useDict("PhoneResultStatus","ReduceType", "FlowStatus", "FollowStatus","AuditStatus", "CaseStatus");
const emits = defineEmits(['success']); const emits = defineEmits(['success']);
const showModal = ref(false); const showModal = ref(false);
const tabledata = ref([]); const tabledata = ref([]);
...@@ -144,17 +146,6 @@ ...@@ -144,17 +146,6 @@
const onHide = (done) => { const onHide = (done) => {
done(); done();
}; };
const options = [
{
value: 'settle',
label: '结清减免',
},
{
value: 'by_stages',
label: '分期减免',
},
];
const config = reactive({ const config = reactive({
checkboxConfig: { checkboxConfig: {
checkMethod: ({ row }) => { checkMethod: ({ row }) => {
......
...@@ -194,7 +194,8 @@ ...@@ -194,7 +194,8 @@
import { reactive, ref } from 'vue'; import { reactive, ref } from 'vue';
import { getAppEnvConfig } from '@/utils/env'; import { getAppEnvConfig } from '@/utils/env';
import { ElMessage } from 'element-plus'; import { ElMessage } from 'element-plus';
import { useDict } from '@/hooks/useDict';
const { PhoneResultStatus, RepayType, FlowStatus, FollowStatus, AuditStatus, CaseStatus } = useDict("PhoneResultStatus","RepayType", "FlowStatus", "FollowStatus","AuditStatus", "CaseStatus");
import { saveRepayRecord } from '@/api/property'; import { saveRepayRecord } from '@/api/property';
const envs = getAppEnvConfig(); const envs = getAppEnvConfig();
const data = ref([]); const data = ref([]);
...@@ -262,26 +263,12 @@ ...@@ -262,26 +263,12 @@
dialogImageUrl.value = uploadFile.url; dialogImageUrl.value = uploadFile.url;
dialogVisible.value = true; dialogVisible.value = true;
}; };
const options = [
{
value: 'repay',
label: '直接还款',
},
{
value: 'by_stages',
label: '分期还款',
},
{
value: 'settle',
label: '结清减免还款',
},
];
const submitForm = () => { const submitForm = () => {
console.log('currentInfo.value', currentInfo.value, currentDetail.value, tabledata.value); console.log('currentInfo.value', currentInfo.value, currentDetail.value, tabledata.value);
formRef.value.validate((valid) => { formRef.value.validate((valid) => {
if (valid) { if (valid) {
const param = { const param = {
repayType: options.find((v) => v.label === currentType.value).value, repayType: RepayType.value.find((v) => v.label === currentType.value).value,
...form, ...form,
repayAmount: form.realRepayAmount, repayAmount: form.realRepayAmount,
borrower: currentInfo.value.borrower, borrower: currentInfo.value.borrower,
......
...@@ -144,7 +144,9 @@ ...@@ -144,7 +144,9 @@
import { savebyStages } from '@/api/property'; import { savebyStages } from '@/api/property';
import { getByIdPlatforms } from '@/api/platform'; import { getByIdPlatforms } from '@/api/platform';
import Decimal from 'decimal.js'; import Decimal from 'decimal.js';
import { useDict } from '@/hooks/useDict';
const { PhoneResultStatus, RepayStatus, FlowStatus, FollowStatus, AuditStatus, CaseStatus } = useDict("PhoneResultStatus","RepayStatus", "FlowStatus", "FollowStatus","AuditStatus", "CaseStatus");
const ProTableRef = ref(); const ProTableRef = ref();
const showModal = ref(false); const showModal = ref(false);
const editFirst = ref(false); const editFirst = ref(false);
...@@ -302,16 +304,7 @@ ...@@ -302,16 +304,7 @@
// //
}); });
}; };
const repayStatusOpt = [
{
value: 'pending',
label: '待还款',
},
{
value: 'over',
label: '已还款',
},
];
const selectdList = ref([]); const selectdList = ref([]);
const onCheckboxChange = (row) => { const onCheckboxChange = (row) => {
selectdList.value = row.records; selectdList.value = row.records;
...@@ -420,7 +413,7 @@ ...@@ -420,7 +413,7 @@
return ( return (
<> <>
{row.repayStatus {row.repayStatus
? repayStatusOpt.find((v) => v.value === row.repayStatus)?.label ? RepayStatus.value?.find((v) => v.value === row.repayStatus)?.label
: ''} : ''}
</> </>
); );
......
...@@ -26,46 +26,12 @@ ...@@ -26,46 +26,12 @@
import { computed } from 'vue'; import { computed } from 'vue';
import { reactive, ref } from 'vue'; import { reactive, ref } from 'vue';
import { pengLoanExcel } from '@/api/import'; import { pengLoanExcel } from '@/api/import';
import { useDict } from '@/hooks/useDict';
const { PhoneResultStatus, ReduceType, FlowStatus, FollowStatus, AuditStatus, CaseStatus } = useDict("PhoneResultStatus","ReduceType", "FlowStatus", "FollowStatus","AuditStatus", "CaseStatus");
const ProTableRef = ref(); const ProTableRef = ref();
const showModal = ref(false); const showModal = ref(false);
const data = ref([]); const data = ref([]);
const currentAccount = ref(undefined); const currentAccount = ref(undefined);
const followStatusOpt = [
{ label: '接通后挂断', value: 'hang_up' },
{ label: '接通有实质进展', value: 'progress' },
{ label: '接通有效转告', value: 'pass_on' },
{ label: '接通拒绝转告', value: 'no_pass' },
{ label: '接听后挂断', value: 'Hang_up_after_answering' },
{ label: '接通无应答', value: 'No_response_when_connected' },
{ label: '称与债人无关', value: 'Claims_unrelated_to_creditors' },
{ label: '称非本人', value: 'Claiming_not_to_be_myself' },
{ label: '无人接听', value: 'no_answer' },
{ label: '关机', value: 'Shutdown' },
{ label: '空号', value: 'dead_number' },
{ label: '占线/忙音/正在通话中', value: 'Busy' },
{ label: '停机', value: 'closing_down' },
{ label: '机器人回复', value: 'Robot_reply' },
{ label: '微信', value: 'WeChat' },
{ label: '短信', value: 'short_message' },
{ label: 'QQ', value: 'QQ' },
{ label: '飞书', value: 'fly' },
{ label: '钉钉', value: 'DING' },
];
const phoneResultStatusOpt = [
{ label: '后续再跟进', value: 'later' },
{ label: '承诺还款', value: 'Promise_Repayment' },
{ label: '暂无还款意愿', value: 'No_Repay' },
{ label: '要求停催', value: 'Stop_Urging' },
{ label: '情绪激动抗拒', value: 'resistance' },
{ label: '拒绝还款', value: 'Refuse_Repayment' },
{ label: '已还款', value: 'Repaired' },
{ label: '代履行还款', value: 'repayment_others' },
];
const caseStatusOpt = [
{ label: '正常', value: 'normal' },
{ label: '撤案', value: 'withdraw' },
{ label: '留案', value: 'stay' },
];
const exportEvent = () => { const exportEvent = () => {
if (ProTableRef.value && ProTableRef.value.element) { if (ProTableRef.value && ProTableRef.value.element) {
ProTableRef.value.element.exportData({ ProTableRef.value.element.exportData({
...@@ -190,7 +156,7 @@ ...@@ -190,7 +156,7 @@
field: 'followStatus', field: 'followStatus',
title: '跟进结果', title: '跟进结果',
width: 80, width: 80,
enum: followStatusOpt, enum: FollowStatus,
// search: { el: 'select', props: { filterable: true }, labelWidth: 80 }, // search: { el: 'select', props: { filterable: true }, labelWidth: 80 },
fieldNames: { label: 'label', value: 'value' }, fieldNames: { label: 'label', value: 'value' },
slots: { slots: {
...@@ -198,7 +164,7 @@ ...@@ -198,7 +164,7 @@
return ( return (
<> <>
{row.followStatus {row.followStatus
? followStatusOpt.find((v) => v.value === row.followStatus)?.label ? FollowStatus.value?.find((v) => v.value === row.followStatus)?.label
: ''} : ''}
</> </>
); );
...@@ -209,7 +175,7 @@ ...@@ -209,7 +175,7 @@
field: 'phoneResultStatus', field: 'phoneResultStatus',
title: '跟进状态', title: '跟进状态',
width: 80, width: 80,
enum: phoneResultStatusOpt, enum: PhoneResultStatus,
// search: { el: 'select', props: { filterable: true }, labelWidth: 80 }, // search: { el: 'select', props: { filterable: true }, labelWidth: 80 },
fieldNames: { label: 'label', value: 'value' }, fieldNames: { label: 'label', value: 'value' },
slots: { slots: {
...@@ -217,7 +183,7 @@ ...@@ -217,7 +183,7 @@
return ( return (
<> <>
{row.phoneResultStatus {row.phoneResultStatus
? phoneResultStatusOpt.find((v) => v.value === row.phoneResultStatus)?.label ? PhoneResultStatus.value?.find((v) => v.value === row.phoneResultStatus)?.label
: ''} : ''}
</> </>
); );
...@@ -228,14 +194,14 @@ ...@@ -228,14 +194,14 @@
field: 'caseStatus', field: 'caseStatus',
title: '案件状态', title: '案件状态',
width: 80, width: 80,
enum: caseStatusOpt, enum: CaseStatus,
// search: { el: 'select', props: { filterable: true }, labelWidth: 80 }, // search: { el: 'select', props: { filterable: true }, labelWidth: 80 },
fieldNames: { label: 'label', value: 'value' }, fieldNames: { label: 'label', value: 'value' },
slots: { slots: {
default: ({ row }) => { default: ({ row }) => {
return ( return (
<> <>
{row.caseStatus ? caseStatusOpt.find((v) => v.value === row.caseStatus)?.label : ''} {row.caseStatus ? CaseStatus.value?.find((v) => v.value === row.caseStatus)?.label : ''}
</> </>
); );
}, },
......
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
<el-tab-pane <el-tab-pane
:label="item.label" :label="item.label"
:name="item.value" :name="item.value"
v-for="(item, index) in auditStatusOpt" v-for="(item, index) in AuditStatus"
:key="index" :key="index"
></el-tab-pane> ></el-tab-pane>
</el-tabs> </el-tabs>
...@@ -48,7 +48,8 @@ ...@@ -48,7 +48,8 @@
import { useUserStore } from '@/stores/modules/user'; import { useUserStore } from '@/stores/modules/user';
const { userInfo } = useUserStore(); const { userInfo } = useUserStore();
import { getTenantPage } from '@/api/tenant'; import { getTenantPage } from '@/api/tenant';
import { useDict } from '@/hooks/useDict';
const { PhoneResultStatus, ReduceType, FlowStatus, FollowStatus, AuditStatus, CaseStatus } = useDict("PhoneResultStatus","ReduceType", "FlowStatus", "FollowStatus","AuditStatus", "CaseStatus");
const envs = getAppEnvConfig(); const envs = getAppEnvConfig();
import { reactive, ref } from 'vue'; import { reactive, ref } from 'vue';
const downloadfile = inject('download'); const downloadfile = inject('download');
...@@ -63,44 +64,6 @@ ...@@ -63,44 +64,6 @@
selectdList.value = row.records; selectdList.value = row.records;
}; };
const followStatusOpt = [
{ label: '接通后挂断', value: 'hang_up' },
{ label: '接通有实质进展', value: 'progress' },
{ label: '接通有效转告', value: 'pass_on' },
{ label: '接通拒绝转告', value: 'no_pass' },
{ label: '接听后挂断', value: 'Hang_up_after_answering' },
{ label: '接通无应答', value: 'No_response_when_connected' },
{ label: '称与债人无关', value: 'Claims_unrelated_to_creditors' },
{ label: '称非本人', value: 'Claiming_not_to_be_myself' },
{ label: '无人接听', value: 'no_answer' },
{ label: '关机', value: 'Shutdown' },
{ label: '空号', value: 'dead_number' },
{ label: '占线/忙音/正在通话中', value: 'Busy' },
{ label: '停机', value: 'closing_down' },
{ label: '机器人回复', value: 'Robot_reply' },
{ label: '微信', value: 'WeChat' },
{ label: '短信', value: 'short_message' },
{ label: 'QQ', value: 'QQ' },
{ label: '飞书', value: 'fly' },
{ label: '钉钉', value: 'DING' },
];
const phoneResultStatusOpt = [
{ label: '后续再跟进', value: 'later' },
{ label: '承诺还款', value: 'Promise_Repayment' },
{ label: '暂无还款意愿', value: 'No_Repay' },
{ label: '要求停催', value: 'Stop_Urging' },
{ label: '情绪激动抗拒', value: 'resistance' },
{ label: '拒绝还款', value: 'Refuse_Repayment' },
{ label: '已还款', value: 'Repaired' },
{ label: '代履行还款', value: 'repayment_others' },
];
const auditStatusOpt = [
{ label: '未稽核', value: 'un_audit' },
{ label: '稽核中', value: 'audit' },
{ label: '已拒绝', value: 'rejected' },
{ label: '已完成', value: 'complete' },
{ label: '稽核通过', value: 'passed' },
];
const activeName = ref('un_audit'); const activeName = ref('un_audit');
const callMode = ref(''); const callMode = ref('');
const paramCallback = (param) => { const paramCallback = (param) => {
...@@ -240,7 +203,7 @@ ...@@ -240,7 +203,7 @@
title: '拨打跟进结果', title: '拨打跟进结果',
showOverflow: 'tooltip', showOverflow: 'tooltip',
width: 120, width: 120,
enum: followStatusOpt, enum: FollowStatus,
search: { search: {
el: 'select', el: 'select',
props: { filterable: true, multiple: true, 'collapse-tags': true }, props: { filterable: true, multiple: true, 'collapse-tags': true },
...@@ -259,7 +222,7 @@ ...@@ -259,7 +222,7 @@
return ( return (
<> <>
{row.followStatus {row.followStatus
? followStatusOpt.find((v) => v.value === row.followStatus)?.label ? FollowStatus.value?.find((v) => v.value === row.followStatus)?.label
: ''} : ''}
</> </>
); );
...@@ -271,7 +234,7 @@ ...@@ -271,7 +234,7 @@
title: '拨打处置状态', title: '拨打处置状态',
showOverflow: 'tooltip', showOverflow: 'tooltip',
width: 120, width: 120,
enum: phoneResultStatusOpt, enum: PhoneResultStatus,
search: { el: 'select', props: { filterable: true }, labelWidth: 78 }, search: { el: 'select', props: { filterable: true }, labelWidth: 78 },
fieldNames: { label: 'label', value: 'value' }, fieldNames: { label: 'label', value: 'value' },
slots: { slots: {
...@@ -279,7 +242,7 @@ ...@@ -279,7 +242,7 @@
return ( return (
<> <>
{row.phoneResultStatus {row.phoneResultStatus
? phoneResultStatusOpt.find((v) => v.value === row.phoneResultStatus)?.label ? PhoneResultStatus.value?.find((v) => v.value === row.phoneResultStatus)?.label
: ''} : ''}
</> </>
); );
...@@ -296,7 +259,7 @@ ...@@ -296,7 +259,7 @@
return ( return (
<> <>
{row.auditStatus {row.auditStatus
? auditStatusOpt.find((v) => v.value === row.auditStatus)?.label ? AuditStatus.value?.find((v) => v.value === row.auditStatus)?.label
: ''} : ''}
</> </>
); );
......
...@@ -26,7 +26,8 @@ ...@@ -26,7 +26,8 @@
import { useUserStore } from '@/stores/modules/user'; import { useUserStore } from '@/stores/modules/user';
import { getPlatformPage } from '@/api/platform'; import { getPlatformPage } from '@/api/platform';
import { getManageOrgPage } from '@/api/manageOrg'; import { getManageOrgPage } from '@/api/manageOrg';
import { useDict } from '@/hooks/useDict';
const { PhoneResultStatus, ReduceType, FlowStatus, FollowStatus, AuditStatus, CaseStatus } = useDict("PhoneResultStatus","ReduceType", "FlowStatus", "FollowStatus","AuditStatus", "CaseStatus");
const { userInfo } = useUserStore(); const { userInfo } = useUserStore();
const router = useRouter(); const router = useRouter();
const selectdList = ref([]); const selectdList = ref([]);
...@@ -83,42 +84,6 @@ ...@@ -83,42 +84,6 @@
}); });
query(); query();
}; };
const followStatusOpt = [
{ label: '接通后挂断', value: 'hang_up' },
{ label: '接通有实质进展', value: 'progress' },
{ label: '接通有效转告', value: 'pass_on' },
{ label: '接通拒绝转告', value: 'no_pass' },
{ label: '接听后挂断', value: 'Hang_up_after_answering' },
{ label: '接通无应答', value: 'No_response_when_connected' },
{ label: '称与债人无关', value: 'Claims_unrelated_to_creditors' },
{ label: '称非本人', value: 'Claiming_not_to_be_myself' },
{ label: '无人接听', value: 'no_answer' },
{ label: '关机', value: 'Shutdown' },
{ label: '空号', value: 'dead_number' },
{ label: '占线/忙音/正在通话中', value: 'Busy' },
{ label: '停机', value: 'closing_down' },
{ label: '机器人回复', value: 'Robot_reply' },
{ label: '微信', value: 'WeChat' },
{ label: '短信', value: 'short_message' },
{ label: 'QQ', value: 'QQ' },
{ label: '飞书', value: 'fly' },
{ label: '钉钉', value: 'DING' },
];
const phoneResultStatusOpt = [
{ label: '后续再跟进', value: 'later' },
{ label: '承诺还款', value: 'Promise_Repayment' },
{ label: '暂无还款意愿', value: 'No_Repay' },
{ label: '要求停催', value: 'Stop_Urging' },
{ label: '情绪激动抗拒', value: 'resistance' },
{ label: '拒绝还款', value: 'Refuse_Repayment' },
{ label: '已还款', value: 'Repaired' },
{ label: '代履行还款', value: 'repayment_others' },
];
const caseStatusOpt = [
{ label: '正常', value: 'normal' },
{ label: '撤案', value: 'withdraw' },
{ label: '留案', value: 'stay' },
];
const config = reactive({ const config = reactive({
columns: [ columns: [
{ type: 'checkbox', title: '', width: 40 }, { type: 'checkbox', title: '', width: 40 },
...@@ -261,7 +226,7 @@ ...@@ -261,7 +226,7 @@
showOverflow: 'tooltip', showOverflow: 'tooltip',
title: '跟进结果', title: '跟进结果',
width: 80, width: 80,
enum: followStatusOpt, enum: FollowStatus,
search: { el: 'select', props: { filterable: true }, labelWidth: 80 }, search: { el: 'select', props: { filterable: true }, labelWidth: 80 },
fieldNames: { label: 'label', value: 'value' }, fieldNames: { label: 'label', value: 'value' },
slots: { slots: {
...@@ -269,7 +234,7 @@ ...@@ -269,7 +234,7 @@
return ( return (
<> <>
{row.followStatus {row.followStatus
? followStatusOpt.find((v) => v.value === row.followStatus)?.label ? FollowStatus.value?.find((v) => v.value === row.followStatus)?.label
: ''} : ''}
</> </>
); );
...@@ -281,7 +246,7 @@ ...@@ -281,7 +246,7 @@
showOverflow: 'tooltip', showOverflow: 'tooltip',
title: '跟进状态', title: '跟进状态',
width: 80, width: 80,
enum: phoneResultStatusOpt, enum: PhoneResultStatus,
search: { el: 'select', props: { filterable: true }, labelWidth: 80 }, search: { el: 'select', props: { filterable: true }, labelWidth: 80 },
fieldNames: { label: 'label', value: 'value' }, fieldNames: { label: 'label', value: 'value' },
slots: { slots: {
...@@ -289,7 +254,7 @@ ...@@ -289,7 +254,7 @@
return ( return (
<> <>
{row.phoneResultStatus {row.phoneResultStatus
? phoneResultStatusOpt.find((v) => v.value === row.phoneResultStatus)?.label ? PhoneResultStatus.value?.find((v) => v.value === row.phoneResultStatus)?.label
: ''} : ''}
</> </>
); );
...@@ -301,14 +266,14 @@ ...@@ -301,14 +266,14 @@
showOverflow: 'tooltip', showOverflow: 'tooltip',
title: '案件状态', title: '案件状态',
width: 80, width: 80,
enum: caseStatusOpt, enum: CaseStatus,
search: { el: 'select', props: { filterable: true }, labelWidth: 80 }, search: { el: 'select', props: { filterable: true }, labelWidth: 80 },
fieldNames: { label: 'label', value: 'value' }, fieldNames: { label: 'label', value: 'value' },
slots: { slots: {
default: ({ row }) => { default: ({ row }) => {
return ( return (
<> <>
{row.caseStatus ? caseStatusOpt.find((v) => v.value === row.caseStatus)?.label : ''} {row.caseStatus ? CaseStatus.value?.find((v) => v.value === row.caseStatus)?.label : ''}
</> </>
); );
}, },
......
...@@ -10,24 +10,9 @@ ...@@ -10,24 +10,9 @@
import { ElMessageBox, ElMessage, ElTag } from 'element-plus'; import { ElMessageBox, ElMessage, ElTag } from 'element-plus';
import { onMounted } from 'vue'; import { onMounted } from 'vue';
import { pageMyMesage } from '@/api/message'; import { pageMyMesage } from '@/api/message';
const statusOpt = [ import { useDict } from '@/hooks/useDict';
{ label: '正常', value: 'normal' }, const { MessageStatus, SendType, MessageType, ServiceType, AuditStatus, CaseStatus } = useDict("MessageStatus","SendType", "MessageType", "ServiceType","AuditStatus", "CaseStatus");
{ label: '已撤销', value: 'cancel' },
];
const messageTypeOpt = [
{ label: '通知', value: 'system' },
{ label: '任务消息', value: 'task' },
];
const sendTypeOpt = [
{ label: '群发', value: 'all' },
{ label: '指定用户发送', value: 'user' },
{ label: '指定角色发送', value: 'role' },
{ label: '指定调节中心发送', value: 'tentant' },
];
const serviceTypeOpt = [
{ label: '流程', value: 'bpm' },
{ label: '提示', value: 'tip' },
];
const proTable = ref(); const proTable = ref();
const socketStore = useSocketStore(); const socketStore = useSocketStore();
const config = reactive({ const config = reactive({
...@@ -58,7 +43,7 @@ ...@@ -58,7 +43,7 @@
title: '状态', title: '状态',
showOverflow: 'tooltip', showOverflow: 'tooltip',
width: 100, width: 100,
enum: statusOpt, enum: MessageStatus,
search: { el: 'select', props: { filterable: true }, span: 1, labelWidth: 65 }, search: { el: 'select', props: { filterable: true }, span: 1, labelWidth: 65 },
fieldNames: { label: 'label', value: 'value' }, fieldNames: { label: 'label', value: 'value' },
slots: { slots: {
...@@ -82,7 +67,7 @@ ...@@ -82,7 +67,7 @@
width: 100, width: 100,
showOverflow: 'tooltip', showOverflow: 'tooltip',
title: '消息类型', title: '消息类型',
enum: messageTypeOpt, enum: MessageType,
search: { el: 'select', props: { filterable: true }, span: 1, labelWidth: 65 }, search: { el: 'select', props: { filterable: true }, span: 1, labelWidth: 65 },
fieldNames: { label: 'label', value: 'value' }, fieldNames: { label: 'label', value: 'value' },
slots: { slots: {
...@@ -90,7 +75,7 @@ ...@@ -90,7 +75,7 @@
return ( return (
<> <>
{row.messageType {row.messageType
? messageTypeOpt.find((v) => v.value === row.messageType)?.label ? MessageType.value?.find((v) => v.value === row.messageType)?.label
: ''} : ''}
</> </>
); );
...@@ -102,13 +87,13 @@ ...@@ -102,13 +87,13 @@
width: 100, width: 100,
title: '发送方式', title: '发送方式',
showOverflow: 'tooltip', showOverflow: 'tooltip',
enum: sendTypeOpt, enum: SendType,
search: { el: 'select', props: { filterable: true }, span: 1, labelWidth: 65 }, search: { el: 'select', props: { filterable: true }, span: 1, labelWidth: 65 },
fieldNames: { label: 'label', value: 'value' }, fieldNames: { label: 'label', value: 'value' },
slots: { slots: {
default: ({ row }) => { default: ({ row }) => {
return ( return (
<>{row.sendType ? sendTypeOpt.find((v) => v.value === row.sendType)?.label : ''}</> <>{row.sendType ? SendType.value?.find((v) => v.value === row.sendType)?.label : ''}</>
); );
}, },
}, },
...@@ -118,7 +103,7 @@ ...@@ -118,7 +103,7 @@
width: 100, width: 100,
title: '业务类型', title: '业务类型',
showOverflow: 'tooltip', showOverflow: 'tooltip',
enum: serviceTypeOpt, enum: ServiceType,
search: { el: 'select', props: { filterable: true }, span: 1, labelWidth: 65 }, search: { el: 'select', props: { filterable: true }, span: 1, labelWidth: 65 },
fieldNames: { label: 'label', value: 'value' }, fieldNames: { label: 'label', value: 'value' },
slots: { slots: {
...@@ -126,7 +111,7 @@ ...@@ -126,7 +111,7 @@
return ( return (
<> <>
{row.serviceType {row.serviceType
? serviceTypeOpt.find((v) => v.value === row.serviceType)?.label ? ServiceType.value?.find((v) => v.value === row.serviceType)?.label
: ''} : ''}
</> </>
); );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment