lilei 2 gadi atpakaļ
vecāks
revīzija
826734521f

+ 9 - 0
src/api/spareParts.js

@@ -12,6 +12,15 @@ export const sparePartsList = (params) => {
   })
   })
 }
 }
 
 
+export const sparePartsDetailExport = (params) => {
+  return axios({
+    url: '/spareParts/detail/export',
+    data: params,
+    method: 'post',
+    responseType: 'blob'
+  })
+}
+
 // 审核
 // 审核
 export const sparePartsAudit = (params) => {
 export const sparePartsAudit = (params) => {
   return axios({
   return axios({

+ 27 - 2
src/views/purchasingManagement/bulkWarehousingOrder/list.vue

@@ -57,6 +57,14 @@
               <span class="table-page-search-submitButtons">
               <span class="table-page-search-submitButtons">
                 <a-button type="primary" @click="$refs.table.refresh(true)" :disabled="disabled" id="bulkWarehousingOrderList-refresh">查询</a-button>
                 <a-button type="primary" @click="$refs.table.refresh(true)" :disabled="disabled" id="bulkWarehousingOrderList-refresh">查询</a-button>
                 <a-button style="margin-left: 5px" @click="resetSearchForm()" :disabled="disabled" id="bulkWarehousingOrderList-reset">重置</a-button>
                 <a-button style="margin-left: 5px" @click="resetSearchForm()" :disabled="disabled" id="bulkWarehousingOrderList-reset">重置</a-button>
+                <a-button
+                  style="margin-left: 10px"
+                  type="primary"
+                  class="button-warning"
+                  @click="handleExport"
+                  :disabled="disabled"
+                  :loading="exportLoading"
+                >导出明细</a-button>
               </span>
               </span>
             </a-col>
             </a-col>
           </a-row>
           </a-row>
@@ -127,6 +135,8 @@
     <!-- 选择基本信息弹框 -->
     <!-- 选择基本信息弹框 -->
     <basic-info-modal :openModal="openModal" @ok="handleOk" @close="openModal=false" />
     <basic-info-modal :openModal="openModal" @ok="handleOk" @close="openModal=false" />
     <sparePartsDetailModal :openModal="openDetailModal" :itemSn="itemSn" @close="closeDetailModal" />
     <sparePartsDetailModal :openModal="openDetailModal" :itemSn="itemSn" @close="closeDetailModal" />
+    <!-- 导出提示框 -->
+    <reportModal :visible="showExport" @close="showExport=false"></reportModal>
   </a-card>
   </a-card>
 </template>
 </template>
 
 
@@ -135,16 +145,20 @@ import { commonMixin } from '@/utils/mixin'
 import { STable, VSelect } from '@/components'
 import { STable, VSelect } from '@/components'
 import basicInfoModal from './basicInfoModal.vue'
 import basicInfoModal from './basicInfoModal.vue'
 import sparePartsDetailModal from './detailModal.vue'
 import sparePartsDetailModal from './detailModal.vue'
-import { sparePartsList, sparePartsDelete, sparePartsAudit } from '@/api/spareParts'
+import reportModal from '@/views/common/reportModal.vue'
+import { hdExportExcel } from '@/libs/exportExcel'
+import { sparePartsList, sparePartsDelete, sparePartsAudit, sparePartsDetailExport } from '@/api/spareParts'
 export default {
 export default {
   name: 'BulkWarehousingOrderList',
   name: 'BulkWarehousingOrderList',
   mixins: [commonMixin],
   mixins: [commonMixin],
-  components: { STable, VSelect, basicInfoModal, sparePartsDetailModal },
+  components: { STable, VSelect, basicInfoModal, sparePartsDetailModal, reportModal },
   data () {
   data () {
     return {
     return {
       spinning: false,
       spinning: false,
       disabled: false, //  查询、重置按钮是否可操作
       disabled: false, //  查询、重置按钮是否可操作
       openModal: false, // 基本信息弹框是否显示
       openModal: false, // 基本信息弹框是否显示
+      showExport: false,
+      exportLoading: false,
       tableHeight: 0,
       tableHeight: 0,
       // 查询参数
       // 查询参数
       queryParam: {
       queryParam: {
@@ -206,6 +220,17 @@ export default {
     rowSelectionFun (obj) {
     rowSelectionFun (obj) {
       this.rowSelectionInfo = obj || null
       this.rowSelectionInfo = obj || null
     },
     },
+    //  导出
+    handleExport () {
+      const _this = this
+      _this.exportLoading = true
+      _this.spinning = true
+      hdExportExcel(sparePartsDetailExport, _this.queryParam, '散件入库明细', function () {
+        _this.exportLoading = false
+        _this.spinning = false
+        _this.showExport = true
+      })
+    },
     //  新增
     //  新增
     handleAdd () {
     handleAdd () {
       this.openModal = true
       this.openModal = true

+ 1 - 1
src/views/salesManagement/salesQuery/list.vue

@@ -396,13 +396,13 @@ export default {
     //  导出
     //  导出
     handleExport () {
     handleExport () {
       const _this = this
       const _this = this
-      _this.showExport = true
       const params = _this.queryParam
       const params = _this.queryParam
       _this.exportLoading = true
       _this.exportLoading = true
       _this.spinning = true
       _this.spinning = true
       hdExportExcel(salesDetailExport, params, '销售明细', function () {
       hdExportExcel(salesDetailExport, params, '销售明细', function () {
         _this.exportLoading = false
         _this.exportLoading = false
         _this.spinning = false
         _this.spinning = false
+        _this.showExport = true
       })
       })
     },
     },
     //  时间  change
     //  时间  change

+ 8 - 5
src/views/salesReturnManagement/billOfLading/list.vue

@@ -293,7 +293,7 @@ export default {
         }
         }
       })
       })
     },
     },
-    resetSearchForm () {
+    resetSearchForm (flag) {
       this.$refs.rangeCreateDate.resetDate()
       this.$refs.rangeCreateDate.resetDate()
       if (this.advanced) {
       if (this.advanced) {
         this.$refs.rangeExamineDate.resetDate()
         this.$refs.rangeExamineDate.resetDate()
@@ -307,7 +307,7 @@ export default {
       this.queryParam.senderSn = undefined
       this.queryParam.senderSn = undefined
       this.queryParam.applyPersonSn = undefined
       this.queryParam.applyPersonSn = undefined
       this.queryParam.logisticsPoint = undefined
       this.queryParam.logisticsPoint = undefined
-      this.queryParam.salesReturnBillNo = ''
+      this.queryParam.salesReturnBillNo = flag ? this.$route.query.billNo : ''
       this.queryParam.state = undefined
       this.queryParam.state = undefined
       this.$refs.table.refresh(true)
       this.$refs.table.refresh(true)
     },
     },
@@ -335,19 +335,22 @@ export default {
   },
   },
   mounted () {
   mounted () {
     if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
     if (!this.$store.state.app.isNewTab) { // 页签刷新时调用
+      this.resetSearchForm(!!this.$route.query.billNo)
       this.pageInit()
       this.pageInit()
-      this.resetSearchForm()
     }
     }
   },
   },
   activated () {
   activated () {
     // 如果是新页签打开,则重置当前页面
     // 如果是新页签打开,则重置当前页面
     if (this.$store.state.app.isNewTab) {
     if (this.$store.state.app.isNewTab) {
+      this.resetSearchForm(!!this.$route.query.billNo)
       this.pageInit()
       this.pageInit()
-      this.resetSearchForm()
+    } else {
+      this.setTableH()
+      this.resetSearchForm(!!this.$route.query.billNo)
     }
     }
     // 仅刷新列表,不重置页面
     // 仅刷新列表,不重置页面
     if (this.$store.state.app.updateList) {
     if (this.$store.state.app.updateList) {
-      this.pageInit()
+      this.setTableH()
       this.$refs.table.refresh()
       this.$refs.table.refresh()
     }
     }
   },
   },

+ 17 - 4
src/views/salesReturnManagement/salesReturn/list.vue

@@ -129,6 +129,10 @@
           </div>
           </div>
           <div v-else>{{ record.salesReturnBillNo }}</div>
           <div v-else>{{ record.salesReturnBillNo }}</div>
         </template>
         </template>
+        <!-- 提货单 -->
+        <template slot="pickUpSalesReturnNum" slot-scope="text, record">
+          <span class="link-bule" @click="handleBillOfLadingDetail(record)">{{ record.pickUpSalesReturnNum }}</span>
+        </template>
         <!-- 操作 -->
         <!-- 操作 -->
         <template slot="action" slot-scope="text, record">
         <template slot="action" slot-scope="text, record">
           <div>
           <div>
@@ -280,8 +284,8 @@ export default {
     columns () {
     columns () {
       const arr = [
       const arr = [
         { title: '编号', dataIndex: 'no', width: '4%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '编号', dataIndex: 'no', width: '4%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '创建时间', dataIndex: 'createDate', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '单据来源', dataIndex: 'salesReturnBillSourceDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '创建时间', dataIndex: 'createDate', width: '5%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '单据来源', dataIndex: 'salesReturnBillSourceDictValue', width: '5%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '是否同步给客户', dataIndex: 'syncFlag', width: '5%', align: 'center', customRender: function (text) { return text ? ['否', '是'][text] : '--' } },
         { title: '是否同步给客户', dataIndex: 'syncFlag', width: '5%', align: 'center', customRender: function (text) { return text ? ['否', '是'][text] : '--' } },
         { title: '客户采退申请单号', dataIndex: 'purchaseReturnApplyNo', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '客户采退申请单号', dataIndex: 'purchaseReturnApplyNo', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '总部销退单号', scopedSlots: { customRender: 'salesReturnBillNo' }, width: '10%', align: 'center' },
         { title: '总部销退单号', scopedSlots: { customRender: 'salesReturnBillNo' }, width: '10%', align: 'center' },
@@ -292,8 +296,9 @@ export default {
         { title: '良品数量', dataIndex: 'totalGoodQty', width: '5%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '良品数量', dataIndex: 'totalGoodQty', width: '5%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '返库数量', dataIndex: 'totalBackStockQty', width: '5%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '返库数量', dataIndex: 'totalBackStockQty', width: '5%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '实际退货金额', dataIndex: 'totalAmount', width: '5%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '实际退货金额', dataIndex: 'totalAmount', width: '5%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
-        { title: '审核时间', dataIndex: 'auditTime', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '业务状态', dataIndex: 'billStatusDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '审核时间', dataIndex: 'auditTime', width: '5%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '提货单', dataIndex: 'pickUpSalesReturnNum', scopedSlots: { customRender: 'pickUpSalesReturnNum' }, width: '4%', align: 'center' },
+        { title: '业务状态', dataIndex: 'billStatusDictValue', width: '5%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: '8%', align: 'center' }
         { title: '操作', scopedSlots: { customRender: 'action' }, width: '8%', align: 'center' }
       ]
       ]
       return arr
       return arr
@@ -356,6 +361,14 @@ export default {
     handleDetail (row) {
     handleDetail (row) {
       this.$router.push({ name: 'salesReturnDetail', params: { sn: row.salesReturnBillSn } })
       this.$router.push({ name: 'salesReturnDetail', params: { sn: row.salesReturnBillSn } })
     },
     },
+    // 提货单查看
+    handleBillOfLadingDetail (row) {
+      if (row.pickUpSalesReturnNum == '0单') {
+        this.$message.info('此销售退货单没有提货单')
+      } else {
+        this.$router.push({ name: 'billOfLadingList', query: { billNo: row.salesReturnBillNo } })
+      }
+    },
     // 删除
     // 删除
     handleDel (row) {
     handleDel (row) {
       const _this = this
       const _this = this