lilei 11 ماه پیش
والد
کامیت
5935cbf15e
1فایلهای تغییر یافته به همراه22 افزوده شده و 17 حذف شده
  1. 22 17
      src/views/financialManagement/warehousingConfirmation/list.vue

+ 22 - 17
src/views/financialManagement/warehousingConfirmation/list.vue

@@ -75,7 +75,7 @@
           bordered>
           <!-- 入库单号 -->
           <template slot="stockPutNo" slot-scope="text, record">
-            <span v-if="$hasPermissions('B_warehousingConfirmationDetail')" class="link-bule" @click="handleDetail(record)">{{ record.stockPutNo }}</span>
+            <span :id="'warehousingConfirmationList-detail-'+record.stockPutNo" v-if="$hasPermissions('B_warehousingConfirmationDetail')" class="link-bule" @click="handleDetail(record)">{{ record.stockPutNo }}</span>
             <span v-else>{{ record.stockPutNo }}</span>
           </template>
           <!-- 操作 -->
@@ -86,7 +86,7 @@
               v-if="record.auditState=='WAIT' && $hasPermissions('B_warehousingConfirmationAlone')"
               class="button-info"
               @click="handleAudit(record)"
-              id="warehousingConfirmationList-audit-btn">入库确认</a-button>
+              :id="'warehousingConfirmationList-audit-btn-'+record.stockPutNo">入库确认</a-button>
             <span v-else>--</span>
           </template>
         </s-table>
@@ -111,8 +111,8 @@
           </div>
         </div>
         <div class="btn-box">
-          <a-button type="primary" :loading="spinning" class="button-error" @click="handleConfirmationFail">不通过</a-button>
-          <a-button type="primary" :loading="spinning" class="button-info" @click="handleConfirmationOk">通过</a-button>
+          <a-button id="confir-ruku-cancel" type="primary" :loading="spinning" class="button-error" @click="handleConfirmationFail">不通过</a-button>
+          <a-button id="confir-ruku-ok" type="primary" :loading="spinning" class="button-info" @click="handleConfirmationOk">通过</a-button>
         </div>
       </a-modal>
     </a-card>
@@ -132,14 +132,14 @@ export default {
   data () {
     return {
       spinning: false,
+      loading: false,
       queryParam: { //  查询条件
         stockPutNo: '', //  入库单号
         auditState: undefined, //  状态
         warehouseSn: undefined // 仓库
       },
-      tableHeight: 0,
+      tableHeight: 0, // 表格高度
       disabled: false, //  查询、重置按钮是否可操作
-      loading: false,
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
@@ -154,13 +154,13 @@ export default {
           return data
         })
       },
-      openModal: false,
-      itemSn: '',
-      nowData: null,
-      confirmationModal: false,
-      confirmationInfo: null,
-      isBatch: false,
-      rowSelectionInfo: null
+      openModal: false, // 详情弹框
+      itemSn: '', // 详情弹框单据sn
+      nowData: null, // 详情弹框当前操作数据
+      confirmationModal: false, // 入库确认弹框
+      confirmationInfo: null, // 确认入库得单据数据
+      isBatch: false, // 是否批量确认入库
+      rowSelectionInfo: null // 批量操作已选数据
     }
   },
   computed: {
@@ -178,6 +178,7 @@ export default {
         { title: '备注', dataIndex: 'remark', width: '15%', align: 'left', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: '8%', align: 'center' }
       ]
+      // 是否显示仓库
       if (this.isShowWarehouse) {
         arr.splice(3, 0, { title: '仓库', dataIndex: 'warehouseName', width: '12%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true })
       }
@@ -208,12 +209,13 @@ export default {
         this.openModal = true
       }
     },
+    // 关闭详情弹框
     closeModal () {
       this.itemSn = ''
       this.nowData = null
       this.openModal = false
     },
-    // 通过
+    // 入库确认通过
     handleConfirmationOk () {
       if (this.isBatch) { //  批量
         this.auditOrder(this.rowSelectionInfo && this.rowSelectionInfo.selectedRowKeys, true)
@@ -221,7 +223,7 @@ export default {
         this.auditOrder([this.confirmationInfo.stockPutSn], true)
       }
     },
-    // 不通过
+    // 入库确认不通过
     handleConfirmationFail () {
       if (this.isBatch) { //  批量
         this.auditOrder(this.rowSelectionInfo && this.rowSelectionInfo.selectedRowKeys, false)
@@ -229,12 +231,13 @@ export default {
         this.auditOrder([this.confirmationInfo.stockPutSn], false)
       }
     },
-    // 单个审核
+    // 打开入库确认
     handleAudit (row) {
       this.confirmationInfo = row
       this.isBatch = false
       this.confirmationModal = true
     },
+    // 入库确认接口调用
     auditOrder (snList, flag) {
       const _this = this
       if (this.isBatch) {
@@ -259,7 +262,7 @@ export default {
         }
       })
     },
-    // 批量审核
+    // 批量入库确认
     handleBatchAudit () {
       const _this = this
       if (!_this.rowSelectionInfo || (_this.rowSelectionInfo && _this.rowSelectionInfo.selectedRowKeys.length < 1)) {
@@ -269,6 +272,7 @@ export default {
       this.isBatch = true
       this.confirmationModal = true
     },
+    // 页面初始
     pageInit () {
       const _this = this
       this.$nextTick(() => { // 页面渲染完成后的回调
@@ -277,6 +281,7 @@ export default {
       this.rowSelectionInfo = null
       this.$refs.table.clearTable()
     },
+    // 表格高度
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
       this.tableHeight = window.innerHeight - tableSearchH - 240