Переглянути джерело

Merge branch 'master' of http://git.zthymaoyi.com/gdc/yiliangyiyun-pc

gjy 2 роки тому
батько
коміт
7669e6ae51

+ 22 - 7
public/static/payprint1.html

@@ -548,9 +548,11 @@
 
               <div class="sfcard-content part2">
                 <div class="sfcard-title">
-                  {{printData1[index].identityAuthenticationInfo.bankDeposit}}{{printData1[index].identityAuthenticationInfo.bankCard}}
+                  {{printData1[index].bankDeposit}}{{printData1[index].bankCard}}
                 </div>
-                <img :src="customerList1[index].imgURl.imageUrl3" class="avatar" />
+                <!-- <img :src="customerList1[index].imgURl.imageUrl3" class="avatar" /> -->
+                <img :src="printData1[index].imgURl.imageUrl3" class="avatar" />
+                <img :src="printData1[index].imgURl.imageUrl4" class="avatar" />
               </div>
     <!--          <div class="sfcard-content part2">
                 <div class="sfcard-title">
@@ -881,13 +883,13 @@
         <div class="bankcard part4" v-if="isShowPrintType2">
           <div class="sfcard-content">
             <div class="sfcard-title">
-              {{printData.identityAuthenticationInfo.bankDeposit}}{{printData.identityAuthenticationInfo.bankCard}}
+              {{printData.bankDeposit}}{{printData.bankCard}}
             </div>
             <img :src="imageUrl3" class="avatar" />
           </div>
           <div class="sfcard-content">
             <div class="sfcard-title">
-              {{printData.identityAuthenticationInfo.bankDeposit}}{{printData.identityAuthenticationInfo.bankCard}}
+              {{printData.bankDeposit}}{{printData.bankCard}}
             </div>
             <img :src="imageUrl4" class="avatar" />
           </div>
@@ -1184,12 +1186,19 @@
           if (this.selectPrint) {
             for (let i = 0; i < this.customerList1.length; i++) {
               let _url1 = this.customerList1[i].cardAddressUrl.split(',')
-              let _url2 = this.customerList1[i].payeeAddressUrl.split(',')
+              // let _url2 = this.customerList1[i].payeeAddressUrl.split(',')
               this.customerList1[i].imgURl = {
                 imageUrl1: _url1[0],
                 imageUrl2: _url1[1],
+                // imageUrl3: _url2[0],
+                // imageUrl4: _url2[0]
+              }
+            }
+            for (let i = 0; i < this.printData1.length; i++) {
+              let _url2 = this.printData1[i].payeeAddressUrl.split(',')
+              this.printData1[i].imgURl = {
                 imageUrl3: _url2[0],
-                imageUrl4: _url2[0]
+                imageUrl4: _url2[1]
               }
             }
           } else {
@@ -1198,12 +1207,18 @@
               this.imageUrl1 = this.identity[0]
               this.imageUrl2 = this.identity[1]
             }
+            console.log(this.customerList)
             if (this.customerList.payeeAddressUrl) {
               this.bank = this.customerList.payeeAddressUrl.split(',')
-
               this.imageUrl3 = this.bank[0]
               this.imageUrl4 = this.bank[1]
             }
+            if (this.printData.payeeAddressUrl){
+              this.bank = this.printData.payeeAddressUrl.split(',')
+              this.imageUrl3 = this.bank[0]
+              this.imageUrl4 = this.bank[1]
+            }
+
             this.tableData = this.printData.weighingManagement
           }
           let _lsit = this.showType.split(',')

+ 2 - 0
src/api/V2/warehouse/index.js

@@ -83,6 +83,8 @@ export const API_GET_RECEIPTTASKNO = '/inOutWarehouseTask/selectInOutWarehouseNo
 export const API_POST_EXPORT = '/warehouseBaseInfo/export'
 //导出出库
 export const API_POST_EXPORTOUT = '/warehouseBaseInfo/exportOut'
+//导出历史库存记录
+export const API_POST_EXPORTHISTORICALINVENTORY = '/historicalInventoryInfo/exportHistoricalInventory'
 //打印增量
 export const API_GET_PRINT = '/commonConstantFalse/getInfo'
 // 仓位号

+ 3 - 1
src/model/warehouse/index.js

@@ -43,7 +43,7 @@ import {
     API_GET_PRINT,
     API_POST_EXPORTOUT,
     API_GET_WAREHOUSE_BINNUMBER,
-
+    API_POST_EXPORTHISTORICALINVENTORY,
     API_GET_WAREHOUSE_BASEINFO_RESERVES,
     API_GET_TURNAROUND_LIST,
     API_POST_TURNAROUND_ADD,
@@ -144,6 +144,8 @@ export const getReceiptTaskNo = appRx.get(API_GET_RECEIPTTASKNO,errorCatcher, er
 export const postExport = appRx.post(API_POST_EXPORT)
 //导出出库
 export const postExportOut = appRx.post(API_POST_EXPORTOUT)
+//导出历史库存记录
+export const exportHistoricalInventory = appRx.post(API_POST_EXPORTHISTORICALINVENTORY)
 //打印增量
 export const printAdd = appRx.get(API_GET_PRINT,errorCatcher, errorHandle, filter)
 //仓位号

+ 21 - 3
src/views/houseSelfCollect/paymentManagement.vue

@@ -408,6 +408,9 @@
         deleteshow: false,
         customerlist: {
           payeeAddressUrls: [],
+          bankCard:'',
+          bankDeposit:'',
+          bankDepositBranch:''
         },
 
         ruleForm: {
@@ -475,6 +478,7 @@
         excelFreightspace: [],
         goodnameList: [],
         goodsName: '全部',
+
       }
     },
     mounted() {
@@ -833,6 +837,7 @@
 
       },
       customer(row) {
+
         getCustomerLook({
             id: row.identityId,
             authenticationStatusKey: 7,
@@ -845,8 +850,21 @@
               this.customerlist.cardAddressUrl.split(',')[0]
             this.customerlist.cardAddressUrl2 =
               this.customerlist.cardAddressUrl.split(',')[1]
-            this.customerlist.payeeAddressUrls =
-              this.customerlist.payeeAddressUrl.split(',')
+            if(row.payeeAddressUrl){
+              this.customerlist.payeeAddressUrls = row.payeeAddressUrl.split(',')
+            }  
+            else{
+              this.customerlist.payeeAddressUrls = this.customerlist.payeeAddressUrl.split(',')
+            }
+            if(row.bankCard){
+              this.customerlist.bankCard = row.bankCard
+            }
+            if(row.bankDeposit){
+              this.customerlist.bankDeposit = row.bankDeposit
+            }
+            if(row.bankDepositBranch){
+              this.customerlist.bankDepositBranch = row.bankDepositBranch
+            }
           })
       },
       customerclose(e) {
@@ -951,7 +969,7 @@
           let index1 = 0
           let index2 = 0
           for (let i = 0; i < this.modification.length; i++) {
-            await getCustomerLook({
+            await getCustomerLook({  
                 id: this.modification[i].identityId,
                 authenticationStatusKey: 7,
               })

+ 94 - 0
src/views/warehousenew/warehouseManagementList.vue

@@ -81,6 +81,7 @@
       <ws-button v-if='list.length>0' @click="handlTask()">任务</ws-button>
       <ws-button v-hasPermission="`warehouseManagement.warehouse.warehouseInfo.add`" @click="outData(1)">导出</ws-button>
       <ws-button @click="outData(2)">打印</ws-button>
+      <ws-button v-hasPermission="`warehouseManagement.warehouse.warehouseInfo.kan`" @click="exportHistoricalData()">导出历史库存记录</ws-button>
       <ws-button @click="transformation()" v-hasPermission=" `warehouseManagement.warehouse.warehouseInfo.view`">折转</ws-button>
       <ws-button v-hasPermission="`warehouseManagement.warehouse.warehouseInfo.kan`" @click="handleall()">全部仓库</ws-button>
       <ws-button v-hasPermission="`warehouseManagement.warehouse.warehouseInfo.kan`" @click="handleMintor()">查看监控</ws-button>
@@ -251,6 +252,35 @@
         <el-button @click="removePrint">取消</el-button>
       </div>
     </div>
+    <div class="mask" v-show="isShowPrintType1"></div>
+    <div class="print-type" v-show="isShowPrintType1">
+      <div class="print-type-content">
+        <div class="print-type-title">{{headerText1}}</div>
+        <div class="print-type-checkbox">
+          <el-form ref="form" label-width="110px">
+            <el-form-item label="起始日期">
+              <el-date-picker value-format="yyyy-MM-dd" type="date" placeholder="请选择起始日期" v-model="parameter.startDate">
+              </el-date-picker>
+            </el-form-item>
+            <el-form-item label="截止日期">
+              <el-date-picker value-format="yyyy-MM-dd" type="date" placeholder="请选择截止日期" v-model="parameter.endDate">
+              </el-date-picker>
+            </el-form-item>
+            <!--仓库名称-->
+            <el-form-item label="仓库名称" span="1" prop="warehouseName">
+              <el-select v-model="parameter.warehouseName" placeholder="请选择仓库名称" filterable clearable>
+                 <el-option key="" label="全部仓库" value="全部仓库" />
+                <el-option v-for="item in warehouseAllXiaLa" :key="item.warehouseName" :label="item.warehouseName" :value="item.warehouseName" />
+              </el-select>
+            </el-form-item>
+          </el-form>
+        </div>
+      </div>
+      <div class="bottom-btn">
+        <el-button @click="submitClick1()">确定</el-button>
+        <el-button @click="removePrint1">取消</el-button>
+      </div>
+    </div>
   </div>
 </template>
 <script>
@@ -259,6 +289,7 @@
     getsponsible,
     clearancee,
     xiala,
+    exportHistoricalInventory,
     postExport,
     addselectinfoList,
     printAdd,
@@ -332,6 +363,8 @@
         },
         isShowPrintType: false, //打印
         headerText: '',
+        isShowPrintType1: false,
+        headerText1: '导出历史库存记录',
         date: {
           year: dayjs().format('YYYY'),
           month: dayjs().format('MM'),
@@ -512,6 +545,67 @@
               }
             })
         }
+      },
+       //导出历史库存记录
+       exportHistoricalData() {
+        // 获取仓库
+        xiala({
+            compId: localStorage.getItem('ws-pf_compId'),
+            warehouseType: this.warehouseType,
+          })
+          .toPromise()
+          .then((response) => {
+            this.packtypeList = response
+          })
+        let date = new Date()
+        var year = date.getFullYear();
+        var month = date.getMonth() + 1;
+        var strDate = date.getDate()
+        var pastdate = new Date(date.getTime() - 24 * 60 * 60 * 1000)
+        this.parameter.startDate = pastdate.getFullYear() + '-' + (pastdate.getMonth() + 1) + '-' + pastdate.getDate()
+        this.parameter.endDate = '' + year + '-' + month + '-' + strDate
+        this.$forceUpdate();
+        this.isShowPrintType1 = true
+      },
+      removePrint1() {
+        this.parameter.warehouseName = ''
+        this.parameter.proportion = ''
+        this.isShowPrintType1 = false
+
+      },
+      async submitClick1() {
+
+        if (!this.parameter.startDate) {
+          this.$message.error('请选择打印的起始日期')
+          return
+        }
+        if (!this.parameter.endDate) {
+          this.$message.error('请选择打印的截止日期')
+          return
+        }
+        if (new Date(this.parameter.endDate).getTime() < new Date(this.parameter.startDate).getTime()) {
+          this.$message.error('截止日期输入错误')
+          return
+        }
+        if(this.parameter.warehouseName == '全部仓库'){
+          this.parameter.warehouseName = ''
+        }
+            const {
+              data
+            } = await exportHistoricalInventory({
+              startDate: this.parameter.startDate,
+              endDate: this.parameter.endDate,
+              warehouseName: this.parameter.warehouseName
+            }, {}, {
+              responseType: 'blob'
+            }).toPromise()
+            downloadFile({
+              res: data,
+              fileName: `${
+          this.date.year + (this.date.month ? `-${this.date.month}` : '')
+        }导出历史库存记录`,
+              type: 'xls',
+            })
       },
       handleClose(){
         this.indialog = false