md
This commit is contained in:
parent
3848d63f9d
commit
30c6d59efd
@ -96,6 +96,8 @@
|
||||
@sort-change="handleSortChange"
|
||||
|
||||
@row-dblclick="handleSendDbClick"
|
||||
|
||||
:row-style="tableRowClassName"
|
||||
>
|
||||
|
||||
<div slot="toolbar">
|
||||
@ -188,6 +190,9 @@
|
||||
<!-- <el-table-column :label="$t('客户名称')" align="center" prop="customerName" min-width="100" /> -->
|
||||
<el-table-column :label="$t('账单编号')" align="center" prop="settleBillNo" min-width="170" :show-overflow-tooltip="true"/>
|
||||
<el-table-column :label="$t('申请金额')" align="center" prop="applyMoney" min-width="100" />
|
||||
<el-table-column :label="$t('加开税点')" align="center" prop="addTaxRate" min-width="100" />
|
||||
<el-table-column :label="$t('加开金额')" align="center" prop="addOpenMoney" min-width="100" />
|
||||
|
||||
<el-table-column :label="$t('开票类型')" align="center" prop="invoiceType" min-width="100" >
|
||||
<template slot-scope="scope">
|
||||
<el-tag v-if="scope.row.invoiceType=='1'" type="info">增值税电子普通发票</el-tag>
|
||||
@ -353,6 +358,13 @@ export default {
|
||||
this.getList();
|
||||
},
|
||||
methods: {
|
||||
tableRowClassName({row, rowIndex}) {
|
||||
if (row.addTaxRate!=0 || row.addOpenMoney!=0) {
|
||||
return {"background-color": "#03a9f4 !important"};
|
||||
}
|
||||
|
||||
return '';
|
||||
},
|
||||
handleSendDbClick(row){
|
||||
this.$emit("onSelect",row);
|
||||
},
|
||||
|
||||
@ -118,6 +118,8 @@
|
||||
@sort-change="handleSortChange"
|
||||
|
||||
@row-dblclick="handleSendDbClick"
|
||||
|
||||
:row-style="tableRowClassName"
|
||||
>
|
||||
|
||||
<div slot="toolbar">
|
||||
@ -184,6 +186,9 @@
|
||||
<!-- <el-table-column :label="$t('客户名称')" align="center" prop="customerName" min-width="100" /> -->
|
||||
<el-table-column :label="$t('账单编号')" align="center" prop="settleBillNo" min-width="170" :show-overflow-tooltip="true"/>
|
||||
<el-table-column :label="$t('申请金额')" align="center" prop="applyMoney" min-width="100" />
|
||||
<el-table-column :label="$t('加开税点')" align="center" prop="addTaxRate" min-width="100" />
|
||||
<el-table-column :label="$t('加开金额')" align="center" prop="addOpenMoney" min-width="100" />
|
||||
|
||||
<el-table-column :label="$t('开票类型')" align="center" prop="invoiceType" min-width="100" >
|
||||
<template slot-scope="scope">
|
||||
<el-tag v-if="scope.row.invoiceType=='1'" type="info">增值税电子普通发票</el-tag>
|
||||
@ -346,6 +351,13 @@ export default {
|
||||
handleSendDbClick(row){
|
||||
this.$emit("onSelect",row);
|
||||
},
|
||||
tableRowClassName({row, rowIndex}) {
|
||||
if (row.addTaxRate!=0 || row.addOpenMoney!=0) {
|
||||
return {"background-color": "#03a9f4 !important"};
|
||||
}
|
||||
|
||||
return '';
|
||||
},
|
||||
/** 查询开票记录表列表 */
|
||||
getList() {
|
||||
// 按运单查询时的处理
|
||||
|
||||
@ -5,6 +5,8 @@
|
||||
size="small"
|
||||
:data="emisSettleInvoiceRelList"
|
||||
|
||||
ref="refTable"
|
||||
|
||||
storageName="applyInvoiceEmisSettleInvoiceRelList_1107"
|
||||
|
||||
:showSearch.sync="showSearch"
|
||||
@ -13,8 +15,24 @@
|
||||
@queryTable="getList"
|
||||
@selection-change="handleSelectionChange"
|
||||
@sort-change="handleSortChange"
|
||||
|
||||
|
||||
>
|
||||
|
||||
<div slot="toolbar">
|
||||
<el-row :gutter="10" class="mb8">
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="warning"
|
||||
plain
|
||||
icon="el-icon-download"
|
||||
size="mini"
|
||||
@click="handleExport"
|
||||
>导出</el-button>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
|
||||
<!-- max-height="500px" -->
|
||||
<el-table-column :label="$t('序号')" align="center" width="60">
|
||||
<template slot-scope="scope">
|
||||
@ -115,6 +133,8 @@ export default {
|
||||
// 开票子账单关联表表格数据
|
||||
emisSettleInvoiceRelList: [],
|
||||
|
||||
selectBillList:[],
|
||||
|
||||
currentId:null,
|
||||
openForm: false,
|
||||
titleForm: "",
|
||||
@ -173,6 +193,7 @@ export default {
|
||||
});
|
||||
},
|
||||
|
||||
|
||||
/** 搜索按钮操作 */
|
||||
handleQuery() {
|
||||
this.queryParams.pageNum = 1;
|
||||
@ -186,6 +207,7 @@ export default {
|
||||
// 多选框选中数据
|
||||
handleSelectionChange(selection) {
|
||||
this.ids = selection.map(item => item.id)
|
||||
this.selectBillList=selection;
|
||||
this.single = selection.length!==1
|
||||
this.multiple = !selection.length
|
||||
},
|
||||
@ -233,49 +255,202 @@ export default {
|
||||
this.$modal.msgSuccess("删除成功");
|
||||
}).catch(() => {});
|
||||
},
|
||||
/** 导出按钮操作 */
|
||||
handleExport() {
|
||||
// this.download('emis/emisSettleInvoiceRel/export', {
|
||||
// ...this.queryParams
|
||||
// }, `emisSettleInvoiceRel_${new Date().getTime()}.xlsx`)
|
||||
const loadingInstance = this.$loading({
|
||||
text: '正在导出...'
|
||||
})
|
||||
var qParam = {...this.queryParams};
|
||||
qParam.pageNum=1;
|
||||
qParam.pageSize=5000;
|
||||
|
||||
listEmisSettleInvoiceRel(this.addDateRange(qParam, this.dateTimeRange)).then(response => {
|
||||
this.downloadLoading = false
|
||||
if (response.code === 200) {
|
||||
const curList = response.rows
|
||||
import('@/vendor/Export2Excel').then(excel => {
|
||||
const tHeader = ['id','申请序号','支付序号','分账单号','申请开票金额','删除标志(0代表存在','创建者','创建时间','更新者','更新时间','创建网点','更新网点',];
|
||||
const filterVal = ['id','applySeqNo','payId','billNo','money','delFlag','createBy','createTime','updateBy','updateTime','createSite','updateSite',];
|
||||
const data = this.formatJson(filterVal, curList, response.rows)
|
||||
excel.export_json_to_excel({
|
||||
header: tHeader,
|
||||
data,
|
||||
filename: '开票子账单关联表',
|
||||
autoWidth: true
|
||||
})
|
||||
loadingInstance.close()
|
||||
})
|
||||
}
|
||||
});
|
||||
/** 导出按钮操作 */
|
||||
handleExport() {
|
||||
const loadingInstance = this.$loading({
|
||||
text: '正在导出...'
|
||||
})
|
||||
|
||||
if(this.selectBillList&&this.selectBillList.length>0){
|
||||
this.exportData(this.selectBillList,loadingInstance);
|
||||
}
|
||||
else{
|
||||
let qExportParam=this.initQueryParams();
|
||||
qExportParam.pageNum=1;
|
||||
qExportParam.pageSize=5000;
|
||||
|
||||
listEmisSettleSubBill(qExportParam).then(response => {
|
||||
if (response.code === 200) {
|
||||
this.exportData(response.rows,loadingInstance);
|
||||
}
|
||||
});
|
||||
}
|
||||
},
|
||||
exportData(selData,loadingInstance){
|
||||
const curList =selData
|
||||
import('@/vendor/Export2Excel').then(excel => {
|
||||
const exportParam=this.$refs.refTable.getExportParam();
|
||||
const tHeader = exportParam.header;
|
||||
const filterVal = exportParam.filter;
|
||||
const data = this.formatJson(filterVal, curList, selData)
|
||||
excel.export_json_to_excel({
|
||||
header: tHeader,
|
||||
data,
|
||||
filename: '账单导出',
|
||||
autoWidth: true
|
||||
})
|
||||
loadingInstance.close()
|
||||
})
|
||||
},
|
||||
formatJson(filterVal, jsonData, resData) {
|
||||
let index = 0
|
||||
return jsonData.map(v => filterVal.map(j => {
|
||||
|
||||
console.log("===>1111===>",v);
|
||||
|
||||
if (j === 'index') {
|
||||
return ++index
|
||||
}
|
||||
if (j === 'status') {
|
||||
var statusStr='xxx'
|
||||
if(v[j] == 10){
|
||||
statusStr='xxx'
|
||||
if (j === 'kjlx') {
|
||||
return v['waybillDetail']['sendSiteName']+'--'+v['waybillDetail']['dispatchUnderlingSiteName'];
|
||||
}
|
||||
if (j === 'fjr') {
|
||||
return v['sendName']+'--'+v['receiveName'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.sendSiteName') {
|
||||
return v['waybillDetail']['sendSiteName'];
|
||||
}
|
||||
|
||||
|
||||
if (j === 'waybillDetail.sendDate') {
|
||||
return v['waybillDetail']['sendDate'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.sendCompany') {
|
||||
return v['waybillDetail']['sendCompany'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.transLineTypeName') {
|
||||
return v['waybillDetail']['transLineTypeName'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.productTypeName') {
|
||||
return v['waybillDetail']['productTypeName'];
|
||||
}
|
||||
|
||||
|
||||
if (j === 'waybillDetail.sendName') {
|
||||
return v['waybillDetail']['sendName'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.parcelQty') {
|
||||
return v['waybillDetail']['parcelQty'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.billWeight') {
|
||||
return v['waybillDetail']['billWeight'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.volumeWeight') {
|
||||
return v['waybillDetail']['volumeWeight'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.totalVolume') {
|
||||
return v['waybillDetail']['totalVolume'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.settlementWeight') {
|
||||
return v['waybillDetail']['settlementWeight'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.freight') {
|
||||
return v['waybillDetail']['freight'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.realFee') {
|
||||
return v['waybillDetail']['realFee'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.remark') {
|
||||
return v['waybillDetail']['remark'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.feeRemark') {
|
||||
return v['waybillDetail']['feeRemark'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.salesmen') {
|
||||
return v['waybillDetail']['salesmen'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.payee') {
|
||||
return v['waybillDetail']['payee'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.payee') {
|
||||
return v['waybillDetail']['payee'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.problemTypeName') {
|
||||
return v['waybillDetail']['problemTypeName'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.problemCause') {
|
||||
return v['waybillDetail']['problemCause'];
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.sendMobile') {
|
||||
return "";
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.calcFeeType') {
|
||||
return this.selectDictLabel(this.dict.type.emis_calc_fee_type,v['waybillDetail']['calcFeeType']);
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.paymentStatus') {
|
||||
return this.selectDictLabel(this.dict.type.emis_payment_status,v['waybillDetail']['paymentStatus']);
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.pickupMethod') {
|
||||
return this.selectDictLabel(this.dict.type.emis_qujian_fangshi,v['waybillDetail']['pickupMethod']);
|
||||
}
|
||||
if (j === 'waybillDetail.customsEclaration') {
|
||||
return this.selectDictLabel(this.dict.type.emis_declare_mode,v['waybillDetail']['customsEclaration']);
|
||||
}
|
||||
if (j === 'waybillDetail.customsClear') {
|
||||
return this.selectDictLabel(this.dict.type.emis_customs_clear,v['waybillDetail']['customsClear']);
|
||||
}
|
||||
if (j === 'waybillDetail.packType') {
|
||||
return this.selectDictLabels(this.dict.type.emis_tab_packing_type,v['waybillDetail']['packType']);
|
||||
}
|
||||
|
||||
if (j === 'waybillDetail.dispatchMethod') {
|
||||
if(v['waybillDetail']['dispatchMethod'] == 1){
|
||||
return '派送';
|
||||
}else{
|
||||
return '自提';
|
||||
}
|
||||
return statusStr;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if (j === 'waybillDetail.blMessage') {
|
||||
if(v['waybillDetail']['blMessage'] == 1){
|
||||
return '发送';
|
||||
}else{
|
||||
return '不发送';
|
||||
}
|
||||
}
|
||||
if (j === 'waybillDetail.blAcceptMessage') {
|
||||
if(v['waybillDetail']['blAcceptMessage'] == 1){
|
||||
return '发送';
|
||||
}else{
|
||||
return '不发送';
|
||||
}
|
||||
}
|
||||
if (j === 'waybillDetail.blSign') {
|
||||
if(v['waybillDetail']['blSign'] == 1){
|
||||
return '已签收';
|
||||
}else{
|
||||
return '未签收';
|
||||
}
|
||||
}
|
||||
if (j === 'waybillDetail.paymentType') {
|
||||
return this.selectDictLabel(this.dict.type.emis_payment_type,v['waybillDetail']['paymentType']);
|
||||
}
|
||||
return v[j]
|
||||
}))
|
||||
|
||||
@ -346,7 +346,7 @@
|
||||
<el-table-column :label="$t('体积')" align="center" prop="waybillDetail.totalVolume" min-width="80" />
|
||||
<el-table-column :label="$t('体积重量')" align="center" prop="waybillDetail.volumeWeight" min-width="80" />
|
||||
<el-table-column :label="$t('结算重量')" align="center" prop="waybillDetail.settlementWeight" min-width="120" :sortable="true" />
|
||||
<el-table-column :label="$t('运费')" align="center" prop="waybillDetail.freight" min-width="80" >
|
||||
<el-table-column :label="$t('运费')" align="center" prop="waybillDetail.billFee" min-width="80" >
|
||||
<template slot-scope="scope">
|
||||
<span style="color: red;font-weight: 500" v-if="scope.row.waybillDetail.realFee!=scope.row.waybillDetail.freight">{{scope.row.waybillDetail.freight}}</span>
|
||||
<span v-else>{{scope.row.waybillDetail.freight}}</span>
|
||||
|
||||
@ -206,6 +206,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { listEmisSettleSubBill} from "@/api/emis/emisSettleSubBill";
|
||||
import { addEmisWaybillProblemInfo,listEmisWaybillProblemInfo } from "@/api/emis/emisWaybillProblemInfo";
|
||||
import { doScan } from "@/api/emis/emisTmsScanRecord";
|
||||
// import { listEmisWaybill } from "@/api/emis/emisWaybill";
|
||||
@ -490,7 +491,7 @@ export default {
|
||||
// // this.form.billCode=null;
|
||||
// })
|
||||
},
|
||||
handleRegister(){
|
||||
async handleRegister(){
|
||||
if(this.form.notifySiteCode==null || this.form.notifySiteCode==''){
|
||||
this.$modal.msgError("请选择通知网点");
|
||||
return;
|
||||
@ -503,6 +504,27 @@ export default {
|
||||
this.$modal.msgError("请填写问题原因");
|
||||
return;
|
||||
}
|
||||
|
||||
// 如果已定制账单,则需要先从账单移除
|
||||
if(this.form.problemType==151 || this.form.problemType==173 || this.form.problemType==170){
|
||||
let qBillParam ={
|
||||
pageNum:1,
|
||||
pageSize:1,
|
||||
billCode:this.form.billCode
|
||||
}
|
||||
let res=await listEmisSettleSubBill(qBillParam);
|
||||
if(res.code==200){
|
||||
let dataArr=res.rows;
|
||||
if(dataArr.length>0){
|
||||
let itemSubBill=dataArr[0];
|
||||
if(itemSubBill.blMerge==1){
|
||||
this.$modal.msgError("已生成客户账单,请联系财务移除该单后再登记!");
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
this.tempRecord.notifySiteCode = this.form.notifySiteCode;
|
||||
this.tempRecord.notifySiteName = this.form.notifySiteName;
|
||||
this.tempRecord.problemTypeName=this.form.problemType;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user