预览和变量

This commit is contained in:
xielue 2023-08-07 15:44:24 +08:00
parent addf7adad0
commit e1f160fe30
4 changed files with 37 additions and 18 deletions

View File

@ -214,7 +214,8 @@
<vxe-column field="price" title="单价" width="120"
:edit-render="{ name: '$input', props: { type: 'number' } }"></vxe-column>
<vxe-column field="amount_formula" title="金额" width="220" :edit-render="{ name: 'EditExpressions' }">
<vxe-column field="amount_formula" title="金额" width="220" :edit-render="{ name: 'EditExpressions' }"
:params="{ moreExpressionsList: getMoreExpressionsList }">
<template #default="{ row }">
<a-tooltip>
<template slot="title">

View File

@ -183,7 +183,8 @@
<vxe-column field="price" title="单价" width="120"
:edit-render="{ name: '$input', props: { type: 'number' } }"></vxe-column>
<vxe-column field="amount_formula" title="金额" width="220" :edit-render="{ name: 'EditExpressions' }">
<vxe-column field="amount_formula" title="金额" width="220" :edit-render="{ name: 'EditExpressions' }"
:params="{ moreExpressionsList: getMoreExpressionsList }">
<template #default="{ row }">
<a-tooltip>
<template slot="title">

View File

@ -4,7 +4,7 @@
<div class="topbar">
<a-button type="primary" @click="ok">保存</a-button>
<a-button type="primary" @click="ok({})">保存</a-button>
<a-button @click="selectScheme">导入方案</a-button>
<a-button @click="cancel">取消</a-button>
<a-button @click="previewScheme">预览方案</a-button>
@ -108,7 +108,8 @@
<vxe-column field="price" title="单价" width="120"
:edit-render="{ name: '$input', props: { type: 'number' } }"></vxe-column>
<vxe-column field="amount_formula" title="金额(公式)" width="220" :edit-render="{ name: 'EditExpressions' }">
<vxe-column field="amount_formula" title="金额(公式)" width="220" :edit-render="{ name: 'EditExpressions' }"
:params="{ moreExpressionsList: getMoreExpressionsList }">
</vxe-column>
</vxe-table>
@ -1573,7 +1574,7 @@ export default {
},
//
ok() {
ok({ callback }) {
let save = () => {
@ -1643,10 +1644,15 @@ export default {
data: postdata,
useBigInt: true,
}).then(() => { //
if (typeof (callback) == "function") {
callback();
} else {
this.$mk.success("保存成功");
if (!this.isEdit) { //
this.back();
}
}
}).catch((a) => { //
this.$mk.error(a.data.msg); //
});
@ -1705,8 +1711,19 @@ export default {
this.scheme_load();
},
previewScheme() {
this.ok({
callback: () => {
let dataId = this.getDataId();
this.$openPage("/BathroomQuotation/BathroomQuotationUpdate/d" + dataId); //
let pageUrl = "/BathroomQuotation/BathroomQuotationUpdate/d" + dataId;
this.$closePage({
closeRoute: "/BathroomQuotation/BathroomQuotationUpdate"
});
this.$openPage(pageUrl); //
}
})
},
confirmSelectScheme() {
let row = this.$refs.scheme_grid.getCurrentRecord(); //

View File

@ -56,7 +56,7 @@ routerMap[FunName + 'Update']= {
path: `/${FunName}/${FunName}Update/:id`,
component: () => import(`@/pages/Middle/bathroom/BathroomQuotation/BathroomQuotation/Edit`),
meta: {
invisible: true,
invisible: true
},
authority: {
permission: [],