Merge remote-tracking branch 'origin/master'
This commit is contained in:
commit
7cab441b5e
8 files changed
+47
-87
No files matched your search
File renamed without changes.
@@ -174,9 +174,8 @@
|
|||||||
<!-- 商品选择对话框 -->
|
<!-- 商品选择对话框 -->
|
||||||
<select-dialog ref="erpSpuSelectDialogRef" :selectedRows="state.editableTableData" @getSelectedRows="getSelectedRows" />
|
<select-dialog ref="erpSpuSelectDialogRef" :selectedRows="state.editableTableData" @getSelectedRows="getSelectedRows" />
|
||||||
|
|
||||||
<linkCodeDialog
|
<link-code-dialog
|
||||||
ref="linkCgPlanDialogRef"
|
ref="linkCodeDialogRef"
|
||||||
v-model="state.linkCgPlanDialogVisible"
|
|
||||||
title="关联采购订单"
|
title="关联采购订单"
|
||||||
:getTableData="() => getCgInventoryPage({ inventoryType: '3' })"
|
:getTableData="() => getCgInventoryPage({ inventoryType: '3' })"
|
||||||
@getSelectedLinkCode="getSelectedLinkCode"
|
@getSelectedLinkCode="getSelectedLinkCode"
|
||||||
@@ -192,7 +191,7 @@ import { getPlanCode, getErpSpuSimpleAll, getCgInventoryPage } from "/@/api/supe
|
|||||||
import { VxeTableEvents, VxeTablePropTypes, type VxeTableInstance } from "vxe-table"
|
import { VxeTableEvents, VxeTablePropTypes, type VxeTableInstance } from "vxe-table"
|
||||||
import { formatDate } from "/@/utils/formatTime"
|
import { formatDate } from "/@/utils/formatTime"
|
||||||
import { Search } from "@element-plus/icons-vue"
|
import { Search } from "@element-plus/icons-vue"
|
||||||
import linkCodeDialog from "/@/views/supermarketerp/components/linkCodeDialog.vue"
|
import LinkCodeDialog from "/@/views/supermarketerp/components/link-code-dialog.vue"
|
||||||
import { displayPrice } from "/@/utils/formatMoney"
|
import { displayPrice } from "/@/utils/formatMoney"
|
||||||
import { tablePrint } from "../../supermarketUtils"
|
import { tablePrint } from "../../supermarketUtils"
|
||||||
import { useSmProcessFormAction } from "/@/hooks/smProcessFormAction"
|
import { useSmProcessFormAction } from "/@/hooks/smProcessFormAction"
|
||||||
@@ -214,7 +213,7 @@ const emit = defineEmits(["close"])
|
|||||||
const loading = ref(false) // 采购计划加载
|
const loading = ref(false) // 采购计划加载
|
||||||
const disabled = ref(false)
|
const disabled = ref(false)
|
||||||
const erpSpuSelectDialogRef = ref() // 商品选择对话框ref
|
const erpSpuSelectDialogRef = ref() // 商品选择对话框ref
|
||||||
const linkCgPlanDialogRef = ref() // 关联采购申请单对话框ref
|
const linkCodeDialogRef = ref() // 关联采购申请单对话框ref
|
||||||
const baseDataFormRef = ref() // 基本数据表单ref
|
const baseDataFormRef = ref() // 基本数据表单ref
|
||||||
const editableTableRef = ref<VxeTableInstance<any>>() // 可编辑表格ref
|
const editableTableRef = ref<VxeTableInstance<any>>() // 可编辑表格ref
|
||||||
const baseDataInfoRef = ref() // 基本信息ref
|
const baseDataInfoRef = ref() // 基本信息ref
|
||||||
@@ -238,16 +237,11 @@ const state = reactive<{
|
|||||||
erpSpuItemsMemo: any[]
|
erpSpuItemsMemo: any[]
|
||||||
selectedRowsErpSpuIds: string[]
|
selectedRowsErpSpuIds: string[]
|
||||||
erpSpuSimpleAll: any
|
erpSpuSimpleAll: any
|
||||||
linkCodeVisible: boolean
|
|
||||||
linkCgPlanDialogVisible: boolean
|
|
||||||
}>({
|
}>({
|
||||||
editableTableData: [], // 可编辑表格数据
|
editableTableData: [], // 可编辑表格数据
|
||||||
erpSpuItemsMemo: [], // 请求到的可编辑表格商品数据的缓存
|
erpSpuItemsMemo: [], // 请求到的可编辑表格商品数据的缓存
|
||||||
selectedRowsErpSpuIds: [], // 可编辑表格已选行的ErpSpuId
|
selectedRowsErpSpuIds: [], // 可编辑表格已选行的ErpSpuId
|
||||||
erpSpuSimpleAll: [], // 简要商品列表
|
erpSpuSimpleAll: [], // 简要商品列表
|
||||||
|
|
||||||
linkCodeVisible: false, // 关联采购申请单对话框开关
|
|
||||||
linkCgPlanDialogVisible: false, // 关联采购申请单对话框开关
|
|
||||||
})
|
})
|
||||||
|
|
||||||
// 基本信息表单校验规则
|
// 基本信息表单校验规则
|
||||||
@@ -299,7 +293,7 @@ const getInitData = async () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 点击关联采购申请编号
|
// 点击关联采购申请编号
|
||||||
const handleClickLinkCode = () => linkCgPlanDialogRef.value.openLinkCodeDialog(3)
|
const handleClickLinkCode = () => linkCodeDialogRef.value.openLinkCodeDialog(3)
|
||||||
|
|
||||||
// 获取选择的采购申请
|
// 获取选择的采购申请
|
||||||
const getSelectedLinkCode = (selectionRows: any) => {
|
const getSelectedLinkCode = (selectionRows: any) => {
|
||||||
@@ -308,7 +302,6 @@ const getSelectedLinkCode = (selectionRows: any) => {
|
|||||||
baseDataForm.linkCode = selectionRows.inventoryCode
|
baseDataForm.linkCode = selectionRows.inventoryCode
|
||||||
state.editableTableData = selectionRows.items
|
state.editableTableData = selectionRows.items
|
||||||
state.erpSpuItemsMemo = selectionRows.items
|
state.erpSpuItemsMemo = selectionRows.items
|
||||||
state.linkCgPlanDialogVisible = false
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 删除选中的行
|
// 删除选中的行
|
||||||
|
|||||||
@@ -179,9 +179,8 @@
|
|||||||
<!-- 商品选择对话框 -->
|
<!-- 商品选择对话框 -->
|
||||||
<select-dialog ref="erpSpuSelectDialogRef" :selectedRows="state.editableTableData" @getSelectedRows="getSelectedRows" />
|
<select-dialog ref="erpSpuSelectDialogRef" :selectedRows="state.editableTableData" @getSelectedRows="getSelectedRows" />
|
||||||
|
|
||||||
<linkCodeDialog
|
<link-code-dialog
|
||||||
ref="linkCgPlanDialogRef"
|
ref="linkCodeDialogRef"
|
||||||
v-model="state.linkCgPlanDialogVisible"
|
|
||||||
title="关联补货申请"
|
title="关联补货申请"
|
||||||
:getTableData="getCgsqPage"
|
:getTableData="getCgsqPage"
|
||||||
@getSelectedLinkCode="getSelectedLinkCode"
|
@getSelectedLinkCode="getSelectedLinkCode"
|
||||||
@@ -197,7 +196,7 @@ import { getPlanCode, getErpSpuSimpleAll, getCgsqPage } from "/@/api/supermarket
|
|||||||
import { VxeTableEvents, VxeTablePropTypes, type VxeTableInstance } from "vxe-table"
|
import { VxeTableEvents, VxeTablePropTypes, type VxeTableInstance } from "vxe-table"
|
||||||
import { formatDate } from "/@/utils/formatTime"
|
import { formatDate } from "/@/utils/formatTime"
|
||||||
import { Search } from "@element-plus/icons-vue"
|
import { Search } from "@element-plus/icons-vue"
|
||||||
import linkCodeDialog from "/@/views/supermarketerp/components/linkCodeDialog.vue"
|
import LinkCodeDialog from "/@/views/supermarketerp/components/link-code-dialog.vue"
|
||||||
import { displayPrice } from "/@/utils/formatMoney"
|
import { displayPrice } from "/@/utils/formatMoney"
|
||||||
import { tablePrint } from "../../supermarketUtils"
|
import { tablePrint } from "../../supermarketUtils"
|
||||||
import { useSmProcessFormAction } from "/@/hooks/smProcessFormAction"
|
import { useSmProcessFormAction } from "/@/hooks/smProcessFormAction"
|
||||||
@@ -219,7 +218,7 @@ const emit = defineEmits(["close"])
|
|||||||
const loading = ref(false) // 采购计划加载
|
const loading = ref(false) // 采购计划加载
|
||||||
const disabled = ref(false)
|
const disabled = ref(false)
|
||||||
const erpSpuSelectDialogRef = ref() // 商品选择对话框ref
|
const erpSpuSelectDialogRef = ref() // 商品选择对话框ref
|
||||||
const linkCgPlanDialogRef = ref() // 关联采购申请单对话框ref
|
const linkCodeDialogRef = ref() // 关联采购申请单对话框ref
|
||||||
const baseDataFormRef = ref() // 基本数据表单ref
|
const baseDataFormRef = ref() // 基本数据表单ref
|
||||||
const editableTableRef = ref<VxeTableInstance<any>>() // 可编辑表格ref
|
const editableTableRef = ref<VxeTableInstance<any>>() // 可编辑表格ref
|
||||||
const baseDataInfoRef = ref() // 基本信息ref
|
const baseDataInfoRef = ref() // 基本信息ref
|
||||||
@@ -244,15 +243,11 @@ const state = reactive<{
|
|||||||
erpSpuItemsMemo: any[]
|
erpSpuItemsMemo: any[]
|
||||||
selectedRowsErpSpuIds: string[]
|
selectedRowsErpSpuIds: string[]
|
||||||
erpSpuSimpleAll: any
|
erpSpuSimpleAll: any
|
||||||
linkCodeVisible: boolean
|
|
||||||
linkCgPlanDialogVisible: boolean
|
|
||||||
}>({
|
}>({
|
||||||
editableTableData: [], // 可编辑表格数据
|
editableTableData: [], // 可编辑表格数据
|
||||||
erpSpuItemsMemo: [], // 请求到的可编辑表格商品数据的缓存
|
erpSpuItemsMemo: [], // 请求到的可编辑表格商品数据的缓存
|
||||||
selectedRowsErpSpuIds: [], // 可编辑表格已选行的ErpSpuId
|
selectedRowsErpSpuIds: [], // 可编辑表格已选行的ErpSpuId
|
||||||
erpSpuSimpleAll: [], // 简要商品列表
|
erpSpuSimpleAll: [], // 简要商品列表
|
||||||
linkCodeVisible: false, // 关联采购申请单对话框开关
|
|
||||||
linkCgPlanDialogVisible: false, // 关联采购申请单对话框开关
|
|
||||||
})
|
})
|
||||||
|
|
||||||
// 基本信息表单校验规则
|
// 基本信息表单校验规则
|
||||||
@@ -304,7 +299,7 @@ const getInitData = async () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 点击关联采购申请编号
|
// 点击关联采购申请编号
|
||||||
const handleClickLinkCode = () => linkCgPlanDialogRef.value.openLinkCodeDialog(1)
|
const handleClickLinkCode = () => linkCodeDialogRef.value.openLinkCodeDialog(1)
|
||||||
|
|
||||||
// 获取选择的采购申请
|
// 获取选择的采购申请
|
||||||
const getSelectedLinkCode = (selectionRows: any) => {
|
const getSelectedLinkCode = (selectionRows: any) => {
|
||||||
@@ -313,7 +308,6 @@ const getSelectedLinkCode = (selectionRows: any) => {
|
|||||||
baseDataForm.linkCode = selectionRows.planCode
|
baseDataForm.linkCode = selectionRows.planCode
|
||||||
state.editableTableData = selectionRows.items
|
state.editableTableData = selectionRows.items
|
||||||
state.erpSpuItemsMemo = selectionRows.items
|
state.erpSpuItemsMemo = selectionRows.items
|
||||||
state.linkCgPlanDialogVisible = false
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 删除选中的行
|
// 删除选中的行
|
||||||
|
|||||||
@@ -180,9 +180,8 @@
|
|||||||
<!-- 商品选择对话框 -->
|
<!-- 商品选择对话框 -->
|
||||||
<select-dialog ref="erpSpuSelectDialogRef" :selectedRows="state.editableTableData" @getSelectedRows="getSelectedRows" />
|
<select-dialog ref="erpSpuSelectDialogRef" :selectedRows="state.editableTableData" @getSelectedRows="getSelectedRows" />
|
||||||
|
|
||||||
<linkCodeDialog
|
<link-code-dialog
|
||||||
ref="linkCgPlanDialogRef"
|
ref="linkCodeDialogRef"
|
||||||
v-model="state.linkCgPlanDialogVisible"
|
|
||||||
title="关联采购订单"
|
title="关联采购订单"
|
||||||
:getTableData="getCgddPage"
|
:getTableData="getCgddPage"
|
||||||
@getSelectedLinkCode="getSelectedLinkCode"
|
@getSelectedLinkCode="getSelectedLinkCode"
|
||||||
@@ -198,7 +197,7 @@ import { getPlanCode, getErpSpuSimpleAll, getCgddPage } from "/@/api/supermarket
|
|||||||
import { VxeTableEvents, VxeTablePropTypes, type VxeTableInstance } from "vxe-table"
|
import { VxeTableEvents, VxeTablePropTypes, type VxeTableInstance } from "vxe-table"
|
||||||
import { formatDate } from "/@/utils/formatTime"
|
import { formatDate } from "/@/utils/formatTime"
|
||||||
import { Search } from "@element-plus/icons-vue"
|
import { Search } from "@element-plus/icons-vue"
|
||||||
import linkCodeDialog from "/@/views/supermarketerp/components/linkCodeDialog.vue"
|
import LinkCodeDialog from "/@/views/supermarketerp/components/link-code-dialog.vue"
|
||||||
import { displayPrice, storePrice } from "/@/utils/formatMoney"
|
import { displayPrice, storePrice } from "/@/utils/formatMoney"
|
||||||
import { tablePrint } from "../../supermarketUtils"
|
import { tablePrint } from "../../supermarketUtils"
|
||||||
import { useSmProcessFormAction } from "/@/hooks/smProcessFormAction"
|
import { useSmProcessFormAction } from "/@/hooks/smProcessFormAction"
|
||||||
@@ -220,7 +219,7 @@ const emit = defineEmits(["close"])
|
|||||||
const loading = ref(false) // 采购计划加载
|
const loading = ref(false) // 采购计划加载
|
||||||
const disabled = ref(false)
|
const disabled = ref(false)
|
||||||
const erpSpuSelectDialogRef = ref() // 商品选择对话框ref
|
const erpSpuSelectDialogRef = ref() // 商品选择对话框ref
|
||||||
const linkCgPlanDialogRef = ref() // 关联采购申请单对话框ref
|
const linkCodeDialogRef = ref() // 关联采购申请单对话框ref
|
||||||
const baseDataFormRef = ref() // 基本数据表单ref
|
const baseDataFormRef = ref() // 基本数据表单ref
|
||||||
const editableTableRef = ref<VxeTableInstance<any>>() // 可编辑表格ref
|
const editableTableRef = ref<VxeTableInstance<any>>() // 可编辑表格ref
|
||||||
const baseDataInfoRef = ref() // 基本信息ref
|
const baseDataInfoRef = ref() // 基本信息ref
|
||||||
@@ -244,16 +243,11 @@ const state = reactive<{
|
|||||||
erpSpuItemsMemo: any[]
|
erpSpuItemsMemo: any[]
|
||||||
selectedRowsErpSpuIds: string[]
|
selectedRowsErpSpuIds: string[]
|
||||||
erpSpuSimpleAll: any
|
erpSpuSimpleAll: any
|
||||||
linkCodeVisible: boolean
|
|
||||||
linkCgPlanDialogVisible: boolean
|
|
||||||
}>({
|
}>({
|
||||||
editableTableData: [], // 可编辑表格数据
|
editableTableData: [], // 可编辑表格数据
|
||||||
erpSpuItemsMemo: [], // 请求到的可编辑表格商品数据的缓存
|
erpSpuItemsMemo: [], // 请求到的可编辑表格商品数据的缓存
|
||||||
selectedRowsErpSpuIds: [], // 可编辑表格已选行的ErpSpuId
|
selectedRowsErpSpuIds: [], // 可编辑表格已选行的ErpSpuId
|
||||||
erpSpuSimpleAll: [], // 简要商品列表
|
erpSpuSimpleAll: [], // 简要商品列表
|
||||||
|
|
||||||
linkCodeVisible: false, // 关联采购申请单对话框开关
|
|
||||||
linkCgPlanDialogVisible: false, // 关联采购申请单对话框开关
|
|
||||||
})
|
})
|
||||||
|
|
||||||
// 基本信息表单校验规则
|
// 基本信息表单校验规则
|
||||||
@@ -317,7 +311,7 @@ const getInitData = async () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 点击关联采购申请编号
|
// 点击关联采购申请编号
|
||||||
const handleClickLinkCode = () => linkCgPlanDialogRef.value.openLinkCodeDialog(2)
|
const handleClickLinkCode = () => linkCodeDialogRef.value.openLinkCodeDialog(2)
|
||||||
|
|
||||||
// 获取选择的采购申请
|
// 获取选择的采购申请
|
||||||
const getSelectedLinkCode = (selectionRows: any) => {
|
const getSelectedLinkCode = (selectionRows: any) => {
|
||||||
@@ -334,7 +328,6 @@ const getSelectedLinkCode = (selectionRows: any) => {
|
|||||||
unitObj: {},
|
unitObj: {},
|
||||||
realPrice: displayPrice(item.purchasePrice, ""),
|
realPrice: displayPrice(item.purchasePrice, ""),
|
||||||
}))
|
}))
|
||||||
state.linkCgPlanDialogVisible = false
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 删除选中的行
|
// 删除选中的行
|
||||||
|
|||||||
@@ -206,9 +206,8 @@
|
|||||||
<!-- 商品选择对话框 -->
|
<!-- 商品选择对话框 -->
|
||||||
<select-dialog ref="erpSpuSelectDialogRef" :selectedRows="state.editableTableData" @getSelectedRows="getSelectedRows" />
|
<select-dialog ref="erpSpuSelectDialogRef" :selectedRows="state.editableTableData" @getSelectedRows="getSelectedRows" />
|
||||||
|
|
||||||
<linkCodeDialog
|
<link-code-dialog
|
||||||
ref="linkCgPlanDialogRef"
|
ref="linkCodeDialogRef"
|
||||||
v-model="state.linkCgPlanDialogVisible"
|
|
||||||
title="关联采购订单"
|
title="关联采购订单"
|
||||||
:getTableData="() => getCgInventoryPage({ inventoryType: '5' })"
|
:getTableData="() => getCgInventoryPage({ inventoryType: '5' })"
|
||||||
@getSelectedLinkCode="getSelectedLinkCode"
|
@getSelectedLinkCode="getSelectedLinkCode"
|
||||||
@@ -224,7 +223,7 @@ import { getPlanCode, getErpSpuSimpleAll, getCgInventoryPage } from "/@/api/supe
|
|||||||
import { VxeTableEvents, VxeTablePropTypes, type VxeTableInstance } from "vxe-table"
|
import { VxeTableEvents, VxeTablePropTypes, type VxeTableInstance } from "vxe-table"
|
||||||
import { formatDate } from "/@/utils/formatTime"
|
import { formatDate } from "/@/utils/formatTime"
|
||||||
import { Search } from "@element-plus/icons-vue"
|
import { Search } from "@element-plus/icons-vue"
|
||||||
import linkCodeDialog from "/@/views/supermarketerp/components/linkCodeDialog.vue"
|
import LinkCodeDialog from "/@/views/supermarketerp/components/link-code-dialog.vue"
|
||||||
import { displayPrice, storePrice } from "/@/utils/formatMoney"
|
import { displayPrice, storePrice } from "/@/utils/formatMoney"
|
||||||
import { tablePrint } from "../../supermarketUtils"
|
import { tablePrint } from "../../supermarketUtils"
|
||||||
import { useSmProcessFormAction } from "/@/hooks/smProcessFormAction"
|
import { useSmProcessFormAction } from "/@/hooks/smProcessFormAction"
|
||||||
@@ -246,7 +245,7 @@ const emit = defineEmits(["close"])
|
|||||||
const loading = ref(false) // 采购计划加载
|
const loading = ref(false) // 采购计划加载
|
||||||
const disabled = ref(false)
|
const disabled = ref(false)
|
||||||
const erpSpuSelectDialogRef = ref() // 商品选择对话框ref
|
const erpSpuSelectDialogRef = ref() // 商品选择对话框ref
|
||||||
const linkCgPlanDialogRef = ref() // 关联采购申请单对话框ref
|
const linkCodeDialogRef = ref() // 关联采购申请单对话框ref
|
||||||
const baseDataFormRef = ref() // 基本数据表单ref
|
const baseDataFormRef = ref() // 基本数据表单ref
|
||||||
const editableTableRef = ref<VxeTableInstance<any>>() // 可编辑表格ref
|
const editableTableRef = ref<VxeTableInstance<any>>() // 可编辑表格ref
|
||||||
const baseDataInfoRef = ref() // 基本信息ref
|
const baseDataInfoRef = ref() // 基本信息ref
|
||||||
@@ -271,16 +270,11 @@ const state = reactive<{
|
|||||||
erpSpuItemsMemo: any[]
|
erpSpuItemsMemo: any[]
|
||||||
selectedRowsErpSpuIds: string[]
|
selectedRowsErpSpuIds: string[]
|
||||||
erpSpuSimpleAll: any
|
erpSpuSimpleAll: any
|
||||||
linkCodeVisible: boolean
|
|
||||||
linkCgPlanDialogVisible: boolean
|
|
||||||
}>({
|
}>({
|
||||||
editableTableData: [], // 可编辑表格数据
|
editableTableData: [], // 可编辑表格数据
|
||||||
erpSpuItemsMemo: [], // 请求到的可编辑表格商品数据的缓存
|
erpSpuItemsMemo: [], // 请求到的可编辑表格商品数据的缓存
|
||||||
selectedRowsErpSpuIds: [], // 可编辑表格已选行的ErpSpuId
|
selectedRowsErpSpuIds: [], // 可编辑表格已选行的ErpSpuId
|
||||||
erpSpuSimpleAll: [], // 简要商品列表
|
erpSpuSimpleAll: [], // 简要商品列表
|
||||||
|
|
||||||
linkCodeVisible: false, // 关联采购申请单对话框开关
|
|
||||||
linkCgPlanDialogVisible: false, // 关联采购申请单对话框开关
|
|
||||||
})
|
})
|
||||||
|
|
||||||
// 合计金额表单数据
|
// 合计金额表单数据
|
||||||
@@ -345,7 +339,7 @@ const getInitData = async () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 点击关联采购申请编号
|
// 点击关联采购申请编号
|
||||||
const handleClickLinkCode = () => linkCgPlanDialogRef.value.openLinkCodeDialog(3)
|
const handleClickLinkCode = () => linkCodeDialogRef.value.openLinkCodeDialog(3)
|
||||||
|
|
||||||
// 获取选择的采购申请
|
// 获取选择的采购申请
|
||||||
const getSelectedLinkCode = (selectionRows: any) => {
|
const getSelectedLinkCode = (selectionRows: any) => {
|
||||||
@@ -354,7 +348,6 @@ const getSelectedLinkCode = (selectionRows: any) => {
|
|||||||
baseDataForm.linkCode = selectionRows.inventoryCode
|
baseDataForm.linkCode = selectionRows.inventoryCode
|
||||||
state.editableTableData = selectionRows.items
|
state.editableTableData = selectionRows.items
|
||||||
state.erpSpuItemsMemo = selectionRows.items
|
state.erpSpuItemsMemo = selectionRows.items
|
||||||
state.linkCgPlanDialogVisible = false
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 删除选中的行
|
// 删除选中的行
|
||||||
|
|||||||
@@ -198,9 +198,8 @@
|
|||||||
<!-- 商品选择对话框 -->
|
<!-- 商品选择对话框 -->
|
||||||
<select-dialog ref="erpSpuSelectDialogRef" :selectedRows="state.editableTableData" @getSelectedRows="getSelectedRows" />
|
<select-dialog ref="erpSpuSelectDialogRef" :selectedRows="state.editableTableData" @getSelectedRows="getSelectedRows" />
|
||||||
|
|
||||||
<linkCodeDialog
|
<link-code-dialog
|
||||||
ref="linkCgPlanDialogRef"
|
ref="linkCodeDialogRef"
|
||||||
v-model="state.linkCgPlanDialogVisible"
|
|
||||||
title="关联采购订单"
|
title="关联采购订单"
|
||||||
:getTableData="getCgddPage"
|
:getTableData="getCgddPage"
|
||||||
@getSelectedLinkCode="getSelectedLinkCode"
|
@getSelectedLinkCode="getSelectedLinkCode"
|
||||||
@@ -216,7 +215,7 @@ import { getPlanCode, getErpSpuSimpleAll, getCgddPage } from "/@/api/supermarket
|
|||||||
import { VxeTableEvents, VxeTablePropTypes, type VxeTableInstance } from "vxe-table"
|
import { VxeTableEvents, VxeTablePropTypes, type VxeTableInstance } from "vxe-table"
|
||||||
import { formatDate } from "/@/utils/formatTime"
|
import { formatDate } from "/@/utils/formatTime"
|
||||||
import { Search } from "@element-plus/icons-vue"
|
import { Search } from "@element-plus/icons-vue"
|
||||||
import linkCodeDialog from "/@/views/supermarketerp/components/linkCodeDialog.vue"
|
import LinkCodeDialog from "/@/views/supermarketerp/components/link-code-dialog.vue"
|
||||||
import { displayPrice, storePrice } from "/@/utils/formatMoney"
|
import { displayPrice, storePrice } from "/@/utils/formatMoney"
|
||||||
import { tablePrint } from "../../supermarketUtils"
|
import { tablePrint } from "../../supermarketUtils"
|
||||||
import { useSmProcessFormAction } from "/@/hooks/smProcessFormAction"
|
import { useSmProcessFormAction } from "/@/hooks/smProcessFormAction"
|
||||||
@@ -238,7 +237,7 @@ const emit = defineEmits(["close"])
|
|||||||
const loading = ref(false) // 采购计划加载
|
const loading = ref(false) // 采购计划加载
|
||||||
const disabled = ref(false)
|
const disabled = ref(false)
|
||||||
const erpSpuSelectDialogRef = ref() // 商品选择对话框ref
|
const erpSpuSelectDialogRef = ref() // 商品选择对话框ref
|
||||||
const linkCgPlanDialogRef = ref() // 关联采购申请单对话框ref
|
const linkCodeDialogRef = ref() // 关联采购申请单对话框ref
|
||||||
const baseDataFormRef = ref() // 基本数据表单ref
|
const baseDataFormRef = ref() // 基本数据表单ref
|
||||||
const editableTableRef = ref<VxeTableInstance<any>>() // 可编辑表格ref
|
const editableTableRef = ref<VxeTableInstance<any>>() // 可编辑表格ref
|
||||||
const baseDataInfoRef = ref() // 基本信息ref
|
const baseDataInfoRef = ref() // 基本信息ref
|
||||||
@@ -263,16 +262,11 @@ const state = reactive<{
|
|||||||
erpSpuItemsMemo: any[]
|
erpSpuItemsMemo: any[]
|
||||||
selectedRowsErpSpuIds: string[]
|
selectedRowsErpSpuIds: string[]
|
||||||
erpSpuSimpleAll: any
|
erpSpuSimpleAll: any
|
||||||
linkCodeVisible: boolean
|
|
||||||
linkCgPlanDialogVisible: boolean
|
|
||||||
}>({
|
}>({
|
||||||
editableTableData: [], // 可编辑表格数据
|
editableTableData: [], // 可编辑表格数据
|
||||||
erpSpuItemsMemo: [], // 请求到的可编辑表格商品数据的缓存
|
erpSpuItemsMemo: [], // 请求到的可编辑表格商品数据的缓存
|
||||||
selectedRowsErpSpuIds: [], // 可编辑表格已选行的ErpSpuId
|
selectedRowsErpSpuIds: [], // 可编辑表格已选行的ErpSpuId
|
||||||
erpSpuSimpleAll: [], // 简要商品列表
|
erpSpuSimpleAll: [], // 简要商品列表
|
||||||
|
|
||||||
linkCodeVisible: false, // 关联采购申请单对话框开关
|
|
||||||
linkCgPlanDialogVisible: false, // 关联采购申请单对话框开关
|
|
||||||
})
|
})
|
||||||
|
|
||||||
// 合计金额表单数据
|
// 合计金额表单数据
|
||||||
@@ -337,7 +331,7 @@ const getInitData = async () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 点击关联采购申请编号
|
// 点击关联采购申请编号
|
||||||
const handleClickLinkCode = () => linkCgPlanDialogRef.value.openLinkCodeDialog(2)
|
const handleClickLinkCode = () => linkCodeDialogRef.value.openLinkCodeDialog(2)
|
||||||
|
|
||||||
// 获取选择的采购申请
|
// 获取选择的采购申请
|
||||||
const getSelectedLinkCode = (selectionRows: any) => {
|
const getSelectedLinkCode = (selectionRows: any) => {
|
||||||
@@ -346,7 +340,6 @@ const getSelectedLinkCode = (selectionRows: any) => {
|
|||||||
baseDataForm.linkCode = selectionRows.code
|
baseDataForm.linkCode = selectionRows.code
|
||||||
state.editableTableData = selectionRows.items
|
state.editableTableData = selectionRows.items
|
||||||
state.erpSpuItemsMemo = selectionRows.items
|
state.erpSpuItemsMemo = selectionRows.items
|
||||||
state.linkCgPlanDialogVisible = false
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 删除选中的行
|
// 删除选中的行
|
||||||
|
|||||||
@@ -51,10 +51,8 @@
|
|||||||
<!-- <pagination @size-change="sizeChangeHandle" @current-change="currentChangeHandle" v-bind="state.pagination" /> -->
|
<!-- <pagination @size-change="sizeChangeHandle" @current-change="currentChangeHandle" v-bind="state.pagination" /> -->
|
||||||
|
|
||||||
<template #footer>
|
<template #footer>
|
||||||
<div class="dialog-footer">
|
<el-button @click="visible = false">取消</el-button>
|
||||||
<el-button @click="visible = false">取消</el-button>
|
<el-button type="primary" @click="onSubmit" :disabled="loading">确认</el-button>
|
||||||
<!-- <el-button type="primary" @click="onSubmit" :disabled="loading">确认</el-button> -->
|
|
||||||
</div>
|
|
||||||
</template>
|
</template>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</template>
|
</template>
|
||||||
@@ -85,10 +83,11 @@ const form = reactive({
|
|||||||
salesCount: "",
|
salesCount: "",
|
||||||
erpSpuName: "",
|
erpSpuName: "",
|
||||||
})
|
})
|
||||||
|
const dialogVisible = ref(false)
|
||||||
|
|
||||||
// 定义校验规则
|
// 定义校验规则
|
||||||
const dataRules = ref({
|
const dataRules = ref({
|
||||||
// sliderPicUrls: [{ required: true, message: "请上传轮播图", trigger: "blur" }],
|
sliderPicUrls: [{ required: true, message: "请上传轮播图", trigger: "blur" }],
|
||||||
})
|
})
|
||||||
|
|
||||||
// 打开弹窗
|
// 打开弹窗
|
||||||
@@ -143,29 +142,29 @@ const state: BasicTableProps = reactive<BasicTableProps>({
|
|||||||
|
|
||||||
const { getDataList, currentChangeHandle, sizeChangeHandle, sortChangeHandle, downBlobFile, tableStyle } = useTable(state)
|
const { getDataList, currentChangeHandle, sizeChangeHandle, sortChangeHandle, downBlobFile, tableStyle } = useTable(state)
|
||||||
|
|
||||||
// const resetQuery = () => {
|
const resetQuery = () => {
|
||||||
// getDataList()
|
getDataList()
|
||||||
// }
|
}
|
||||||
|
|
||||||
// 点击选择库存商品
|
// 点击选择库存商品
|
||||||
// const handleClickSelectSpu = () => {
|
const handleClickSelectSpu = () => {
|
||||||
// loading.value = true
|
loading.value = true
|
||||||
// resetQuery()
|
resetQuery()
|
||||||
// spuSelectDialogVisible.value = true
|
dialogVisible.value = true
|
||||||
// try {
|
try {
|
||||||
// getDataList()
|
getDataList()
|
||||||
// } catch (error) {
|
} catch (error) {
|
||||||
// state.dataList = []
|
state.dataList = []
|
||||||
// loading.value = false
|
loading.value = false
|
||||||
// }
|
}
|
||||||
// loading.value = false
|
loading.value = false
|
||||||
// }
|
}
|
||||||
|
|
||||||
// 线上商品列表表格行点击
|
// 线上商品列表表格行点击
|
||||||
const handleRowClick = (row: any) => {
|
const handleRowClick = (row: any) => {
|
||||||
// spuSelectDialogVisible.value = false
|
dialogVisible.value = false
|
||||||
// form.erpSpuId = row.id
|
form.erpSpuId = row.id
|
||||||
// form.erpSpuName = row.productName
|
form.erpSpuName = row.productName
|
||||||
}
|
}
|
||||||
|
|
||||||
// 暴露变量
|
// 暴露变量
|
||||||
|
|||||||
@@ -243,16 +243,11 @@ const state = reactive<{
|
|||||||
erpSpuItemsMemo: any[]
|
erpSpuItemsMemo: any[]
|
||||||
selectedRowsErpSpuIds: string[]
|
selectedRowsErpSpuIds: string[]
|
||||||
erpSpuSimpleAll: any
|
erpSpuSimpleAll: any
|
||||||
linkCodeVisible: boolean
|
|
||||||
linkCgPlanDialogVisible: boolean
|
|
||||||
}>({
|
}>({
|
||||||
editableTableData: [], // 可编辑表格数据
|
editableTableData: [], // 可编辑表格数据
|
||||||
erpSpuItemsMemo: [], // 请求到的可编辑表格商品数据的缓存
|
erpSpuItemsMemo: [], // 请求到的可编辑表格商品数据的缓存
|
||||||
selectedRowsErpSpuIds: [], // 可编辑表格已选行的ErpSpuId
|
selectedRowsErpSpuIds: [], // 可编辑表格已选行的ErpSpuId
|
||||||
erpSpuSimpleAll: [], // 简要商品列表
|
erpSpuSimpleAll: [], // 简要商品列表
|
||||||
|
|
||||||
linkCodeVisible: false, // 关联采购申请单对话框开关
|
|
||||||
linkCgPlanDialogVisible: false, // 关联采购申请单对话框开关
|
|
||||||
})
|
})
|
||||||
|
|
||||||
// 基本信息表单校验规则
|
// 基本信息表单校验规则
|
||||||
|
|||||||
Reference in new issue
Block a user