lilei 2 years ago
parent
commit
2a984ca2ba

+ 9 - 6
src/views/purchasingManagement/bulkWarehousingOrder/auditNoPassModal.vue

@@ -32,12 +32,12 @@
 
 <script>
 export default {
-  name: 'auditNoPassModal',
+  name: 'AuditNoPassModal',
   props: {
     openModal: { //  弹框显示状态
       type: Boolean,
       default: false
-    },
+    }
   },
   data () {
     return {
@@ -50,7 +50,7 @@ export default {
       const arr = [
         { title: '序号', dataIndex: 'no', width: '5%', align: 'center' },
         { title: '产品编码', dataIndex: 'productCode', width: '25%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '产品名称', dataIndex: 'productName', width: '40%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '产品名称', dataIndex: 'productName', width: '40%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true }
       ]
       if (this.$hasPermissions('B_isShowCost')) { //  成本价权限
         arr.splice(5, 0, { title: 'OCS成本价', dataIndex: 'verifyCost', width: '15%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } })
@@ -64,8 +64,11 @@ export default {
     handleBack () {
       this.isShow = false
     },
-    setData(data){
+    setData (data) {
       this.list = data
+      this.list.map((item, i) => {
+        item.no = i + 1
+      })
     }
   },
   watch: {
@@ -78,7 +81,7 @@ export default {
       if (!newValue) {
         this.$emit('close')
       }
-    },
+    }
   }
 }
 </script>
@@ -93,4 +96,4 @@ export default {
       margin: 5px 0 10px;
     }
   }
-</style>
+</style>

+ 5 - 3
src/views/purchasingManagement/bulkWarehousingOrder/edit.vue

@@ -84,9 +84,9 @@
               class="button-error"
               id="bulkWarehousingOrderList-del-btn">删除</a-button>
           </template>
-          
+
           <template slot="productName" slot-scope="text, record">
-            {{record.productName}}
+            {{ record.productName }}
             <a-tag color="red" v-if="record.giftFlag==1">赠品</a-tag>
           </template>
         </s-table>
@@ -156,7 +156,7 @@ export default {
       const arr = [
         { title: '序号', dataIndex: 'no', width: '5%', align: 'center' },
         { title: '产品编码', dataIndex: 'productCode', width: '20%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '产品名称', scopedSlots: { customRender: 'productName' },width: '25%', align: 'center' },
+        { title: '产品名称', scopedSlots: { customRender: 'productName' }, width: '25%', align: 'center' },
         { title: '单位', dataIndex: 'unit', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '入库数量', dataIndex: 'productQty', width: '10%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         // { title: '入库单价', dataIndex: 'productCost', width: '10%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
@@ -209,10 +209,12 @@ export default {
     },
     // 导入产品
     hanldeOk (obj) {
+      this.spinning = true
       sparePartsDetailBatchInsert(obj).then(res => {
         if (res.status == 200) {
           this.$refs.table.refresh(true)
         }
+        this.spinning = false
       })
     },
     //  返回列表

+ 3 - 1
src/views/supplierManagement/costSetting/addProductModal.vue

@@ -13,7 +13,7 @@
         <div style="display:flex;align-items: center;padding:10px 0;">
           <div style="font-size:14px;"><span style="color:red;">*</span>供应商名称:</div>
           <div style="flex-grow: 1;">
-            <supplier style="width:50%" v-model="supplierSn" @change="getChoosed" placeholder="请输入供应商名称搜索"></supplier>
+            <supplier style="width:50%" ref="supplier" v-model="supplierSn" @change="getChoosed" placeholder="请输入供应商名称搜索"></supplier>
           </div>
         </div>
         <div style="padding:10px 0;border-bottom: 1px solid #eee;">
@@ -210,6 +210,7 @@ export default {
       _this.$refs.ruleForm.validate(valid => {
         if (valid) {
           if (this.supplierSn) {
+            _this.$refs.table.clearTable()
             _this.$refs.table.refresh(true)
           } else {
             this.$message.warning('请先选择供应商!')
@@ -227,6 +228,7 @@ export default {
       this.queryParam.productTypeSn2 = ''
       this.queryParam.productTypeSn3 = ''
       this.queryParam.productType = []
+      this.supplierSn = undefined
     },
     //  重置
     resetSearchForm () {