From a1b487e3417efb1481c3ef5598dcc4894529f1d5 Mon Sep 17 00:00:00 2001 From: haoxuan <haoxuan> Date: 星期四, 18 四月 2024 16:42:04 +0800 Subject: [PATCH] 出入库明细打印的接口联调+根据公司的不同设置不同的打印宽度 --- src/components/makepager/CommonFormTableView.vue | 26 ++++++++++++++++++-------- 1 files changed, 18 insertions(+), 8 deletions(-) diff --git a/src/components/makepager/CommonFormTableView.vue b/src/components/makepager/CommonFormTableView.vue index 903d1aa..961f4a1 100644 --- a/src/components/makepager/CommonFormTableView.vue +++ b/src/components/makepager/CommonFormTableView.vue @@ -142,12 +142,12 @@ </div> </el-form-item> <el-form-item - v-else-if="item.inputFloat" + v-else-if="item.inputFloat||item.inputFloatValue" label=" " :prop="'tableData.' + scope.$index + '.' + item.prop" :rules="[{ required: item.isRequird ? true : false, message: '杈撳叆涓嶈兘涓虹┖' }]" > - <span v-if="scope.row.isEdit">{{ scope.row[item.prop] }}</span> + <span v-if="scope.row.isEdit||(item.inputFloatValue&&!scope.row[item.isInputFloat])">{{ scope.row[item.prop] }}</span> <div v-else @click.stop="commoInput"> <el-input-number v-model="scope.row[item.prop]" @@ -194,7 +194,7 @@ style="width: 80%" @change=" (val) => { - selLocationClick(val, item.prop) + selLocationClick(val, item.prop,scope.row) } " > @@ -430,7 +430,7 @@ <slot name="tableButton" /> </el-table> </el-form> - <div v-if="!detailEnter && !isinventory && !isReorder" style="margin: 10px"> + <div v-if="!detailEnter && !isinventory && !isReorder&&isOperateAdd" style="margin: 10px"> <el-button size="small" type="primary" @click="add">鏂板</el-button> <el-button size="small" type="primary" @click="empty">娓呯┖</el-button> </div> @@ -450,7 +450,7 @@ import { getProductList } from "@/api/product/product" import { getLocationList } from "@/api/warehouseManage/warehouse" import { getCompanyList } from "@/api/common/other" -import { getRuleList } from "@/api/operate/inventoryAdjustment" +import { getRuleList} from "@/api/operate/inventoryAdjustment" import { getProductCategoryList } from "@/api/product/productCategory" import SimpleSearchInput from "@/components/makepager/SimpleSearchInput" import { getAmountAndPrediction } from "@/api/product/reorderRules" @@ -507,7 +507,12 @@ isOperate: { type: Boolean, default: true - } + }, + // 鏄惁鏈夋柊澧炲拰娓呯┖鎿嶄綔 + isOperateAdd: { + type: Boolean, + default: true + }, }, data() { return { @@ -679,6 +684,7 @@ this.locacionName = "" await getLocationList({ // keyword: "", + type:3, jointName: this.initialPosition ? this.initialPosition : null, productId: this.queryProductId ? this.queryProductId : null, productCategoryId: this.categoryId ? this.categoryId : null, @@ -772,6 +778,7 @@ }, // 閫夋嫨浜у搧 selProductClick(item, row) { + console.log("閫夋嫨浜у搧",row,item) if (this.isReorder) { this.productId = item.id this.productName = item.name @@ -794,13 +801,12 @@ ite.productName = item.name ite.categoryId = item.categoryId ite.productCategory = item.categoryName - ite.amount = item.amount + // ite.amount = item.amount ite.unit = item.unit } }) this.$emit("selProductClick", "product", this.tableList.tableData[selIndex]) } - if (this.isinventory) { getRuleList({ locationId: 0, @@ -813,6 +819,7 @@ } }) } + // this.$emit("selProductClick", item) }, // 閫夋嫨浜у搧绫诲瀷 @@ -844,6 +851,7 @@ }, // 閫夋嫨浣嶇疆 selLocationClick(item, prop, row) { + console.log("浣嶇疆閫夋嫨",item,row) if (prop === "areaName") { getLocationList({ jointName: item.label, @@ -855,6 +863,8 @@ this.selSonLocationOptions = list } }) + }else if(prop==='locationName'){ + console.log("locationName") } if (this.isReorder) { this.locacionId = item.value -- Gitblit v1.8.0