This commit is contained in:
parent
b821dabcb9
commit
ee075ea7f8
|
|
@ -289,6 +289,7 @@ export default {
|
||||||
|
|
||||||
this.$forceUpdate()
|
this.$forceUpdate()
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
// 如果没有id参数,说明是新增模式
|
// 如果没有id参数,说明是新增模式
|
||||||
this.addModeItems.forEach(item => {
|
this.addModeItems.forEach(item => {
|
||||||
this.pageOptions.formOptions.items.push(item);
|
this.pageOptions.formOptions.items.push(item);
|
||||||
|
|
|
||||||
|
|
@ -39,6 +39,9 @@
|
||||||
|
|
||||||
<template #op="{ row }">
|
<template #op="{ row }">
|
||||||
<div class="oplinks">
|
<div class="oplinks">
|
||||||
|
<a @click.stop="pageDetail(row)" title="详情">
|
||||||
|
<a-icon type="file"/>
|
||||||
|
</a>
|
||||||
<a @click.stop="pageEdit(row)" title="编辑">
|
<a @click.stop="pageEdit(row)" title="编辑">
|
||||||
<a-icon type="edit"/>
|
<a-icon type="edit"/>
|
||||||
</a>
|
</a>
|
||||||
|
|
@ -76,6 +79,7 @@ export default {
|
||||||
keyName: 'id', // 主键字段名
|
keyName: 'id', // 主键字段名
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// 接口动作
|
// 接口动作
|
||||||
actions: { // Api 接口地址
|
actions: { // Api 接口地址
|
||||||
// =============================== 接口地址 自动生成 Start ===============================
|
// =============================== 接口地址 自动生成 Start ===============================
|
||||||
|
|
@ -91,8 +95,6 @@ export default {
|
||||||
CustomBatchHandle: `${BASE_URL.BASE_URL}/Custom/v1/custom/batchHandle`, // 批量处理客户
|
CustomBatchHandle: `${BASE_URL.BASE_URL}/Custom/v1/custom/batchHandle`, // 批量处理客户
|
||||||
CustomOpen: `${BASE_URL.BASE_URL}/Custom/v1/custom/open`, // 打开客户
|
CustomOpen: `${BASE_URL.BASE_URL}/Custom/v1/custom/open`, // 打开客户
|
||||||
CustomClose: `${BASE_URL.BASE_URL}/Custom/v1/custom/close`, // 关闭客户
|
CustomClose: `${BASE_URL.BASE_URL}/Custom/v1/custom/close`, // 关闭客户
|
||||||
BalanceAdd: `${BASE_URL.BASE_URL}/Custom/v1/balance/add`, // 增加客户结余
|
|
||||||
BalanceReduce: `${BASE_URL.BASE_URL}/Custom/v1/balance/reduce`, // 减少客户结余
|
|
||||||
|
|
||||||
// =============================== 接口地址 自动生成 End ===============================
|
// =============================== 接口地址 自动生成 End ===============================
|
||||||
},
|
},
|
||||||
|
|
@ -179,6 +181,7 @@ export default {
|
||||||
{field: 'type', sortable: true, title: '类型',formatter: this.formatType, width: 150}, // 客户类型
|
{field: 'type', sortable: true, title: '类型',formatter: this.formatType, width: 150}, // 客户类型
|
||||||
{field: 'industry', sortable: true, title: '行业', width: 150}, // 客户行业
|
{field: 'industry', sortable: true, title: '行业', width: 150}, // 客户行业
|
||||||
{field: 'contact', title: '联系人', width: 150}, // 客户联系人
|
{field: 'contact', title: '联系人', width: 150}, // 客户联系人
|
||||||
|
{field: 'total_balance', sortable: true, title: '总结余', width: 150}, // 总结余
|
||||||
{field: 'contact_phone', sortable: true, title: '联系人电话', width: 150}, // 客户联系人电话
|
{field: 'contact_phone', sortable: true, title: '联系人电话', width: 150}, // 客户联系人电话
|
||||||
{field: 'total_ton', sortable: true, title: '总计交易吨数', width: 150}, // 总计交易吨数
|
{field: 'total_ton', sortable: true, title: '总计交易吨数', width: 150}, // 总计交易吨数
|
||||||
{field: 'total_count', sortable: true, title: '总计交易次数', width: 150}, // 总计交易次数
|
{field: 'total_count', sortable: true, title: '总计交易次数', width: 150}, // 总计交易次数
|
||||||
|
|
@ -191,7 +194,6 @@ export default {
|
||||||
title: '创建时间',
|
title: '创建时间',
|
||||||
showHeaderOverflow: true
|
showHeaderOverflow: true
|
||||||
}, // 创建时间
|
}, // 创建时间
|
||||||
{field: 'total_balance', sortable: true, title: '总结余', width: 150}, // 总结余
|
|
||||||
{field: 'total_amount', sortable: true, title: '总交易金额', width: 150}, // 总交易金额
|
{field: 'total_amount', sortable: true, title: '总交易金额', width: 150}, // 总交易金额
|
||||||
{field: 'remark', sortable: true, title: '备注', width: 250}, // 备注
|
{field: 'remark', sortable: true, title: '备注', width: 250}, // 备注
|
||||||
{
|
{
|
||||||
|
|
@ -207,7 +209,7 @@ export default {
|
||||||
// =============================== 表格列 自动生成 Start ===============================
|
// =============================== 表格列 自动生成 Start ===============================
|
||||||
|
|
||||||
|
|
||||||
{title: '操作', slots: {default: 'op'}, width: 120,fixed: 'right'}
|
{title: '操作', slots: {default: 'op'}, width: 160,fixed: 'right'}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -373,7 +375,34 @@ export default {
|
||||||
onSearch() {
|
onSearch() {
|
||||||
this.$refs.xGrid.commitProxy('query') // 提交搜索
|
this.$refs.xGrid.commitProxy('query') // 提交搜索
|
||||||
},
|
},
|
||||||
|
pageDetail(row){
|
||||||
|
console.log("list row",row)
|
||||||
|
if (!row) { // 如果没有选中行
|
||||||
|
this.$mk.msg("请选择行"); // 提示
|
||||||
|
return; // 返回
|
||||||
|
}
|
||||||
|
|
||||||
|
this.$mk.dialog.open({
|
||||||
|
height: 800,
|
||||||
|
width: 1200,
|
||||||
|
page: () => import('./Detail.vue'),
|
||||||
|
title: "详情",
|
||||||
|
dataId: row.id,
|
||||||
|
pageOptions: {
|
||||||
|
ApiUrl: this.actions.CustomDetail,
|
||||||
|
ApiData: {
|
||||||
|
id: row.id
|
||||||
|
},
|
||||||
|
FieldName: "custom",
|
||||||
|
title: "详情",
|
||||||
|
},
|
||||||
|
callback: ({success}) => {
|
||||||
|
console.log("success",success);
|
||||||
|
|
||||||
|
this.$forceUpdate() // 刷新
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
// 监听属性
|
// 监听属性
|
||||||
|
|
|
||||||
|
|
@ -274,7 +274,7 @@ export default {
|
||||||
// 如果是新增模式,关闭当前页面
|
// 如果是新增模式,关闭当前页面
|
||||||
if (!this.isEdit) {
|
if (!this.isEdit) {
|
||||||
this.$closePage({
|
this.$closePage({
|
||||||
closeRoute: "/DriverWages/DriverWagesAdd"
|
closeRoute: "/DriverWages/DriverWagesCreate"
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
// 如果是编辑模式,关闭当前页面
|
// 如果是编辑模式,关闭当前页面
|
||||||
|
|
@ -314,6 +314,7 @@ export default {
|
||||||
this.$mk.success("保存成功");
|
this.$mk.success("保存成功");
|
||||||
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
||||||
this.back();
|
this.back();
|
||||||
|
this.$forceUpdate()
|
||||||
}
|
}
|
||||||
}).catch((a) => { // 失败回调
|
}).catch((a) => { // 失败回调
|
||||||
this.$mk.error(a.data.msg); // 显示错误信息
|
this.$mk.error(a.data.msg); // 显示错误信息
|
||||||
|
|
|
||||||
|
|
@ -226,7 +226,7 @@ export default {
|
||||||
// 如果是新增模式,关闭当前页面
|
// 如果是新增模式,关闭当前页面
|
||||||
if (!this.isEdit) {
|
if (!this.isEdit) {
|
||||||
this.$closePage({
|
this.$closePage({
|
||||||
closeRoute: "/DriverWages/DriverWagesGiornaleLogAdd"
|
closeRoute: "/DriverWages/DriverWagesGiornaleLogCreate"
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
// 如果是编辑模式,关闭当前页面
|
// 如果是编辑模式,关闭当前页面
|
||||||
|
|
@ -266,6 +266,7 @@ export default {
|
||||||
this.$mk.success("保存成功");
|
this.$mk.success("保存成功");
|
||||||
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
||||||
this.back();
|
this.back();
|
||||||
|
this.$forceUpdate()
|
||||||
}
|
}
|
||||||
}).catch((a) => { // 失败回调
|
}).catch((a) => { // 失败回调
|
||||||
this.$mk.error(a.data.msg); // 显示错误信息
|
this.$mk.error(a.data.msg); // 显示错误信息
|
||||||
|
|
|
||||||
|
|
@ -231,7 +231,7 @@ export default {
|
||||||
// 如果是新增模式,关闭当前页面
|
// 如果是新增模式,关闭当前页面
|
||||||
if (!this.isEdit) {
|
if (!this.isEdit) {
|
||||||
this.$closePage({
|
this.$closePage({
|
||||||
closeRoute: "/DriverWages/DriverWagesSurplusAdd"
|
closeRoute: "/DriverWages/DriverWagesSurplusCreate"
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
// 如果是编辑模式,关闭当前页面
|
// 如果是编辑模式,关闭当前页面
|
||||||
|
|
@ -271,6 +271,7 @@ export default {
|
||||||
this.$mk.success("保存成功");
|
this.$mk.success("保存成功");
|
||||||
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
||||||
this.back();
|
this.back();
|
||||||
|
this.$forceUpdate()
|
||||||
}
|
}
|
||||||
}).catch((a) => { // 失败回调
|
}).catch((a) => { // 失败回调
|
||||||
this.$mk.error(a.data.msg); // 显示错误信息
|
this.$mk.error(a.data.msg); // 显示错误信息
|
||||||
|
|
|
||||||
|
|
@ -209,7 +209,7 @@ export default {
|
||||||
// 如果是新增模式,关闭当前页面
|
// 如果是新增模式,关闭当前页面
|
||||||
if (!this.isEdit) {
|
if (!this.isEdit) {
|
||||||
this.$closePage({
|
this.$closePage({
|
||||||
closeRoute: "/Maintenance/MaintenanceAdd"
|
closeRoute: "/Maintenance/MaintenanceCreate"
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
// 如果是编辑模式,关闭当前页面
|
// 如果是编辑模式,关闭当前页面
|
||||||
|
|
@ -249,6 +249,7 @@ export default {
|
||||||
this.$mk.success("保存成功");
|
this.$mk.success("保存成功");
|
||||||
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
||||||
this.back();
|
this.back();
|
||||||
|
this.$forceUpdate()
|
||||||
}
|
}
|
||||||
}).catch((a) => { // 失败回调
|
}).catch((a) => { // 失败回调
|
||||||
this.$mk.error(a.data.msg); // 显示错误信息
|
this.$mk.error(a.data.msg); // 显示错误信息
|
||||||
|
|
|
||||||
|
|
@ -305,7 +305,7 @@ export default {
|
||||||
// 如果是新增模式,关闭当前页面
|
// 如果是新增模式,关闭当前页面
|
||||||
if (!this.isEdit) {
|
if (!this.isEdit) {
|
||||||
this.$closePage({
|
this.$closePage({
|
||||||
closeRoute: "/Maintenance/MaintenanceGiornaleLogAdd"
|
closeRoute: "/Maintenance/MaintenanceGiornaleLogCreate"
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
// 如果是编辑模式,关闭当前页面
|
// 如果是编辑模式,关闭当前页面
|
||||||
|
|
@ -347,6 +347,7 @@ export default {
|
||||||
this.$mk.success("保存成功");
|
this.$mk.success("保存成功");
|
||||||
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
||||||
this.back();
|
this.back();
|
||||||
|
this.$forceUpdate()
|
||||||
}
|
}
|
||||||
}).catch((a) => { // 失败回调
|
}).catch((a) => { // 失败回调
|
||||||
this.$mk.error(a.data.msg); // 显示错误信息
|
this.$mk.error(a.data.msg); // 显示错误信息
|
||||||
|
|
|
||||||
|
|
@ -270,7 +270,7 @@ export default {
|
||||||
// 如果是新增模式,关闭当前页面
|
// 如果是新增模式,关闭当前页面
|
||||||
if (!this.isEdit) {
|
if (!this.isEdit) {
|
||||||
this.$closePage({
|
this.$closePage({
|
||||||
closeRoute: "/Maintenance/OtherExpensesLogAdd"
|
closeRoute: "/Maintenance/OtherExpensesLogCreate"
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
// 如果是编辑模式,关闭当前页面
|
// 如果是编辑模式,关闭当前页面
|
||||||
|
|
@ -314,6 +314,7 @@ export default {
|
||||||
this.$mk.success("保存成功");
|
this.$mk.success("保存成功");
|
||||||
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
||||||
this.back();
|
this.back();
|
||||||
|
this.$forceUpdate()
|
||||||
}
|
}
|
||||||
}).catch((a) => { // 失败回调
|
}).catch((a) => { // 失败回调
|
||||||
this.$mk.error(a.data.msg); // 显示错误信息
|
this.$mk.error(a.data.msg); // 显示错误信息
|
||||||
|
|
|
||||||
|
|
@ -317,6 +317,7 @@ export default {
|
||||||
this.$mk.success("保存成功");
|
this.$mk.success("保存成功");
|
||||||
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
||||||
this.back();
|
this.back();
|
||||||
|
this.$forceUpdate()
|
||||||
}
|
}
|
||||||
}).catch((a) => { // 失败回调
|
}).catch((a) => { // 失败回调
|
||||||
this.$mk.error(a.data.msg); // 显示错误信息
|
this.$mk.error(a.data.msg); // 显示错误信息
|
||||||
|
|
|
||||||
|
|
@ -224,7 +224,7 @@ export default {
|
||||||
// 如果是新增模式,关闭当前页面
|
// 如果是新增模式,关闭当前页面
|
||||||
if (!this.isEdit) {
|
if (!this.isEdit) {
|
||||||
this.$closePage({
|
this.$closePage({
|
||||||
closeRoute: "/SoilQualityMaterial/SoilQualityMaterialAliasAdd"
|
closeRoute: "/SoilQualityMaterial/SoilQualityMaterialAliasCreate"
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
// 如果是编辑模式,关闭当前页面
|
// 如果是编辑模式,关闭当前页面
|
||||||
|
|
@ -264,6 +264,7 @@ export default {
|
||||||
this.$mk.success("保存成功");
|
this.$mk.success("保存成功");
|
||||||
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
||||||
this.back();
|
this.back();
|
||||||
|
this.$forceUpdate()
|
||||||
}
|
}
|
||||||
}).catch((a) => { // 失败回调
|
}).catch((a) => { // 失败回调
|
||||||
this.$mk.error(a.data.msg); // 显示错误信息
|
this.$mk.error(a.data.msg); // 显示错误信息
|
||||||
|
|
|
||||||
|
|
@ -284,7 +284,7 @@ export default {
|
||||||
// 如果是新增模式,关闭当前页面
|
// 如果是新增模式,关闭当前页面
|
||||||
if (!this.isEdit) {
|
if (!this.isEdit) {
|
||||||
this.$closePage({
|
this.$closePage({
|
||||||
closeRoute: "/Tire/TireAdd"
|
closeRoute: "/Tire/TireCreate"
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
// 如果是编辑模式,关闭当前页面
|
// 如果是编辑模式,关闭当前页面
|
||||||
|
|
@ -330,6 +330,7 @@ export default {
|
||||||
this.$mk.success("保存成功");
|
this.$mk.success("保存成功");
|
||||||
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
||||||
this.back();
|
this.back();
|
||||||
|
this.$forceUpdate()
|
||||||
}
|
}
|
||||||
}).catch((a) => { // 失败回调
|
}).catch((a) => { // 失败回调
|
||||||
this.$mk.error(a.data.msg); // 显示错误信息
|
this.$mk.error(a.data.msg); // 显示错误信息
|
||||||
|
|
|
||||||
|
|
@ -642,7 +642,7 @@ export default {
|
||||||
// 如果是新增模式,关闭当前页面
|
// 如果是新增模式,关闭当前页面
|
||||||
if (!this.isEdit) {
|
if (!this.isEdit) {
|
||||||
this.$closePage({
|
this.$closePage({
|
||||||
closeRoute: "/TrainNumber/TrainNumberAdd"
|
closeRoute: "/TrainNumber/TrainNumberCreate"
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
// 如果是编辑模式,关闭当前页面
|
// 如果是编辑模式,关闭当前页面
|
||||||
|
|
@ -739,6 +739,7 @@ export default {
|
||||||
this.$mk.success("保存成功");
|
this.$mk.success("保存成功");
|
||||||
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
||||||
this.back();
|
this.back();
|
||||||
|
this.$forceUpdate()
|
||||||
}
|
}
|
||||||
}).catch((a) => { // 失败回调
|
}).catch((a) => { // 失败回调
|
||||||
this.$mk.error(a.data.msg); // 显示错误信息
|
this.$mk.error(a.data.msg); // 显示错误信息
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="page-body">
|
<div class="page-body">
|
||||||
|
|
||||||
<div class="page-header">
|
<!-- <div class="page-header">
|
||||||
<a-descriptions title="User Info">
|
<a-descriptions title="User Info">
|
||||||
<a-descriptions-item label="UserName">
|
<a-descriptions-item label="UserName">
|
||||||
Zhou Maomao
|
Zhou Maomao
|
||||||
|
|
@ -19,7 +19,7 @@
|
||||||
No. 18, Wantang Road, Xihu District, Hangzhou, Zhejiang, China
|
No. 18, Wantang Road, Xihu District, Hangzhou, Zhejiang, China
|
||||||
</a-descriptions-item>
|
</a-descriptions-item>
|
||||||
</a-descriptions>
|
</a-descriptions>
|
||||||
</div>
|
</div> -->
|
||||||
|
|
||||||
<vxe-form :data="formOptions.data" ref="xForm" :title-width="formOptions.titleWidth"
|
<vxe-form :data="formOptions.data" ref="xForm" :title-width="formOptions.titleWidth"
|
||||||
:title-align="formOptions.titleAlign" :rules="formOptions.rules" :items="formOptions.items" titleColon>
|
:title-align="formOptions.titleAlign" :rules="formOptions.rules" :items="formOptions.items" titleColon>
|
||||||
|
|
@ -324,6 +324,7 @@ export default {
|
||||||
this.$mk.success("保存成功");
|
this.$mk.success("保存成功");
|
||||||
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
if (!this.isEdit) { // 如果是新增模式,关闭当前页面
|
||||||
this.back();
|
this.back();
|
||||||
|
this.$forceUpdate()
|
||||||
}
|
}
|
||||||
}).catch((a) => { // 失败回调
|
}).catch((a) => { // 失败回调
|
||||||
this.$mk.error(a.data.msg); // 显示错误信息
|
this.$mk.error(a.data.msg); // 显示错误信息
|
||||||
|
|
|
||||||
|
|
@ -215,6 +215,7 @@ export default {
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
this.back();
|
this.back();
|
||||||
|
this.$forceUpdate()
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue