总费用:{{scope.row.billFee}}
-
-
+
+
+
+
+
+
+
+ {{ scope.row.customerName }}
+
+
+
+
+
+
+
+ {{scope.row.waybillDetail.productTypeName}}({{scope.row.waybillDetail.timeType}})
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 是
+ /
+
+
+
+
+
+
未确认
已确认
确认不出账
账单异常
-
-
-
-
+
+
+
+
-
+
未确认
已确认
@@ -233,226 +329,17 @@
账单异常
-
+
+
-
-
- 现金
- 月结
-
-
-
-
- {{ scope.row.customerName }}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- {{ scope.row.waybillDetail.sendName }}--{{ scope.row.waybillDetail.receiveName }}
-
-
-
-
- {{ scope.row.waybillDetail.sendSiteName }}--{{ scope.row.waybillDetail.dispatchUnderlingSiteName }}
-
-
-
-
- {{ parseTime(scope.row.waybillDetail.estimateDate, '{y}-{m}-{d}') }}
-
-
-
-
-
- {{scope.row.waybillDetail.takePieceEmployeeName}}
-
-
-
-
-
-
-
-
-
- {{scope.row.waybillDetail.operateEmployeeName}}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- {{scope.row.waybillDetail.customerName}}
-
-
-
-
-
-
-
-
- 是
- 否
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 发送
- 不发送
-
-
-
-
-
-
-
-
-
-
-
-
-
- 发送
- 不发送
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 派送
- 自提
-
-
-
-
-
-
-
-
-
-
- {{scope.row.waybillDetail.freight}}
- 0
-
-
-
-
-
-
-
-
-
- 已签收
- 未签收
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -551,8 +438,11 @@ export default {
// 结算子账单表格数据
emisSettleSubBillList: [],
+ actionType:null,
settleType:null,
+ storageName:null,
+
queryStatInfoMap:null,
currentId:null,
@@ -749,32 +639,68 @@ export default {
},
created() {
this.queryParams.blConfirm='0';
- this.settleType=this.$route.query.settleType;
+ this.actionType=this.$route.query.actionType;
+ this.initData();
this.getList();
},
methods: {
+
+ initData(){
+ if(this.actionType==1){
+ this.storageName="SubBillConfirmByMoneyList_main";
+ }
+ else if(this.actionType==2){
+ this.storageName="SubBillConfirmByMonthList_main";
+ }
+ else if(this.actionType==3){
+ this.storageName="SubBillConfirmBySitehList_main";
+ }
+ },
handleClick(tab, event) {
// console.log(tab, event);
- if (tab.name == 'all') {
+ if(this.actionType==1|| this.actionType==2){
this.queryParams.blSiteConfirm=null;
- }
- else if (tab.name == 'waitConfirm') {
- this.queryParams.blSiteConfirm='0';
- }
- else if (tab.name == 'hasConfirm') {
- this.queryParams.blSiteConfirm='1';
- }
- // else if (tab.name == 'confirmNotBill') {
- // this.queryParams.blSiteConfirm='2';
- // }
- else if (tab.name == 'billError') {
- this.queryParams.blSiteConfirm='3';
- }
-
-
-
+ this.queryParams.blConfirm=null;
+ if (tab.name == 'all') {
+ this.queryParams.blConfirm=null;
+ }
+ else if (tab.name == 'waitConfirm') {
+ this.queryParams.blConfirm='0';
+ }
+ else if (tab.name == 'hasConfirm') {
+ this.queryParams.blConfirm='1';
+ }
+ else if (tab.name == 'confirmNotBill') {
+ this.queryParams.blConfirm='2';
+ }
+ else if (tab.name == 'billError') {
+ this.queryParams.blConfirm='3';
+ }
+ else if (tab.name == 'siteBillError') {
+ this.queryParams.blSiteConfirm='3';
+ }
+ }
+ else if(this.actionType==2){
+ this.queryParams.blSiteConfirm=null;
+ this.queryParams.blConfirm=1;
+ if (tab.name == 'all') {
+ this.queryParams.blSiteConfirm=null;
+ }
+ else if (tab.name == 'waitConfirm') {
+ this.queryParams.blSiteConfirm='0';
+ }
+ else if (tab.name == 'hasConfirm') {
+ this.queryParams.blSiteConfirm='1';
+ }
+ // else if (tab.name == 'confirmNotBill') {
+ // this.queryParams.blSiteConfirm='2';
+ // }
+ else if (tab.name == 'billError') {
+ this.queryParams.blSiteConfirm='3';
+ }
+ }
this.getList();
},
@@ -797,8 +723,13 @@ export default {
/** 查询结算子账单列表 */
initQueryParams(){
- this.queryParams.settleType=this.settleType;
- this.queryParams.params.salesmen=this.$store.getters.empName
+ if(this.actionType==3){
+ this.queryParams.params.salesmen=this.$store.getters.empName
+ }else if(this.actionType==2){
+ this.queryParams.settleType=2;
+ }else if(this.actionType==1){
+ this.queryParams.settleType=1;
+ }
this.queryParams=this.addDateRange(this.queryParams, this.dateTimeRange,"sendDate")
},
getList() {
@@ -818,6 +749,98 @@ export default {
});
},
+ //指定列求和
+ getSummaries(param) {
+ const { columns, data } = param;
+ console.log("===>getSummaries==>",param)
+ const sums = [];
+ columns.forEach((column, index) => {
+ if (index === 0) {
+ sums[index] = '合计';
+ return;
+ }
+
+
+ if (
+ column.property === 'waybillDetail.billWeight'
+ ) {
+ const values = data.map(item => Number(item.waybillDetail.billWeight));
+ sums[index] = values.reduce((prev, curr) => {
+ const value = Number(curr);
+ if (!isNaN(value)) {
+ return prev + curr;
+ } else {
+ return prev;
+ }
+ }, 0);
+ sums[index] = sums[index].toFixed(2); //保留2位小数
+ }
+
+ else if (
+ column.property === 'waybillDetail.volumeWeight'
+
+ ) {
+ const values = data.map(item => Number(item.waybillDetail.volumeWeight));
+
+ sums[index] = values.reduce((prev, curr) => {
+ const value = Number(curr);
+ if (!isNaN(value)) {
+ return prev + curr;
+ } else {
+ return prev;
+ }
+ }, 0);
+ sums[index] = sums[index].toFixed(2); //保留2位小数
+ }
+ else if (
+ column.property === 'waybillDetail.freight'
+
+ ) {
+ const values = data.map(item => Number(item.waybillDetail.freight));
+
+ sums[index] = values.reduce((prev, curr) => {
+ const value = Number(curr);
+ if (!isNaN(value)) {
+ return prev + curr;
+ } else {
+ return prev;
+ }
+ }, 0);
+ sums[index] = sums[index].toFixed(2); //保留2位小数
+ }
+
+ else if (
+ column.property === 'waybillDetail.totalVolume'
+ ) {
+ const values = data.map(item => Number(item.waybillDetail.totalVolume));
+ sums[index] = values.reduce((prev, curr) => {
+ const value = Number(curr);
+ if (!isNaN(value)) {
+ return prev + curr;
+ } else {
+ return prev;
+ }
+ }, 0);
+ sums[index] = sums[index].toFixed(5); //保留2位小数
+ }
+ else if(
+ column.property === 'waybillDetail.parcelQty'
+ ){
+ const values = data.map(item => Number(item.waybillDetail.parcelQty));
+ sums[index] = values.reduce((prev, curr) => {
+ const value = Number(curr);
+ if (!isNaN(value)) {
+ return prev + curr;
+ } else {
+ return prev;
+ }
+ }, 0);
+ sums[index];
+ }
+ });
+ console.log(sums);
+ return sums
+ },
handleShowTraceInfo(row){
this.openTraceInfoTitle="运单详情【"+row.billCode+"】";
@@ -858,6 +881,55 @@ export default {
this.openForm = true;
this.titleForm = "修改";
},
+ handleConfirmByCenter(row) {
+ const ids = row.id || this.ids;
+ this.$modal.confirm('是否确认').then(function() {
+ return confirmBillByCenter(ids);
+ }).then(() => {
+ this.getList();
+ this.$modal.msgSuccess("操作成功");
+ }).catch(() => {});
+ },
+ handleCancelConfirmByCenter(row) {
+ const ids = row.id || this.ids;
+ this.$modal.confirm('是否取消确认').then(function() {
+ return cancelConfirmBillByCenter(ids);
+ }).then(() => {
+ this.getList();
+ this.$modal.msgSuccess("操作成功");
+ }).catch(() => {});
+ },
+ handleConfirmNoBillByCenter(row) {
+ const ids = row.id || this.ids;
+ this.$prompt('请输入不出账原因', "操作确认", {
+ confirmButtonText: "确定",
+ cancelButtonText: "取消",
+ closeOnClickModal: false,
+ inputPattern: /^.{1,30}$/,
+ inputErrorMessage: "原因长度必须介于 1 和 30 之间"
+ }).then(({ value }) => {
+ confirmNoBillByCenter(ids,value).then(response => {
+ this.$modal.msgSuccess("操作成功" );
+ this.getList();
+ });
+ }).catch(() => {});
+ },
+ handleSetBillErrorByCenter(row) {
+ const ids = row.id || this.ids;
+ this.$prompt('请输入账单异常原因', "操作确认", {
+ confirmButtonText: "确定",
+ cancelButtonText: "取消",
+ closeOnClickModal: false,
+ inputPattern: /^.{1,30}$/,
+ inputErrorMessage: "原因长度必须介于 1 和 30 之间"
+ }).then(({ value }) => {
+ setBillErrorByCenter(ids,value).then(response => {
+ this.$modal.msgSuccess("操作成功" );
+ this.getList();
+ });
+ }).catch(() => {});
+ },
+
handleConfirmBySite(row) {
const ids = row.id || this.ids;
this.$modal.confirm('是否确认').then(function() {
@@ -906,12 +978,7 @@ export default {
});
}).catch(() => {});
},
- handleView(row) {
- this.id=row.id;
- this.titleView="查看";
- this.openView=true;
- // this.router.push({ path: '/emis/emisSettleSubBill/viewDetail', query: { id: row.id }})
- },
+
handleFormChanged(){
this.openForm = false;
this.getList();
@@ -983,7 +1050,7 @@ export default {
.feeItem{
- border: 1px solid #d4d4d4;
+ border: 1px solid #dfe6ec;
ul{
list-style: none;
@@ -992,7 +1059,7 @@ export default {
width: 590px;
height: 32px;
line-height: 32px;
- border: 1px solid #ffffff;
+ border: 1px solid #dfe6ec;
border-top: 0px;
font-size: 12px;
@@ -1001,7 +1068,7 @@ export default {
display:block; width:33%; float:left;text-indent:2em
}
.th{
- background:#F1FADE; font-weight:bold; border-top:1px
+ background:#FFF; font-weight:bold; border-top:1px
}
}