|
@@ -427,7 +427,6 @@ export default {
|
|
|
},
|
|
|
methods: {
|
|
|
closeDialog(){
|
|
|
- debugger
|
|
|
html2canvas(this.$refs.saveImg.$el).then((canvas) => {
|
|
|
let dataURL = canvas.toDataURL('image/png')
|
|
|
this.imgUrl = dataURL
|
|
@@ -579,106 +578,106 @@ export default {
|
|
|
return chineseStr;
|
|
|
},
|
|
|
print() {
|
|
|
- // if (!this.paymentList.buckleWeightRatio) {
|
|
|
- // this.$message({
|
|
|
- // message: '扣重比不能为空',
|
|
|
- // type: 'warning',
|
|
|
- // })
|
|
|
- // return
|
|
|
- // }
|
|
|
- // if (this.paymentList.buckleWeightRatio < 0 || this.paymentList.buckleWeightRatio > 2) {
|
|
|
- // this.$message({
|
|
|
- // message: '扣重比输入错误',
|
|
|
- // type: 'warning',
|
|
|
- // })
|
|
|
- // return
|
|
|
- // }
|
|
|
+ if (!this.paymentList.buckleWeightRatio) {
|
|
|
+ this.$message({
|
|
|
+ message: '扣重比不能为空',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (this.paymentList.buckleWeightRatio < 0 || this.paymentList.buckleWeightRatio > 2) {
|
|
|
+ this.$message({
|
|
|
+ message: '扣重比输入错误',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
|
|
|
- // if (this.paymentList.weighingSubsidy < 0 || this.paymentList.weighingSubsidy > 100000) {
|
|
|
- // this.$message({
|
|
|
- // message: '称重补助范围应在0-100000内',
|
|
|
- // type: 'warning',
|
|
|
- // })
|
|
|
- // return
|
|
|
- // }
|
|
|
+ if (this.paymentList.weighingSubsidy < 0 || this.paymentList.weighingSubsidy > 100000) {
|
|
|
+ this.$message({
|
|
|
+ message: '称重补助范围应在0-100000内',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
|
|
|
- // if (this.paymentList.weighingDeduction < 0 || this.paymentList.weighingDeduction > 100000) {
|
|
|
- // this.$message({
|
|
|
- // message: '称重扣款范围应在0-100000内',
|
|
|
- // type: 'warning',
|
|
|
- // })
|
|
|
- // return
|
|
|
- // }
|
|
|
+ if (this.paymentList.weighingDeduction < 0 || this.paymentList.weighingDeduction > 100000) {
|
|
|
+ this.$message({
|
|
|
+ message: '称重扣款范围应在0-100000内',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
|
|
|
- // if (this.paymentList.freightSubsidy < 0 || this.paymentList.freightSubsidy > 100000) {
|
|
|
- // this.$message({
|
|
|
- // message: '运费补助范围应在0-100000内',
|
|
|
- // type: 'warning',
|
|
|
- // })
|
|
|
- // return
|
|
|
- // }
|
|
|
+ if (this.paymentList.freightSubsidy < 0 || this.paymentList.freightSubsidy > 100000) {
|
|
|
+ this.$message({
|
|
|
+ message: '运费补助范围应在0-100000内',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
|
|
|
- // if (this.paymentList.freightDeduction < 0 || this.paymentList.freightDeduction > 100000) {
|
|
|
- // this.$message({
|
|
|
- // message: '运费扣款范围应在0-100000内',
|
|
|
- // type: 'warning',
|
|
|
- // })
|
|
|
- // return
|
|
|
- // }
|
|
|
+ if (this.paymentList.freightDeduction < 0 || this.paymentList.freightDeduction > 100000) {
|
|
|
+ this.$message({
|
|
|
+ message: '运费扣款范围应在0-100000内',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
|
|
|
- // if (this.paymentList.unloadSubsidy < 0 || this.paymentList.unloadSubsidy > 100000) {
|
|
|
- // this.$message({
|
|
|
- // message: '卸车补助范围应在0-100000内',
|
|
|
- // type: 'warning',
|
|
|
- // })
|
|
|
- // return
|
|
|
- // }
|
|
|
+ if (this.paymentList.unloadSubsidy < 0 || this.paymentList.unloadSubsidy > 100000) {
|
|
|
+ this.$message({
|
|
|
+ message: '卸车补助范围应在0-100000内',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
|
|
|
- // if (this.paymentList.unloadDeduction < 0 || this.paymentList.unloadDeduction > 100000) {
|
|
|
- // this.$message({
|
|
|
- // message: '卸车扣款范围应在0-100000内',
|
|
|
- // type: 'warning',
|
|
|
- // })
|
|
|
- // return
|
|
|
- // }
|
|
|
+ if (this.paymentList.unloadDeduction < 0 || this.paymentList.unloadDeduction > 100000) {
|
|
|
+ this.$message({
|
|
|
+ message: '卸车扣款范围应在0-100000内',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
|
|
|
- // if (this.paymentList.otherSubsidy < 0 || this.paymentList.unloadDeduction > 100000) {
|
|
|
- // this.$message({
|
|
|
- // message: '其他补助范围应在0-100000内',
|
|
|
- // type: 'warning',
|
|
|
- // })
|
|
|
- // return
|
|
|
- // }
|
|
|
+ if (this.paymentList.otherSubsidy < 0 || this.paymentList.unloadDeduction > 100000) {
|
|
|
+ this.$message({
|
|
|
+ message: '其他补助范围应在0-100000内',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
|
|
|
- // if (this.paymentList.qualityDeduction < 0 || this.paymentList.qualityDeduction > 100000) {
|
|
|
- // this.$message({
|
|
|
- // message: '质量扣款范围应在0-100000内',
|
|
|
- // type: 'warning',
|
|
|
- // })
|
|
|
- // return
|
|
|
- // }
|
|
|
+ if (this.paymentList.qualityDeduction < 0 || this.paymentList.qualityDeduction > 100000) {
|
|
|
+ this.$message({
|
|
|
+ message: '质量扣款范围应在0-100000内',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
|
|
|
- // if (this.paymentList.otherDeduction < 0 || this.paymentList.otherDeduction > 100000) {
|
|
|
- // this.$message({
|
|
|
- // message: '其他扣款范围应在0-100000内',
|
|
|
- // type: 'warning',
|
|
|
- // })
|
|
|
- // return
|
|
|
- // }
|
|
|
- // if (this.paymentList.actualPayment < 0 || this.paymentList.otherDeduction > 100000) {
|
|
|
- // this.$message({
|
|
|
- // message: '实际付款范围应在0-100000内',
|
|
|
- // type: 'warning',
|
|
|
- // })
|
|
|
- // return
|
|
|
- // }
|
|
|
- // if (this.paymentList.remarks.length > 20) {
|
|
|
- // this.$message({
|
|
|
- // message: '记事字数应在0-20个字',
|
|
|
- // type: 'warning',
|
|
|
- // })
|
|
|
- // return
|
|
|
- // }
|
|
|
+ if (this.paymentList.otherDeduction < 0 || this.paymentList.otherDeduction > 100000) {
|
|
|
+ this.$message({
|
|
|
+ message: '其他扣款范围应在0-100000内',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (this.paymentList.actualPayment < 0 || this.paymentList.otherDeduction > 100000) {
|
|
|
+ this.$message({
|
|
|
+ message: '实际付款范围应在0-100000内',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (this.paymentList.remarks.length > 20) {
|
|
|
+ this.$message({
|
|
|
+ message: '记事字数应在0-20个字',
|
|
|
+ type: 'warning',
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
|
|
|
this.paymentList.id=this.$route.query.id
|
|
|
this.paymentList.settlementClerk = sessionStorage.getItem('ws-pf_staffName')
|