|
@@ -832,6 +832,7 @@
|
|
|
>反关闭运单</el-button
|
|
|
>
|
|
|
</div>
|
|
|
+ <el-button round @click="resetPrintNumber">重置打印次数</el-button>
|
|
|
</div>
|
|
|
<div class="steelMapClass3">
|
|
|
<div class="steelMapClass32">
|
|
@@ -2094,6 +2095,15 @@ export default {
|
|
|
},
|
|
|
computed: {},
|
|
|
methods: {
|
|
|
+ resetPrintNumber(){
|
|
|
+ this.axios.post('/api/v1/bp/resetPrintNumber',this.steelMap).then((res)=>{
|
|
|
+ if(res.data.status=='succeed'){
|
|
|
+ this.$message.success("重置成功!");
|
|
|
+ }else{
|
|
|
+ this.$message.error("重置失败!");
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
showBatchCapacity() {
|
|
|
this.capacityNo = null
|
|
|
this.capacityId = null
|
|
@@ -2137,8 +2147,7 @@ export default {
|
|
|
return
|
|
|
}
|
|
|
console.log('this.batchCapacityList', this.batchCapacityList)
|
|
|
- // this.batchCapacityList.forEach(row => {})
|
|
|
- for (let i = 0; i < this.batchCapacityList.length; i++) {
|
|
|
+ this.batchCapacityList.forEach(row => {
|
|
|
row.capacityId = this.capacityId
|
|
|
row.capacityNumber = this.capacityNo
|
|
|
//是否校验GPS
|
|
@@ -2148,31 +2157,22 @@ export default {
|
|
|
this.$message.error('请先授权承运商!')
|
|
|
return
|
|
|
}
|
|
|
- if (row.capacityIds != 0) {
|
|
|
- await this.axios
|
|
|
- .post('/api/v1/ams/updateCapacityNumberInFactory', row)
|
|
|
- .then(res => {
|
|
|
- if (res.data.code == 200) {
|
|
|
- console.log(res.data)
|
|
|
- } else {
|
|
|
- this.$message.error(res.data.data)
|
|
|
- }
|
|
|
- })
|
|
|
- } else {
|
|
|
+ if (row.capacityIds == 0) {
|
|
|
row.lineId = this.lineSpelling[row.size]
|
|
|
- let arr = []
|
|
|
- arr.push(row)
|
|
|
- await this.axios
|
|
|
- .post('/api/v1/ams/dispatchSteelOrder', arr)
|
|
|
+ }
|
|
|
+ })
|
|
|
+ let map={
|
|
|
+ list:this.batchCapacityList
|
|
|
+ }
|
|
|
+ await this.axios
|
|
|
+ .post('/api/v1/ams/batchUpdateCapacity',map )
|
|
|
.then(res => {
|
|
|
if (res.data.code == '200') {
|
|
|
this.$message.success('派车成功!')
|
|
|
} else {
|
|
|
this.$message.error(res.data.data)
|
|
|
}
|
|
|
- })
|
|
|
- }
|
|
|
- }
|
|
|
+ })
|
|
|
this.batchCarrierVisible = false
|
|
|
this.getSteelReport()
|
|
|
} else {
|