食堂进销
This commit is contained in:
1 parent
971fe011cc
commit
c8fc7b04a5
2 files changed
+16
-11
No files matched your search
@@ -183,14 +183,20 @@ const getInitData = async () => {
|
|||||||
baseForm.id = undefined
|
baseForm.id = undefined
|
||||||
const id = props.formId
|
const id = props.formId
|
||||||
if (id) {
|
if (id) {
|
||||||
// loading.value = true
|
loading.value = true
|
||||||
// // 获取清单数据
|
// 获取清单数据
|
||||||
// const [cgPlanData] = await Promise.allSettled([getObj(id)])
|
const [res] = await Promise.allSettled([getObj(id)])
|
||||||
// .then((results) => results.map((result) => (result.status === "fulfilled" ? result.value : null)))
|
.then((results) => results.map((result) => (result.status === "fulfilled" ? result.value : null)))
|
||||||
// .finally(() => (loading.value = false))
|
.finally(() => (loading.value = false))
|
||||||
// if (cgPlanData && cgPlanData.code === 0) {
|
if (res && res.code == 0) {
|
||||||
// Object.assign(baseForm, cgPlanData.data)
|
Object.assign(baseForm, res.data, { items: "" })
|
||||||
// }
|
state.itemTableForm = res.data.items.map((item: any) => ({
|
||||||
|
...item,
|
||||||
|
realPrice: displayPrice(item.realPrice, ""),
|
||||||
|
totalAmount: displayPrice(item.totalNumber, ""),
|
||||||
|
unitPrice: displayPrice(item.unitPrice, ""),
|
||||||
|
}))
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
loading.value = true
|
loading.value = true
|
||||||
// 获取采购入库编号
|
// 获取采购入库编号
|
||||||
@@ -260,7 +266,6 @@ const tableFormItems = () => {
|
|||||||
totalAmount: storePrice((Number(item.quantity || 0) * Number(item.realPrice || 0)).toFixed(2)),
|
totalAmount: storePrice((Number(item.quantity || 0) * Number(item.realPrice || 0)).toFixed(2)),
|
||||||
stock: item.stock,
|
stock: item.stock,
|
||||||
remark: item.remark,
|
remark: item.remark,
|
||||||
orderType: 1,
|
|
||||||
totalNumber: item.totalNumber,
|
totalNumber: item.totalNumber,
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -60,7 +60,7 @@
|
|||||||
<el-table-column type="index" label="#" width="50" />
|
<el-table-column type="index" label="#" width="50" />
|
||||||
<el-table-column prop="inventoryCode" label="单据编号" show-overflow-tooltip />
|
<el-table-column prop="inventoryCode" label="单据编号" show-overflow-tooltip />
|
||||||
<el-table-column prop="inventoryDate" label="单据日期" show-overflow-tooltip />
|
<el-table-column prop="inventoryDate" label="单据日期" show-overflow-tooltip />
|
||||||
<el-table-column prop="productName" label="商品" show-overflow-tooltip />
|
<el-table-column prop="productName" label="商品" show-overflow-tooltip />
|
||||||
<el-table-column prop="handlerUserName" label="经办人" show-overflow-tooltip />
|
<el-table-column prop="handlerUserName" label="经办人" show-overflow-tooltip />
|
||||||
<!-- <el-table-column prop="checkStatus" label="审批状态" show-overflow-tooltip /> -->
|
<!-- <el-table-column prop="checkStatus" label="审批状态" show-overflow-tooltip /> -->
|
||||||
<!-- <el-table-column prop="checkUserId" label="审批人id" show-overflow-tooltip /> -->
|
<!-- <el-table-column prop="checkUserId" label="审批人id" show-overflow-tooltip /> -->
|
||||||
@@ -174,6 +174,6 @@ const handleDelete = async (ids: string[]) => {
|
|||||||
const formClose = () => {
|
const formClose = () => {
|
||||||
formState.showForm = false
|
formState.showForm = false
|
||||||
formState.formId = undefined
|
formState.formId = undefined
|
||||||
fetchList()
|
getDataList()
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
Reference in new issue
Block a user