|
@@ -34,12 +34,15 @@
|
|
|
|
|
|
<ws-button type="primary" @click="reject">驳回</ws-button>
|
|
<ws-button type="primary" @click="reject">驳回</ws-button>
|
|
<ws-button type="primary" @click="adopt">通过</ws-button>
|
|
<ws-button type="primary" @click="adopt">通过</ws-button>
|
|
- <ws-button type="primary" @click="invoicingClick" v-hasPermission="`acquisitionManagement.acquisitionPay.finace`">开票</ws-button>
|
|
|
|
- <ws-button type="primary" @click="exportlist" v-hasPermission="`acquisitionManagement.acquisitionPay.print`">导出</ws-button>
|
|
|
|
|
|
+ <ws-button type="primary" @click="invoicingClick"
|
|
|
|
+ v-hasPermission="`acquisitionManagement.acquisitionPay.finace`">开票</ws-button>
|
|
|
|
+ <ws-button type="primary" @click="exportlist" v-hasPermission="`acquisitionManagement.acquisitionPay.print`">导出
|
|
|
|
+ </ws-button>
|
|
<!-- <ws-button type="primary" @click="handlepass" v-if="isShowAdopt">审核</ws-button> -->
|
|
<!-- <ws-button type="primary" @click="handlepass" v-if="isShowAdopt">审核</ws-button> -->
|
|
<ws-button type="primary" @click="payment" v-hasPermission="`acquisitionManagement.acquisitionPay.pay`">付款
|
|
<ws-button type="primary" @click="payment" v-hasPermission="`acquisitionManagement.acquisitionPay.pay`">付款
|
|
</ws-button>
|
|
</ws-button>
|
|
- <ws-button type="primary" @click="selectPrint(1)" v-hasPermission="`acquisitionManagement.acquisitionPay.finace`">财务批量打印
|
|
|
|
|
|
+ <ws-button type="primary" @click="selectPrint(1)"
|
|
|
|
+ v-hasPermission="`acquisitionManagement.acquisitionPay.finace`">财务批量打印
|
|
</ws-button>
|
|
</ws-button>
|
|
</template>
|
|
</template>
|
|
<template slot="right">
|
|
<template slot="right">
|
|
@@ -69,7 +72,8 @@
|
|
<el-table-column class="table_td" prop="paymentNo" width="100" label="编号" sortable></el-table-column>
|
|
<el-table-column class="table_td" prop="paymentNo" width="100" label="编号" sortable></el-table-column>
|
|
<el-table-column class="table_td" prop="customerName" label="客户" sortable>
|
|
<el-table-column class="table_td" prop="customerName" label="客户" sortable>
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
- <div @click.stop="customer(scope.row)"><span :class="{ text_css: scope.row.textcss }">{{scope.row.customerName}}</span></div>
|
|
|
|
|
|
+ <div @click.stop="customer(scope.row)"><span
|
|
|
|
+ :class="{ text_css: scope.row.textcss }">{{scope.row.customerName}}</span></div>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
<el-table-column class="table_td" prop="carNo" label="车牌号"></el-table-column>
|
|
<el-table-column class="table_td" prop="carNo" label="车牌号"></el-table-column>
|
|
@@ -170,6 +174,8 @@
|
|
:total="deptBudgetTotal"></el-pagination>
|
|
:total="deptBudgetTotal"></el-pagination>
|
|
<el-dialog width="70%" class="table-content" center :visible.sync="isShowPrint"
|
|
<el-dialog width="70%" class="table-content" center :visible.sync="isShowPrint"
|
|
:title="printData.compName + '结算凭证'">
|
|
:title="printData.compName + '结算凭证'">
|
|
|
|
+ <!-- selectCustomerList:[],
|
|
|
|
+ selectPrintList: [], -->
|
|
<paymentPrint :printData="printData" :customerInfo="customerList" :showType="ruleForm.type"></paymentPrint>
|
|
<paymentPrint :printData="printData" :customerInfo="customerList" :showType="ruleForm.type"></paymentPrint>
|
|
<div style="text-align: center">
|
|
<div style="text-align: center">
|
|
<el-button type="primary" @click="isShowPrint = false">关闭</el-button>
|
|
<el-button type="primary" @click="isShowPrint = false">关闭</el-button>
|
|
@@ -179,13 +185,7 @@
|
|
</el-dialog>
|
|
</el-dialog>
|
|
</div>
|
|
</div>
|
|
<!--客户信息-->
|
|
<!--客户信息-->
|
|
- <el-dialog
|
|
|
|
- width="50%"
|
|
|
|
- title="客户信息"
|
|
|
|
- :visible.sync="customerInfo"
|
|
|
|
- :append-to-body="true"
|
|
|
|
- :close="customerclose"
|
|
|
|
- >
|
|
|
|
|
|
+ <el-dialog width="50%" title="客户信息" :visible.sync="customerInfo" :append-to-body="true" :close="customerclose">
|
|
<el-form class="customer">
|
|
<el-form class="customer">
|
|
|
|
|
|
|
|
|
|
@@ -244,7 +244,7 @@
|
|
</div>
|
|
</div>
|
|
</template>
|
|
</template>
|
|
<script>
|
|
<script>
|
|
-import {
|
|
|
|
|
|
+ import {
|
|
dayjs,
|
|
dayjs,
|
|
EventBus
|
|
EventBus
|
|
} from 'base-core-lib'
|
|
} from 'base-core-lib'
|
|
@@ -277,7 +277,7 @@ import {
|
|
watch: {},
|
|
watch: {},
|
|
data() {
|
|
data() {
|
|
return {
|
|
return {
|
|
- printType:0,
|
|
|
|
|
|
+ printType: 0,
|
|
isShowPrintType1: true,
|
|
isShowPrintType1: true,
|
|
isShowPrintType2: true,
|
|
isShowPrintType2: true,
|
|
isShowPrintType3: true,
|
|
isShowPrintType3: true,
|
|
@@ -304,7 +304,8 @@ import {
|
|
bankCard: '',
|
|
bankCard: '',
|
|
bankDeposit: ''
|
|
bankDeposit: ''
|
|
},
|
|
},
|
|
- selectCustomerList:[],
|
|
|
|
|
|
+ selectCustomerList: [],
|
|
|
|
+ selectPrintList: [],
|
|
identity: [],
|
|
identity: [],
|
|
//分页
|
|
//分页
|
|
currentPage: 1,
|
|
currentPage: 1,
|
|
@@ -321,7 +322,6 @@ import {
|
|
warehouseName: '',
|
|
warehouseName: '',
|
|
isShowPrint: false,
|
|
isShowPrint: false,
|
|
printData: {},
|
|
printData: {},
|
|
- selectPrintList: [],
|
|
|
|
warehouse: [],
|
|
warehouse: [],
|
|
value1: '', //付款日期
|
|
value1: '', //付款日期
|
|
modification: [],
|
|
modification: [],
|
|
@@ -348,29 +348,28 @@ import {
|
|
// this.getList()
|
|
// this.getList()
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
- selectPrint(){
|
|
|
|
|
|
+ selectPrint() {
|
|
console.log('批量打印数据', this.modification)
|
|
console.log('批量打印数据', this.modification)
|
|
this.printType = 1
|
|
this.printType = 1
|
|
- this.isShowPrintType = true
|
|
|
|
-
|
|
|
|
|
|
+ this.isShowPrintType = true
|
|
},
|
|
},
|
|
- async exportlist() {
|
|
|
|
|
|
+ async exportlist() {
|
|
console.log('导出数据', this.modification)
|
|
console.log('导出数据', this.modification)
|
|
- let _data = {
|
|
|
|
|
|
+ let _data = {
|
|
paymentManagementList: this.modification
|
|
paymentManagementList: this.modification
|
|
}
|
|
}
|
|
- const {
|
|
|
|
- data
|
|
|
|
- } = await export1(_data, {}, {
|
|
|
|
- responseType: 'blob'
|
|
|
|
- }).toPromise()
|
|
|
|
- downloadFile({
|
|
|
|
- res: data,
|
|
|
|
- fileName: `${
|
|
|
|
|
|
+ const {
|
|
|
|
+ data
|
|
|
|
+ } = await export1(_data, {}, {
|
|
|
|
+ responseType: 'blob'
|
|
|
|
+ }).toPromise()
|
|
|
|
+ downloadFile({
|
|
|
|
+ res: data,
|
|
|
|
+ fileName: `${
|
|
this.date.year + (this.date.month ? `-${this.date.month}` : '')
|
|
this.date.year + (this.date.month ? `-${this.date.month}` : '')
|
|
}结算凭证`,
|
|
}结算凭证`,
|
|
- type: 'xls',
|
|
|
|
- })
|
|
|
|
|
|
+ type: 'xls',
|
|
|
|
+ })
|
|
|
|
|
|
},
|
|
},
|
|
invoicingClick() {
|
|
invoicingClick() {
|
|
@@ -384,23 +383,24 @@ import {
|
|
// console.log(response)
|
|
// console.log(response)
|
|
// })
|
|
// })
|
|
let data = {
|
|
let data = {
|
|
- paymentManagementList:this.modification
|
|
|
|
|
|
+ paymentManagementList: this.modification
|
|
}
|
|
}
|
|
console.log('开票', data)
|
|
console.log('开票', data)
|
|
//开票
|
|
//开票
|
|
invoicing(data)
|
|
invoicing(data)
|
|
.toPromise()
|
|
.toPromise()
|
|
.then(response => {
|
|
.then(response => {
|
|
- debugger
|
|
|
|
console.log(response)
|
|
console.log(response)
|
|
if (response.length > 0) {
|
|
if (response.length > 0) {
|
|
for (let i = 0; i < response.length; i++) {
|
|
for (let i = 0; i < response.length; i++) {
|
|
- //创建标签下载文件
|
|
|
|
|
|
+ // 创建标签下载文件
|
|
let a = document.createElement('a');
|
|
let a = document.createElement('a');
|
|
- a.href = response[i];
|
|
|
|
a.setAttribute('download', response[i]);
|
|
a.setAttribute('download', response[i]);
|
|
|
|
+ a.setAttribute('target', 'blank');
|
|
|
|
+ a.setAttribute('href', response[i]);
|
|
a.click();
|
|
a.click();
|
|
a.remove();
|
|
a.remove();
|
|
|
|
+
|
|
}
|
|
}
|
|
}
|
|
}
|
|
//未完成,接口调通后替换假数据
|
|
//未完成,接口调通后替换假数据
|
|
@@ -435,25 +435,25 @@ import {
|
|
.catch(() => {})
|
|
.catch(() => {})
|
|
},
|
|
},
|
|
customer(row) {
|
|
customer(row) {
|
|
- for(let i = 0 ; i < this.paymentList.length ; i++){
|
|
|
|
- if(row.id == this.paymentList[i].id){
|
|
|
|
|
|
+ for (let i = 0; i < this.paymentList.length; i++) {
|
|
|
|
+ if (row.id == this.paymentList[i].id) {
|
|
row.textcss = true
|
|
row.textcss = true
|
|
- }else{
|
|
|
|
|
|
+ } else {
|
|
this.paymentList[i].textcss = false
|
|
this.paymentList[i].textcss = false
|
|
}
|
|
}
|
|
}
|
|
}
|
|
row.textcss = true
|
|
row.textcss = true
|
|
- this. customerInfo = true
|
|
|
|
|
|
+ this.customerInfo = true
|
|
this.customerlist = row.identityAuthenticationInfo
|
|
this.customerlist = row.identityAuthenticationInfo
|
|
this.customerlist.cardAddressUrl1 = this.customerlist.cardAddressUrl.split(',')[0]
|
|
this.customerlist.cardAddressUrl1 = this.customerlist.cardAddressUrl.split(',')[0]
|
|
this.customerlist.cardAddressUrl2 = this.customerlist.cardAddressUrl.split(',')[1]
|
|
this.customerlist.cardAddressUrl2 = this.customerlist.cardAddressUrl.split(',')[1]
|
|
this.customerlist.payeeAddressUrls = this.customerlist.payeeAddressUrl.split(',')
|
|
this.customerlist.payeeAddressUrls = this.customerlist.payeeAddressUrl.split(',')
|
|
this.$forceUpdate();
|
|
this.$forceUpdate();
|
|
},
|
|
},
|
|
- customerclose(e){
|
|
|
|
|
|
+ customerclose(e) {
|
|
console.log(e)
|
|
console.log(e)
|
|
- // row.textcss = false
|
|
|
|
- this. customerInfo = false
|
|
|
|
|
|
+ // row.textcss = false
|
|
|
|
+ this.customerInfo = false
|
|
|
|
|
|
},
|
|
},
|
|
//合计
|
|
//合计
|
|
@@ -514,68 +514,82 @@ import {
|
|
typePrintCannelClick() {
|
|
typePrintCannelClick() {
|
|
this.isShowPrintType = false
|
|
this.isShowPrintType = false
|
|
},
|
|
},
|
|
- typePrintClick(type) {debugger
|
|
|
|
|
|
+ typePrintClick(type) {
|
|
// type 1批量打印 0单个打印
|
|
// type 1批量打印 0单个打印
|
|
// this.isShowPrint = true
|
|
// this.isShowPrint = true
|
|
- if(type==1){
|
|
|
|
- for(let i =0;i<this.modification.length;i++){
|
|
|
|
- getCustomerLook({
|
|
|
|
- id: this.modification[i].identityAuthenticationInfo.id,
|
|
|
|
- authenticationStatusKey: 7
|
|
|
|
- })
|
|
|
|
- .toPromise()
|
|
|
|
- .then(response => {
|
|
|
|
- this.selectCustomerList.push(response)
|
|
|
|
- getpaymentexamine({
|
|
|
|
- id: this.modification[i].id
|
|
|
|
|
|
+ if (type == 1) {
|
|
|
|
+ let index1 = 0;
|
|
|
|
+ let index2 = 0;
|
|
|
|
+ for (let i = 0; i < this.modification.length; i++) {
|
|
|
|
+ getCustomerLook({
|
|
|
|
+ id: this.modification[i].identityAuthenticationInfo.id,
|
|
|
|
+ authenticationStatusKey: 7
|
|
})
|
|
})
|
|
.toPromise()
|
|
.toPromise()
|
|
.then(response => {
|
|
.then(response => {
|
|
- let date = new Date()
|
|
|
|
- response.currentTime =
|
|
|
|
- date.getFullYear() +
|
|
|
|
- '年' +
|
|
|
|
- Number(date.getMonth() + 1) +
|
|
|
|
- '月' +
|
|
|
|
- date.getDate() +
|
|
|
|
- '日'
|
|
|
|
- this.selectPrintList.push(response)
|
|
|
|
-
|
|
|
|
|
|
+ this.selectCustomerList.push(response)
|
|
|
|
+ index2++;
|
|
|
|
+ if (index1 == this.modification.length && index2 == this.modification.length) {
|
|
|
|
+ this.printData.compName = ""
|
|
|
|
+ // this.isShowPrint = true
|
|
|
|
+ this.printBig();
|
|
|
|
+ }
|
|
|
|
+ getpaymentexamine({
|
|
|
|
+ id: this.modification[i].id
|
|
|
|
+ })
|
|
|
|
+ .toPromise()
|
|
|
|
+ .then(response => {
|
|
|
|
+ index1++;
|
|
|
|
+ let date = new Date()
|
|
|
|
+ response.currentTime =
|
|
|
|
+ date.getFullYear() +
|
|
|
|
+ '年' +
|
|
|
|
+ Number(date.getMonth() + 1) +
|
|
|
|
+ '月' +
|
|
|
|
+ date.getDate() +
|
|
|
|
+ '日'
|
|
|
|
+ this.selectPrintList.push(response)
|
|
|
|
+ if (index1 == this.modification.length && index2 == this.modification.length) {
|
|
|
|
+ this.printData.compName = ""
|
|
|
|
+ // this.isShowPrint = true
|
|
|
|
+ this.printBig();
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ })
|
|
})
|
|
})
|
|
- })
|
|
|
|
}
|
|
}
|
|
- // console.log('批量打印客户list',this.selectCustomerList)
|
|
|
|
- // console.log('批量打印凭证list',this.selectPrintList)
|
|
|
|
- }else{
|
|
|
|
- getCustomerLook({
|
|
|
|
- id: this.rowData.identityAuthenticationInfo.id,
|
|
|
|
- authenticationStatusKey: 7
|
|
|
|
- })
|
|
|
|
- .toPromise()
|
|
|
|
- .then(response => {
|
|
|
|
- this.customerList = response
|
|
|
|
- getpaymentexamine({
|
|
|
|
- id: this.rowData.id
|
|
|
|
- })
|
|
|
|
- .toPromise()
|
|
|
|
- .then(response => {
|
|
|
|
- this.printData = response
|
|
|
|
- this.isShowPrint = true
|
|
|
|
- // if(this.printData.solidGrainPrice){
|
|
|
|
- // this.printData.solidGrainPrice = (this.printData.tidalGrainPrice * this.printData.netWeight)/this.printData.pureWeight
|
|
|
|
- // }
|
|
|
|
- let date = new Date()
|
|
|
|
- this.printData.currentTime =
|
|
|
|
- date.getFullYear() +
|
|
|
|
- '年' +
|
|
|
|
- Number(date.getMonth() + 1) +
|
|
|
|
- '月' +
|
|
|
|
- date.getDate() +
|
|
|
|
- '日'
|
|
|
|
- })
|
|
|
|
- })
|
|
|
|
|
|
+ // console.log('批量打印客户list',this.selectCustomerList)
|
|
|
|
+ // console.log('批量打印凭证list',this.selectPrintList)
|
|
|
|
+ } else {
|
|
|
|
+ getCustomerLook({
|
|
|
|
+ id: this.rowData.identityAuthenticationInfo.id,
|
|
|
|
+ authenticationStatusKey: 7
|
|
|
|
+ })
|
|
|
|
+ .toPromise()
|
|
|
|
+ .then(response => {
|
|
|
|
+ this.customerList = response
|
|
|
|
+ getpaymentexamine({
|
|
|
|
+ id: this.rowData.id
|
|
|
|
+ })
|
|
|
|
+ .toPromise()
|
|
|
|
+ .then(response => {
|
|
|
|
+ this.printData = response
|
|
|
|
+ this.isShowPrint = true
|
|
|
|
+ // if(this.printData.solidGrainPrice){
|
|
|
|
+ // this.printData.solidGrainPrice = (this.printData.tidalGrainPrice * this.printData.netWeight)/this.printData.pureWeight
|
|
|
|
+ // }
|
|
|
|
+ let date = new Date()
|
|
|
|
+ this.printData.currentTime =
|
|
|
|
+ date.getFullYear() +
|
|
|
|
+ '年' +
|
|
|
|
+ Number(date.getMonth() + 1) +
|
|
|
|
+ '月' +
|
|
|
|
+ date.getDate() +
|
|
|
|
+ '日'
|
|
|
|
+ })
|
|
|
|
+ })
|
|
}
|
|
}
|
|
-
|
|
|
|
|
|
+
|
|
},
|
|
},
|
|
handleRowClick(row) {
|
|
handleRowClick(row) {
|
|
if (row.status != '已驳回') {
|
|
if (row.status != '已驳回') {
|
|
@@ -652,15 +666,24 @@ import {
|
|
)
|
|
)
|
|
},
|
|
},
|
|
printBig() {
|
|
printBig() {
|
|
- window.open(
|
|
|
|
- '../../../../../static/payprint.html?type=2&dataList=' +
|
|
|
|
- JSON.stringify(this.printData) +
|
|
|
|
- '&customerList=' +
|
|
|
|
- JSON.stringify(this.customerList) +
|
|
|
|
- '&printTypeList=' +
|
|
|
|
- this.ruleForm.type,
|
|
|
|
- '结算凭证'
|
|
|
|
- )
|
|
|
|
|
|
+ console.log(this.printType)
|
|
|
|
+ let _list1 = []
|
|
|
|
+ let _list2 = []
|
|
|
|
+ if (this.printType == 1) {
|
|
|
|
+ sessionStorage.setItem('cwprint', true)
|
|
|
|
+ // 财务批量打印数据
|
|
|
|
+ sessionStorage.setItem('selectPrint_selectPrintList', JSON.stringify(this.selectPrintList))
|
|
|
|
+ sessionStorage.setItem('selectPrint_selectCustomerList', JSON.stringify(this.selectCustomerList))
|
|
|
|
+ } else if (this.printType == 0) {
|
|
|
|
+ sessionStorage.setItem('cwprint', true)
|
|
|
|
+ _list1 = JSON.stringify(this.printData)
|
|
|
|
+ _list2 = JSON.stringify(this.customerList)
|
|
|
|
+ } else {
|
|
|
|
+ _list1 = JSON.stringify(this.printData)
|
|
|
|
+ _list2 = JSON.stringify(this.customerList)
|
|
|
|
+ }
|
|
|
|
+ window.open('../../../../../static/payprint.html?type=2&dataList=' + _list1 + '&customerList=' + _list2 +
|
|
|
|
+ '&printTypeList=' + this.ruleForm.type, '结算凭证')
|
|
},
|
|
},
|
|
getList() {
|
|
getList() {
|
|
this.payments = {
|
|
this.payments = {
|
|
@@ -671,33 +694,32 @@ import {
|
|
if (this.searchType != -1) {
|
|
if (this.searchType != -1) {
|
|
searchParam = this.searchType
|
|
searchParam = this.searchType
|
|
}
|
|
}
|
|
-
|
|
|
|
- getpayment({
|
|
|
|
- currentPage: this.currentPage,
|
|
|
|
- pageSize: this.pageSize,
|
|
|
|
- searchKeyWord: this.searchKeyWord,
|
|
|
|
- searchType: searchParam,
|
|
|
|
- warehouseName: this.warehouseName,
|
|
|
|
- managementType: 1,
|
|
|
|
- compId: sessionStorage.getItem('ws-pf_compId')
|
|
|
|
- })
|
|
|
|
- .toPromise()
|
|
|
|
- .then(response => {
|
|
|
|
- this.paymentList = response.records
|
|
|
|
- for(let i = 0 ; i < this.paymentList.length ; i++){
|
|
|
|
- this.paymentList.textcss = false
|
|
|
|
- }
|
|
|
|
- this.deptBudgetTotal = response.total
|
|
|
|
- })
|
|
|
|
- // getJurisdiction({
|
|
|
|
- // managementType: 1,
|
|
|
|
- // warehouseName: this.warehouseName,
|
|
|
|
- // compId: sessionStorage.getItem('ws-pf_compId')
|
|
|
|
- // })
|
|
|
|
- // .toPromise()
|
|
|
|
- // .then(response => {
|
|
|
|
- // this.isShowAdopt = response
|
|
|
|
- // })
|
|
|
|
|
|
+ getpayment({
|
|
|
|
+ currentPage: this.currentPage,
|
|
|
|
+ pageSize: this.pageSize,
|
|
|
|
+ searchKeyWord: this.searchKeyWord,
|
|
|
|
+ searchType: searchParam,
|
|
|
|
+ warehouseName: this.warehouseName,
|
|
|
|
+ managementType: 1,
|
|
|
|
+ compId: sessionStorage.getItem('ws-pf_compId')
|
|
|
|
+ })
|
|
|
|
+ .toPromise()
|
|
|
|
+ .then(response => {
|
|
|
|
+ this.paymentList = response.records
|
|
|
|
+ for (let i = 0; i < this.paymentList.length; i++) {
|
|
|
|
+ this.paymentList.textcss = false
|
|
|
|
+ }
|
|
|
|
+ this.deptBudgetTotal = response.total
|
|
|
|
+ })
|
|
|
|
+ // getJurisdiction({
|
|
|
|
+ // managementType: 1,
|
|
|
|
+ // warehouseName: this.warehouseName,
|
|
|
|
+ // compId: sessionStorage.getItem('ws-pf_compId')
|
|
|
|
+ // })
|
|
|
|
+ // .toPromise()
|
|
|
|
+ // .then(response => {
|
|
|
|
+ // this.isShowAdopt = response
|
|
|
|
+ // })
|
|
|
|
|
|
|
|
|
|
},
|
|
},
|