入库去除经办人选项
This commit is contained in:
1 parent
04d4fc4406
commit
f4e0ea65ca
4 files changed
+18
-38
No files matched your search
@@ -11,7 +11,7 @@
|
||||
<span class="font-bold">单据日期:</span>
|
||||
<span>{{ baseDataForm.inventoryDate }}</span>
|
||||
</div>
|
||||
<div style="width: 33.33%; height: 28px; line-height: 28px">
|
||||
<!-- <div style="width: 33.33%; height: 28px; line-height: 28px">
|
||||
<span class="font-bold">经办人:</span>
|
||||
<SelectHandlerUser
|
||||
v-model.trim="baseDataForm.handlerUserId"
|
||||
@@ -19,7 +19,7 @@
|
||||
style="width: 200px"
|
||||
:isDisplayName="true"
|
||||
/>
|
||||
</div>
|
||||
</div> -->
|
||||
<div style="width: 33.33%; height: 28px; line-height: 28px">
|
||||
<span class="font-bold">关联补货申请:</span>
|
||||
<span>{{ baseDataForm.linkCode }}</span>
|
||||
@@ -53,14 +53,14 @@
|
||||
:disabled="disabled"
|
||||
/>
|
||||
</el-form-item> -->
|
||||
<el-form-item label="经办人" prop="handlerUserId">
|
||||
<!-- <el-form-item label="经办人" prop="handlerUserId">
|
||||
<SelectHandlerUser
|
||||
v-model.trim="baseDataForm.handlerUserId"
|
||||
placeholder="请选择经办人"
|
||||
style="width: 200px"
|
||||
:disabled="disabled"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-form-item> -->
|
||||
<el-form-item label="货商" prop="supplierId">
|
||||
<SelectSupermarketSupplier v-model="baseDataForm.supplierId" style="width: 200px" :disabled="disabled" />
|
||||
</el-form-item>
|
||||
@@ -81,7 +81,6 @@
|
||||
border
|
||||
:loading="loading"
|
||||
show-overflow
|
||||
show-footer
|
||||
max-height="410"
|
||||
:edit-config="{
|
||||
trigger: 'click',
|
||||
@@ -98,9 +97,12 @@
|
||||
:column-config="{ resizable: true }"
|
||||
:row-config="{ isHover: true }"
|
||||
:resizable-config="{ dragMode: 'fixed' }"
|
||||
:checkbox-config="{ highlight: true, range: true }"
|
||||
:data="vxeTableData"
|
||||
:edit-rules="validRules"
|
||||
show-footer
|
||||
:footer-data="footerData"
|
||||
:merge-footer-items="[{ row: 0, col: 2, rowspan: 1, colspan: 6 }]"
|
||||
@checkbox-all=""
|
||||
@checkbox-change=""
|
||||
size="mini"
|
||||
@@ -189,6 +191,9 @@
|
||||
@change="updateFootEvent"
|
||||
/>
|
||||
</template>
|
||||
<template #footer="{ row }">
|
||||
<span style="color: #2e5cf6; font-weight: bold">{{ footerData[0].totalAmount }} 元</span>
|
||||
</template>
|
||||
</vxe-column>
|
||||
<vxe-column field="remark" title="备注" :edit-render="{ autoFocus: 'input', placeholder: '请输入' }">
|
||||
<template #edit="{ row }">
|
||||
@@ -207,7 +212,7 @@
|
||||
<el-tooltip v-if="!disabled" effect="dark" content="保存并返回列表页面" placement="top">
|
||||
<el-button type="primary" plain @click="onSave">保存</el-button>
|
||||
</el-tooltip>
|
||||
<!-- <el-tooltip v-if="disabled" effect="dark" content="打印清单" placement="top">
|
||||
<!-- <el-tooltip effect="dark" content="打印清单" placement="top">
|
||||
<el-button type="success" plain @click="printEvent">打印</el-button>
|
||||
</el-tooltip> -->
|
||||
</el-row>
|
||||
@@ -263,7 +268,6 @@ const baseDataForm = reactive<any>({
|
||||
id: "",
|
||||
inventoryCode: "",
|
||||
inventoryDate: formatDate(new Date(), "YYYY-mm-dd"),
|
||||
handlerUserId: "",
|
||||
supplierId: "",
|
||||
remark: "",
|
||||
inventoryType: "3",
|
||||
@@ -374,17 +378,8 @@ const getSelectedRows = (selectionRows: any) => {
|
||||
isNew: true,
|
||||
}
|
||||
})
|
||||
// 仅添加新勾选的项
|
||||
vxeTableData.value.push(...addedItems)
|
||||
|
||||
// 筛选取消勾选的项
|
||||
// const removedItems = vxeTableData.value.filter(
|
||||
// (item: any) => !selectionRows.some((selectedItem: any) => selectedItem.erpSpuId === item.erpSpuId),
|
||||
// )
|
||||
// 仅移除取消勾选的项
|
||||
// vxeTableData.value = vxeTableData.value.filter(
|
||||
// (item: any) => !removedItems.some((removeItem: any) => removeItem.erpSpuId === item.erpSpuId),
|
||||
// )
|
||||
updateFootCount(vxeTableData.value)
|
||||
|
||||
console.log("vxeTableData.value", vxeTableData.value)
|
||||
|
||||
@@ -15,9 +15,9 @@
|
||||
value-format="YYYY-MM-DD"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="经办人" prop="handlerUserId">
|
||||
<!-- <el-form-item label="经办人" prop="handlerUserId">
|
||||
<SelectHandlerUser v-model.trim="state.queryForm.handlerUserId" placeholder="请选择经办人" style="width: 200px" />
|
||||
</el-form-item>
|
||||
</el-form-item> -->
|
||||
<el-form-item>
|
||||
<el-button icon="search" type="primary" @click="getDataList">查询</el-button>
|
||||
<el-button icon="Refresh" @click="resetQuery">重置</el-button>
|
||||
@@ -65,7 +65,7 @@
|
||||
<el-table-column prop="inventoryCode" 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="handlerUserName" label="经办人" show-overflow-tooltip />
|
||||
<!-- <el-table-column prop="handlerUserName" label="经办人" show-overflow-tooltip /> -->
|
||||
<el-table-column prop="supplierName" label="货商" show-overflow-tooltip />
|
||||
<el-table-column prop="remark" label="备注" show-overflow-tooltip />
|
||||
<el-table-column prop="totalAmount" label="入库总金额" show-overflow-tooltip>
|
||||
|
||||
@@ -283,17 +283,8 @@ const getSelectedRows = (selectionRows: any) => {
|
||||
// if (index !== -1) return vxeTableDataMemo.value[index]
|
||||
return { ...addItem, unitId: addItem.erpUnitVos[0].id, quantity: 1, isNew: true }
|
||||
})
|
||||
// 仅添加新勾选的项
|
||||
vxeTableData.value.push(...addedItems)
|
||||
|
||||
// 筛选取消勾选的项
|
||||
// const removedItems = vxeTableData.value.filter(
|
||||
// (item: any) => !selectionRows.some((selectedItem: any) => selectedItem.erpSpuId === item.erpSpuId),
|
||||
// )
|
||||
// 仅移除取消勾选的项
|
||||
// vxeTableData.value = vxeTableData.value.filter(
|
||||
// (item: any) => !removedItems.some((removeItem: any) => removeItem.erpSpuId === item.erpSpuId),
|
||||
// )
|
||||
console.log("vxeTableData.value", vxeTableData.value)
|
||||
}
|
||||
|
||||
|
||||
@@ -14,19 +14,13 @@ function chunk<T>(array: T[], size: number): T[][] {
|
||||
}
|
||||
|
||||
// 表格分页 + 表单信息 打印
|
||||
export const tablePrint = (
|
||||
editableTableRef: any,
|
||||
baseDataInfoRef: any,
|
||||
editableTableData: any,
|
||||
tableChunkSize: number = 20,
|
||||
printTitle: string = "",
|
||||
) => {
|
||||
const $table = editableTableRef
|
||||
const formPrintHtml = baseDataInfoRef ? baseDataInfoRef.innerHTML : ""
|
||||
export const tablePrint = (vxeTableRef: any, baseInfoRef: any, vxeTableData: any, tableChunkSize: number = 20, printTitle: string = "") => {
|
||||
const $table = vxeTableRef
|
||||
const formPrintHtml = baseInfoRef ? baseInfoRef.innerHTML : ""
|
||||
if ($table && formPrintHtml) {
|
||||
// 分割每页20条
|
||||
Promise.all(
|
||||
chunk(editableTableData, tableChunkSize).map((pageData: any, index: number) => {
|
||||
chunk(vxeTableData, tableChunkSize).map((pageData: any, index: number) => {
|
||||
return $table
|
||||
.getPrintHtml({
|
||||
data: pageData,
|
||||
|
||||
Reference in new issue
Block a user