Browse Source

bug 修复

lilei 3 years ago
parent
commit
b5f34b59af

+ 11 - 0
src/api/allocateReturn.js

@@ -65,6 +65,17 @@ export const allocateReturnQueryPage = (params) => {
     method: 'post'
   })
 }
+// 分页查询调拨退货确认列表
+export const allocateReturnQueryConfirmPage = (params) => {
+  const url = `/allocateReturn/queryConfirmPage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post'
+  })
+}
 // 保存调拨退货
 export const allocateReturnSave = params => {
   return axios({

+ 4 - 2
src/views/allocationManagement/transferReturn/detail.vue

@@ -145,8 +145,10 @@ export default {
       this.$router.push({ name: row.grapFlag == 1 ? 'transferReturnGrpEdit' : 'transferReturnEdit', params: { sn: row.allocateReturnSn, targetType: row.targetType } })
     },
     pageInit () {
-      this.$refs.table.refresh(true)
-      this.getDetail()
+      if (this.outBizSn || this.$route.params.sn) {
+        this.$refs.table.refresh(true)
+        this.getDetail()
+      }
     }
   },
   mounted () {

+ 14 - 14
src/views/financialManagement/allocateReturnConfirmation/list.vue

@@ -35,10 +35,10 @@
               <a-col :md="6" :sm="24">
                 <a-form-item label="状态">
                   <v-select
-                    v-model="queryParam.billStatus"
-                    ref="billStatus"
-                    id="transferReturnConfirmation-billStatus"
-                    code="ALLOCATE_RETURN_STATE"
+                    v-model="queryParam.state"
+                    ref="state"
+                    id="transferReturnConfirmation-state"
+                    code="ALLOCATE_RETURN_STATE_CONFIRM"
                     placeholder="请选择状态"
                     allowClear></v-select>
                 </a-form-item>
@@ -77,7 +77,7 @@
           <a-button
             size="small"
             type="link"
-            v-if="record.billStatus=='WAIT_FINANCIAL_AUDIT' && $hasPermissions('B_returnConfirmation_return')"
+            v-if="record.state=='WAIT_FINANCIAL_AUDIT' && $hasPermissions('B_returnConfirmation_return')"
             class="button-warning"
             @click="handleAudit(record)"
             id="transferReturnConfirmation-audit-btn">退货确认</a-button>
@@ -95,7 +95,7 @@ import { commonMixin } from '@/utils/mixin'
 import rangeDate from '@/views/common/rangeDate.vue'
 import { STable, VSelect } from '@/components'
 import AllocateReturnDetailModal from './detailModal.vue'
-import { allocateReturnQueryPage, allocateReturnFinanceAudit } from '@/api/allocateReturn'
+import { allocateReturnQueryConfirmPage, allocateReturnFinanceAudit } from '@/api/allocateReturn'
 export default {
   name: 'AllocateReturnConfirmationList',
   mixins: [commonMixin],
@@ -110,7 +110,7 @@ export default {
         allocateReturnNo: '', //  单号
         targetName: '',
         grabFlag: undefined,
-        billStatus: undefined //  状态
+        state: undefined //  状态
       },
       disabled: false, //  查询、重置按钮是否可操作
       advanced: true,
@@ -118,7 +118,7 @@ export default {
       loadData: parameter => {
         this.disabled = true
         this.spinning = true
-        return allocateReturnQueryPage(Object.assign(parameter, this.queryParam)).then(res => {
+        return allocateReturnQueryConfirmPage(Object.assign(parameter, this.queryParam)).then(res => {
           let data
           if (res.status == 200) {
             data = res.data
@@ -148,13 +148,13 @@ export default {
         { title: '退货总数量', dataIndex: 'totalQty', width: '7%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '坏件数量', dataIndex: 'totalBadQty', width: '7%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '返库数量', dataIndex: 'totalBackStockQty', width: '7%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        // { title: '退货总金额', dataIndex: 'totalReturnPrice', width: '7%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '确认时间', dataIndex: 'auditTime', width: '11%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '状态', dataIndex: 'billStatusDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
+        // { title: '退货总金额', dataIndex: 'totalPrice', width: '7%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '确认时间', dataIndex: 'financeAuditTime', width: '11%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '状态', dataIndex: 'stateDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: '8%', align: 'center' }
       ]
       if (this.$hasPermissions('B_isShowPrice')) { //  售价权限
-        arr.splice(8, 0, { title: '退货总金额', dataIndex: 'totalReturnPrice', width: '7%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } })
+        arr.splice(8, 0, { title: '退货总金额', dataIndex: 'totalPrice', width: '7%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } })
       }
       return arr
     }
@@ -176,7 +176,7 @@ export default {
       this.queryParam.allocateReturnNo = ''
       this.queryParam.targetName = ''
       this.queryParam.grabFlag = undefined
-      this.queryParam.billStatus = undefined
+      this.queryParam.state = undefined
       this.$refs.table.refresh(true)
     },
     // 详情
@@ -213,7 +213,7 @@ export default {
     auditOrder (sn, flag) {
       const _this = this
       _this.spinning = true
-      allocateReturnFinanceAudit({ allocateReturnSn: sn, billStatus: flag }).then(res => {
+      allocateReturnFinanceAudit({ allocateReturnSn: sn, state: flag }).then(res => {
         if (res.status == 200) {
           _this.$message.success(res.message)
           _this.$refs.table.refresh()