客户需求保存
This commit is contained in:
@ -186,11 +186,11 @@
|
|||||||
const res = await getCompDept(userInfo.id)
|
const res = await getCompDept(userInfo.id)
|
||||||
formState.value.cuCode = res?.comp?.code
|
formState.value.cuCode = res?.comp?.code
|
||||||
formState.value.comId = res?.comp?.id
|
formState.value.comId = res?.comp?.id
|
||||||
}
|
|
||||||
if (pageType.value!=='view' && pageType.value!=='compare') {
|
|
||||||
const res1 = await getLngPngDemandRate({}) || []
|
const res1 = await getLngPngDemandRate({}) || []
|
||||||
formState.value.rateM3Gj = res1[0].rateM3Gj
|
formState.value.rateM3Gj = res1[0].rateM3Gj
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
})
|
})
|
||||||
async function numChange (k, record) {
|
async function numChange (k, record) {
|
||||||
if (k == 'qtyDemandGj') {
|
if (k == 'qtyDemandGj') {
|
||||||
|
|||||||
@ -39,7 +39,7 @@
|
|||||||
import type { Rule } from 'ant-design-vue/es/form';
|
import type { Rule } from 'ant-design-vue/es/form';
|
||||||
import { getDictionary } from '/@/api/sales/Customer';
|
import { getDictionary } from '/@/api/sales/Customer';
|
||||||
import { useModal } from '/@/components/Modal';
|
import { useModal } from '/@/components/Modal';
|
||||||
import { addLngPngDemand, submitLngPngDemand,getLngPngDemand,getLngPngDemandUpdate,getLngPngDemandCompare } from '/@/api/dayPlan/Demand';
|
import { addLngPngDemand, submitLngPngDemand,getLngPngDemand,getLngPngDemandUpdate,getLngPngDemandCompare,updateLngPngDemand } from '/@/api/dayPlan/Demand';
|
||||||
import dayjs from 'dayjs';
|
import dayjs from 'dayjs';
|
||||||
import { getAppEnvConfig } from '/@/utils/env';
|
import { getAppEnvConfig } from '/@/utils/env';
|
||||||
import { message } from 'ant-design-vue';
|
import { message } from 'ant-design-vue';
|
||||||
@ -172,8 +172,10 @@
|
|||||||
lngPngDemandPurList:arr
|
lngPngDemandPurList:arr
|
||||||
}
|
}
|
||||||
spinning.value = true;
|
spinning.value = true;
|
||||||
let request = ''
|
let request = submitLngPngDemand
|
||||||
request = type == 'save'? addLngPngDemand : submitLngPngDemand
|
if (type == 'save') {
|
||||||
|
request = !pageId.value ? addLngPngDemand : updateLngPngDemand
|
||||||
|
}
|
||||||
await request(obj)
|
await request(obj)
|
||||||
spinning.value = false;
|
spinning.value = false;
|
||||||
notification.success({
|
notification.success({
|
||||||
|
|||||||
@ -206,7 +206,7 @@
|
|||||||
formPath: 'dayPlan/Demand',
|
formPath: 'dayPlan/Demand',
|
||||||
formName: formName,
|
formName: formName,
|
||||||
formId:currentRoute.value.meta.formId,
|
formId:currentRoute.value.meta.formId,
|
||||||
id: record.Id,
|
id: record.id,
|
||||||
type:'view'
|
type:'view'
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user