Browse Source

收货品检

chenrui 2 năm trước cách đây
mục cha
commit
19987c19e6

+ 11 - 0
src/api/checkWarehouse.js

@@ -2,6 +2,17 @@ import { axios } from '@/utils/request'
 
 //  库存盘点  列表  分页
 export const checkWarehouseList = (params) => {
+  const url = `/checkWarehouse/queryPage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post'
+  })
+}
+//  盘点确认  列表  分页
+export const verifyQueryPage = (params) => {
   const url = `/checkWarehouse/verifyQueryPage/${params.pageNo}/${params.pageSize}`
   delete params.pageNo
   delete params.pageSize

+ 12 - 1
src/api/pickUp.js

@@ -11,6 +11,17 @@ export const pickUpQueryPage = (params) => {
     method: 'post'
   })
 }
+//  仓库提货列表  分页
+export const warehouseQueryPage = (params) => {
+  const url = `/pickUp/warehouseQueryPage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post'
+  })
+}
 // 提货
 export const pickUpFinish = (params) => {
   return axios({
@@ -102,4 +113,4 @@ export const pickUpDetailPrint = params => {
     method: 'post',
     responseType: 'blob'
   })
-}
+}

+ 12 - 1
src/api/salesReturn.js

@@ -89,6 +89,17 @@ export const salesReturnList = (params) => {
     method: 'post'
   })
 }
+//  收货品检 分页查询产品
+export const takeQueryPage = (params) => {
+  const url = `/salesReturn/takeQueryPage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post'
+  })
+}
 // 销售退货 统计
 export const salesReturnQueryCount = (params) => {
   const url = `/salesReturn/queryCount`
@@ -157,7 +168,7 @@ export const salesReturnFinancialDetailList = (params) => {
   })
 }
 
-//销售退货 客服确认
+// 销售退货 客服确认
 export const customerServiceConfirm = (params) => {
   return axios({
     url: `/salesReturn/customerServiceConfirm/${params.salesReturnBillSn}`,

+ 2 - 2
src/views/financialManagement/inventoryConfirmation/list.vue

@@ -72,7 +72,7 @@
 import { commonMixin } from '@/utils/mixin'
 import { STable, VSelect } from '@/components'
 import chooseWarehouse from '@/views/common/chooseWarehouse'
-import { checkWarehouseList, checkWarehouseReCheck, checkWarehouseFinanceAudit } from '@/api/checkWarehouse'
+import { verifyQueryPage, checkWarehouseReCheck, checkWarehouseFinanceAudit } from '@/api/checkWarehouse'
 export default {
   name: 'InventoryConfirmationList',
   mixins: [commonMixin],
@@ -96,7 +96,7 @@ export default {
       loadData: parameter => {
         this.disabled = true
         this.spinning = true
-        return checkWarehouseList(Object.assign(parameter, this.queryParam)).then(res => {
+        return verifyQueryPage(Object.assign(parameter, this.queryParam)).then(res => {
           let data
           if (res.status == 200) {
             data = res.data

+ 17 - 10
src/views/salesReturnManagement/billOfLading/add.vue

@@ -87,11 +87,6 @@
                 />
               </a-form-model-item>
             </a-col>
-            <a-col :md="24">
-              <a-form-model-item label="出库仓库" :label-col="{span:2}" :wrapper-col="{span:20}">
-                <chooseWarehouse ref="warehouse" @change="handleWarehouse"></chooseWarehouse>
-              </a-form-model-item>
-            </a-col>
             <a-col :span="24">
               <a-form-model-item label="运费" :label-col="{span:2}" :wrapper-col="{span:20}">
                 <a-input
@@ -114,6 +109,11 @@
                   placeholder="请输入备注(最多500个字符)" />
               </a-form-model-item>
             </a-col>
+            <a-col :spna="24">
+              <a-form-model-item label="出库仓库" :label-col="{span:2}" :wrapper-col="{span:20}" prop="warehouseSn">
+                <chooseWarehouse ref="warehouse" v-model="form.warehouseSn" @change="handleWarehouse"></chooseWarehouse>
+              </a-form-model-item>
+            </a-col>
             <a-col :spna="24">
               <a-form-model-item label="附件" help="说明:支持图片、word、excel、PDF等格式,最多10个附件。" :label-col="{span:2}" :wrapper-col="{span:20}">
                 <Upload
@@ -130,7 +130,7 @@
                   upText="上传附件"></Upload>
               </a-form-model-item>
             </a-col>
-            <a-col :spna="24">
+            <a-col :spna="24" v-show="form.warehouseSn">
               <a-form-model-item label="关联销退单" :label-col="{span:2}" :wrapper-col="{span:20}">
                 <a-button type="primary" class="button-primary" @click="openSelModal">选择销退单</a-button>
                 <div style="margin-top:10px;">
@@ -186,6 +186,7 @@
       modalTit="选择销退单"
       :chooseData="chooseData"
       :openModal="showXtModal"
+      :warehouseSn="form.warehouseSn"
       @cancel="closeModal"></selectXtModal>
     <!-- 选择审核人员 -->
     <chooseDepartUserModal :showDefUser="false" :openModal="openDepartUserModal" @close="closeModal" @submit="handleSubmit"></chooseDepartUserModal>
@@ -231,7 +232,8 @@ export default {
         goodsNum: '', // 件数
         freight: '', // 运费
         remarks: '',
-        attachmentList: '' // 附件
+        attachmentList: '', // 附件
+        warehouseSn: undefined// 出库仓库
       },
       attachList: [],
       rules: {
@@ -240,6 +242,9 @@ export default {
         ],
         theme: [
           { required: true, message: '请输入主题', trigger: 'blur' }
+        ],
+        warehouseSn: [
+          { required: true, message: '请选择出库仓库', trigger: 'change' }
         ]
       },
       chooseData: [],
@@ -257,7 +262,10 @@ export default {
   methods: {
     // 选择出库仓库
     handleWarehouse (val) {
-
+      this.form.warehouseSn = val
+      if (val) {
+        this.getReturnOrderList(val)
+      }
     },
     custChange (val) {
       this.form.senderSn = val.key
@@ -278,7 +286,7 @@ export default {
       this.spinning = false
     },
     // 关联销售退货单
-    getReturnOrderList () {
+    getReturnOrderList (infoSn) {
       pickUpDetailQueryList({ pickUpSn: this.$route.params.sn }).then(res => {
         this.chooseData = []
         res.data.map(item => {
@@ -411,7 +419,6 @@ export default {
       if (this.$route.params.sn) {
         this.form.theme = ''
         this.getDetail()
-        this.getReturnOrderList()
       } else {
         this.chooseData = []
         // 从销售退货列表过来的数据

+ 6 - 0
src/views/salesReturnManagement/billOfLading/selectXtModal.vue

@@ -44,6 +44,7 @@
           :data="loadData"
           :scroll="{ y: 400 }"
           :pageSize="10"
+          :defaultLoadData="false"
           bordered>
           <!-- 收款单号 -->
           <template slot="salesReturnBillNo" slot-scope="text, record">
@@ -90,6 +91,10 @@ export default {
       default: function () {
         return []
       }
+    },
+    warehouseSn: {
+      type: String,
+      default: null
     }
   },
   data () {
@@ -116,6 +121,7 @@ export default {
       loadData: parameter => {
         this.disabled = true
         this.spinning = true
+        this.queryParam.warehouseSn = this.warehouseSn
         return salesReturnList(Object.assign(parameter, this.queryParam)).then(res => {
           let data
           if (res.status == 200) {

+ 8 - 9
src/views/salesReturnManagement/pickUp/list.vue

@@ -50,7 +50,7 @@
               </a-col>
               <a-col :md="6" :sm="24" v-show="isShowWarehouse">
                 <a-form-model-item label="出库仓库">
-                  <chooseWarehouse ref="warehouse" @change="handleWarehouse" :isPermission="true"></chooseWarehouse>
+                  <chooseWarehouse ref="warehouse" v-model="queryParam.warehouseSn" :isPermission="true"></chooseWarehouse>
                 </a-form-model-item>
               </a-col>
             </template>
@@ -121,7 +121,7 @@ import employee from '../../expenseManagement/expenseReimbursement/employee.js'
 import logisticsPoint from '../billOfLading/logisticsPoint'
 import rangeDate from '@/views/common/rangeDate.vue'
 import chooseWarehouse from '@/views/common/chooseWarehouse'
-import { pickUpQueryPage, pickUpFinish } from '@/api/pickUp'
+import { warehouseQueryPage, pickUpFinish } from '@/api/pickUp'
 export default {
   name: 'PickUpList',
   mixins: [commonMixin],
@@ -151,13 +151,14 @@ export default {
         logisticsPoint: undefined, // 物流点
         senderSn: undefined, //  发货人
         state: 'AUDIT_PASS', // 业务状态
-        stateList: ['FINISH', 'AUDIT_PASS']
+        stateList: ['FINISH', 'AUDIT_PASS'],
+        warehouseSn: undefined
       },
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
         this.spinning = true
-        return pickUpQueryPage(Object.assign(parameter, this.queryParam)).then(res => {
+        return warehouseQueryPage(Object.assign(parameter, this.queryParam)).then(res => {
           let data
           if (res.status == 200) {
             data = res.data
@@ -190,19 +191,16 @@ export default {
         { title: '发货方', dataIndex: 'dealerEntity.dealerName', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '收货人', dataIndex: 'receiverName', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '状态', dataIndex: 'stateDictValue', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
-        // { title: '出库仓库', dataIndex: 'warehouse', width: '10%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        // { title: '出库仓库', dataIndex: 'warehouseName', width: '10%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: '6%', align: 'center' }
       ]
       if (this.isShowWarehouse) {
-        arr.splice(11, 0, { title: '出库仓库', dataIndex: 'warehouse', width: '10%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true })
+        arr.splice(11, 0, { title: '出库仓库', dataIndex: 'warehouseName', width: '10%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true })
       }
       return arr
     }
   },
   methods: {
-    handleWarehouse (val) {
-
-    },
     //  审核时间  change
     dateExamineChange (date) {
       this.queryParam.auditBeginDate = date[0] ? date[0] : ''
@@ -247,6 +245,7 @@ export default {
       this.queryParam.logisticsPoint = undefined
       this.queryParam.salesReturnBillNo = ''
       this.queryParam.state = undefined
+      this.queryParam.warehouseSn = undefined
       this.queryParam.stateList = ['FINISH', 'AUDIT_PASS']
       this.$refs.table.refresh(true)
     },

+ 9 - 11
src/views/salesReturnManagement/receiveCheck/list.vue

@@ -33,8 +33,8 @@
               </a-form-item>
             </a-col>
             <a-col :md="6" :sm="24" v-show="isShowWarehouse">
-              <a-form-model-item label="出库仓库" >
-                <chooseWarehouse ref="warehouse" @change="handleWarehouse" :isPermission="true"></chooseWarehouse>
+              <a-form-model-item label="出库仓库">
+                <chooseWarehouse ref="warehouse" v-model="queryParam.warehouseSn" :isPermission="true"></chooseWarehouse>
               </a-form-model-item>
             </a-col>
             <a-col :md="6" :sm="24">
@@ -110,7 +110,7 @@ import { STable, VSelect } from '@/components'
 import dealerSubareaScopeList from '@/views/common/dealerSubareaScopeList.vue'
 import employee from '../../expenseManagement/expenseReimbursement/employee.js'
 import rangeDate from '@/views/common/rangeDate.vue'
-import { salesReturnList } from '@/api/salesReturn'
+import { takeQueryPage } from '@/api/salesReturn'
 import printModal from './printModal.vue'
 import chooseWarehouse from '@/views/common/chooseWarehouse'
 import commonModal from '@/views/common/commonModal.vue'
@@ -141,13 +141,14 @@ export default {
         endAuditDate: '',
         buyerSn: undefined, //  客户名称
         salesReturnBillNo: undefined, //  总部销退单号
-        billStatus: undefined // 业务状态
+        billStatus: undefined, // 业务状态
+        warehouseSn: undefined
       },
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
         this.spinning = true
-        return salesReturnList(Object.assign(parameter, this.queryParam, {
+        return takeQueryPage(Object.assign(parameter, this.queryParam, {
           'excludeBillStatusList': ['WAIT_SUBMIT', 'WAIT_AUDIT', 'AUDIT_REJECT', 'CANCEL']
         })).then(res => {
           let data
@@ -176,7 +177,7 @@ export default {
         { title: '审核时间', dataIndex: 'auditTime', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '总部销退单号', scopedSlots: { customRender: 'salesReturnBillNo' }, width: '10%', align: 'center' },
         { title: '客户名称', dataIndex: 'buyerName', width: '10%', align: 'left', customRender: function (text) { return text || '--' }, ellipsis: true },
-        // { title: '出库仓库', dataIndex: 'warehouse', width: '8%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        // { title: '出库仓库', dataIndex: 'warehouseName', width: '8%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '申请退货数量', dataIndex: 'totalInitialQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '仓库实收数量', dataIndex: 'totalReceiveQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '坏件数量', dataIndex: 'totalBadQty', width: '5%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
@@ -186,16 +187,12 @@ export default {
         { title: '操作', scopedSlots: { customRender: 'action' }, width: '6%', align: 'center' }
       ]
       if (this.isShowWarehouse) {
-        arr.splice(4, 0, { title: '出库仓库', dataIndex: 'warehouse', width: '8%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true })
+        arr.splice(4, 0, { title: '出库仓库', dataIndex: 'warehouseName', width: '8%', align: 'left', customRender: function (text) { return text || '--' }, ellipsis: true })
       }
       return arr
     }
   },
   methods: {
-    // 选择出库仓库
-    handleWarehouse (val) {
-
-    },
     //  审核时间  change
     dateExamineChange (date) {
       this.queryParam.beginAuditDate = date[0]
@@ -224,6 +221,7 @@ export default {
       this.queryParam.buyerSn = undefined
       this.queryParam.salesReturnBillNo = ''
       this.queryParam.billStatus = undefined
+      this.queryParam.warehouseSn = undefined
       this.$refs.table.refresh(true)
     },
     pageInit () {