maliang 1 săptămână în urmă
părinte
comite
ccfbfe6e03

+ 1 - 1
jshERP-web/src/views/bill/dialog/BillDetail.vue

@@ -1697,7 +1697,7 @@ export default {
         { title: '序列号', dataIndex: 'snList', width: 300 },
         { title: '有效期', dataIndex: 'expirationDate', width: 90 },
         { title: '多属性', dataIndex: 'sku', width: 90 },
-        { title: '数量', dataIndex: 'operNumber', width: 90 },
+        { title: '入库数量', dataIndex: 'operNumber', width: 90 },
         { title: '已入库', dataIndex: 'finishNumber', width: 90 },
         { title: '单价', dataIndex: 'unitPrice', width: 90 },
         { title: '金额', dataIndex: 'allPrice', width: 90 },

+ 24 - 24
jshERP-web/src/views/bill/mixins/BillModalMixin.js

@@ -454,25 +454,25 @@ export const BillModalMixin = {
       setTimeout(function () {
         that.$refs.materialDataTable.resetScrollTop((target.rows.length + 1) * that.$refs.materialDataTable.rowHeight)
       }, 1000)
-      if (this.currentSelectDepotId) {
-        //如果单据选择过仓库,则直接从当前选择的仓库加载
-        target.setValues([{ rowKey: row.id, values: { depotId: this.currentSelectDepotId } }])
-      } else {
-        getAction('/depot/findDepotByCurrentUser').then((res) => {
-          if (res.code === 200) {
-            let arr = res.data
-            if (arr.length === 1) {
-              target.setValues([{ rowKey: row.id, values: { depotId: arr[0].id + '' } }])
-            } else {
-              for (let i = 0; i < arr.length; i++) {
-                if (arr[i].isDefault) {
-                  target.setValues([{ rowKey: row.id, values: { depotId: arr[i].id + '' } }])
-                }
-              }
-            }
-          }
-        })
-      }
+      // if (this.currentSelectDepotId) {
+      //   //如果单据选择过仓库,则直接从当前选择的仓库加载
+      //   target.setValues([{ rowKey: row.id, values: { depotId: this.currentSelectDepotId } }])
+      // } else {
+      //   getAction('/depot/findDepotByCurrentUser').then((res) => {
+      //     if (res.code === 200) {
+      //       let arr = res.data
+      //       if (arr.length === 1) {
+      //         target.setValues([{ rowKey: row.id, values: { depotId: arr[0].id + '' } }])
+      //       } else {
+      //         for (let i = 0; i < arr.length; i++) {
+      //           if (arr[i].isDefault) {
+      //             target.setValues([{ rowKey: row.id, values: { depotId: arr[i].id + '' } }])
+      //           }
+      //         }
+      //       }
+      //     }
+      //   })
+      // }
     },
     //根据【仓库名】带出对应的【仓位货架】
     async setProPosition(barCode, depotId, event){
@@ -517,11 +517,7 @@ export const BillModalMixin = {
           console.log('row========', row)
           // // 选择商品自动带出barCode、商品ID
           if(row.depotId&&row.barCode){
-            // console.log('row.depotId========', row.depotId)
             // // 根据仓库id自动带出仓位货架(若有)参数:商品id、仓库id
-            // getAction('/material/getPositionByDidAndMid',{mid:row.mid,did:row.depotId}).then((res) => {
-            //   console.log('res========', res)
-            // })
             this.setProPosition(row.barCode, row.depotId, event)
           }
           break
@@ -617,6 +613,7 @@ export const BillModalMixin = {
           getMaterialByBarCode(param).then((res) => {
             if (res && res.code === 200) {
               let mList = res.data
+              console.log('mList======',mList)
               target.getValues((error, values) => {
                 const clickRowIndex = values.findIndex((item) => item.id === row.id) //获取当前行的索引
                 // values.pop() //移除最后一行数据
@@ -632,13 +629,15 @@ export const BillModalMixin = {
                   mObj.depotId = mInfo.depotId
                   mObj.stock = mInfo.stock
                   mObj.inventory = mInfo.inventory
+                  mObj.allPrice = mInfo.allPrice||0
+                  mObj.taxLastMoney = mInfo.taxLastMoney||0
                   mArr.push(mObj)
                 }
                 let allPriceTotal = 0
                 let taxLastMoneyTotal = 0
                 for (let j = 0; j < mArr.length; j++) {
                   allPriceTotal += mArr[j].allPrice - 0
-                  taxLastMoneyTotal += mArr[j].taxLastMoney - 0
+                  taxLastMoneyTotal += mArr[j].taxLastMoney- 0
                   //组合和拆分单据给商品类型进行重新赋值
                   if (j === 0) {
                     mArr[0].mType = '组合件'
@@ -646,6 +645,7 @@ export const BillModalMixin = {
                     mArr[j].mType = '普通子件'
                   }
                 }
+                console.log('mArr--------',mArr)
                 this.materialTable.dataSource = mArr
                 if (this.prefixNo === 'LSCK' || this.prefixNo === 'LSTH') {
                   target.statisticsColumns.allPrice = allPriceTotal

+ 1 - 1
jshERP-web/src/views/bill/modules/OtherInModal.vue

@@ -303,7 +303,7 @@ export default {
           },
           { title: '保质期', key: 'expiryNum', width: '120px', type: FormTypes.inputNumber },
           // { title: '商品条码', key: 'barCode', width: '9%', type: FormTypes.normal },
-          { title: '仓库名', key: 'depotId', width: '120px', type: FormTypes.select },
+          { title: '仓库名', key: 'depotId', width: '120px', type: FormTypes.select,validateRules: [{ required: true, message: '${title}不能为空' }], },
           { title: '仓库货架', key: 'position', width: '120px', type: FormTypes.input },
           { title: '包装规格', key: 'unitName', width: '120px', type: FormTypes.normal },
 

+ 3 - 3
jshERP-web/src/views/bill/modules/OtherOutModal.vue

@@ -298,8 +298,8 @@ export default {
           // { title: '生产日期', key: 'productionDate', width: '200px', type: FormTypes.normal, disabled: true },
           // { title: '保质期', key: 'expiryNum', width: '120px', type: FormTypes.normal },
           // { title: '商品条码', key: 'barCode', width: '9%', type: FormTypes.normal },
-          { title: '仓库名', key: 'depotId', width: '120px', type: FormTypes.select },
-          { title: '仓库货架', key: 'position', width: '120px', type: FormTypes.normal },
+          { title: '仓库名', key: 'depotId', width: '120px', type: FormTypes.select,validateRules: [{ required: true, message: '${title}不能为空' }], },
+          { title: '仓库货架', key: 'position', width: '120px', type: FormTypes.input },
           { title: '包装规格', key: 'unitName', width: '120px', type: FormTypes.normal },
 
           { title: '型号', key: 'model', width: '120px', type: FormTypes.normal },
@@ -342,7 +342,7 @@ export default {
             type: FormTypes.inputNumber,
             validateRules: [{ required: true, message: '实际入库数量不能为空' }],
           },
-          { title: '出库差异', key: 'warehousingVariance', width: '120px', type: FormTypes.input },
+          { title: '出库差异', key: 'warehousingVariance', width: '120px', type: FormTypes.inputNumber },
           { title: '出库差异原因', key: 'reasonOfDifference', width: '120px', type: FormTypes.input },
           {
             title: '出库人',

+ 2 - 2
jshERP-web/src/views/bill/modules/PurchaseInModal.vue

@@ -483,7 +483,7 @@ export default {
           },
           { title: '保质期', key: 'expiryNum', width: '120px', type: FormTypes.inputNumber },
           // { title: '商品条码', key: 'barCode', width: '9%', type: FormTypes.normal },
-          { title: '仓库名', key: 'depotId', width: '120px', type: FormTypes.select },
+          { title: '仓库名', key: 'depotId', width: '120px', type: FormTypes.select,validateRules: [{ required: true, message: '${title}不能为空' }], },
           { title: '仓库货架', key: 'position', width: '120px', type: FormTypes.input },
           { title: '包装规格', key: 'unitName', width: '120px', type: FormTypes.normal },
 
@@ -544,7 +544,7 @@ export default {
           //   type: FormTypes.inputNumber,
           //   validateRules: [{ required: true, message: '实际入库数量不能为空' }],
           // },
-          { title: '入库差异', key: 'warehousingVariance', width: '120px', type: FormTypes.input },
+          { title: '入库差异', key: 'warehousingVariance', width: '120px', type: FormTypes.inputNumber },
           { title: '入库差异原因', key: 'reasonOfDifference', width: '120px', type: FormTypes.input },
           {
             title: '入库人',

+ 1 - 1
jshERP-web/src/views/bill/modules/PurchaseOrderModal.vue

@@ -440,7 +440,7 @@ export default {
           },
           { title: '保质期', key: 'expiryNum', width: '120px', type: FormTypes.inputNumber },
           // { title: '商品条码', key: 'barCode', width: '120px', type: FormTypes.normal },
-          { title: '仓库名', key: 'depotId', width: '120px', type: FormTypes.select },
+          { title: '仓库名', key: 'depotId', width: '120px', type: FormTypes.select,validateRules: [{ required: true, message: '${title}不能为空' }], },
           { title: '仓库货架', key: 'position', width: '120px', type: FormTypes.input },
           { title: '包装规格', key: 'unitName', width: '120px', type: FormTypes.normal },
 

+ 1 - 1
jshERP-web/src/views/bill/modules/SaleOrderModal.vue

@@ -401,7 +401,7 @@ export default {
           // { title: '生产日期', key: 'productionDate', width: '6%', type: FormTypes.normal },
           // { title: '保质期', key: 'expiryNum', width: '6%', type: FormTypes.normal },
           // { title: '商品条码', key: 'barCode', width: '6%', type: FormTypes.normal },
-          { title: '仓库名', key: 'depotId', width: '120px', type: FormTypes.select },
+          { title: '仓库名', key: 'depotId', width: '120px', type: FormTypes.select,validateRules: [{ required: true, message: '${title}不能为空' }], },
           { title: '仓库货架', key: 'position', width: '120px', type: FormTypes.input },
           { title: '包装规格', key: 'unitName', width: '120px', type: FormTypes.normal },
 

+ 2 - 2
jshERP-web/src/views/bill/modules/SaleOutModal.vue

@@ -502,7 +502,7 @@ export default {
           // { title: '生产日期', key: 'productionDate', width: '9%', type: FormTypes.normal, disabled: true },
           // { title: '保质期', key: 'expiryNum', width: '6%', type: FormTypes.normal },
           // { title: '商品条码', key: 'barCode', width: '9%', type: FormTypes.normal },
-          { title: '仓库名', key: 'depotId', width: '120px', type: FormTypes.select },
+          { title: '仓库名', key: 'depotId', width: '120px', type: FormTypes.select,validateRules: [{ required: true, message: '${title}不能为空' }], },
           { title: '仓库货架', key: 'position', width: '120px', type: FormTypes.input },
           { title: '包装规格', key: 'unitName', width: '120px', type: FormTypes.normal },
 
@@ -556,7 +556,7 @@ export default {
           //   type: FormTypes.inputNumber,
           //   validateRules: [{ required: true, message: '实际入库数量不能为空' }],
           // },
-          { title: '出库差异', key: 'warehousingVariance', width: '120px', type: FormTypes.input },
+          { title: '出库差异', key: 'warehousingVariance', width: '120px', type: FormTypes.inputNumber },
           { title: '出库差异原因', key: 'reasonOfDifference', width: '120px', type: FormTypes.input },
           {
             title: '出库人',