|
@@ -1,4 +1,4 @@
|
|
-// 汽车调度
|
|
|
|
|
|
+// 汽车调度派车
|
|
<template>
|
|
<template>
|
|
<div class="container">
|
|
<div class="container">
|
|
<el-row>
|
|
<el-row>
|
|
@@ -103,7 +103,7 @@
|
|
<div
|
|
<div
|
|
class="driver position liaison"
|
|
class="driver position liaison"
|
|
v-for="(item, index) in deptBudgetList.tranCarInfoList"
|
|
v-for="(item, index) in deptBudgetList.tranCarInfoList"
|
|
- :key='index'
|
|
|
|
|
|
+ :key="index"
|
|
>
|
|
>
|
|
<ws-info-table>
|
|
<ws-info-table>
|
|
<div class="catNos">
|
|
<div class="catNos">
|
|
@@ -344,6 +344,7 @@ export default {
|
|
},
|
|
},
|
|
},
|
|
},
|
|
accessoryTFs: false,
|
|
accessoryTFs: false,
|
|
|
|
+ index:0,
|
|
}
|
|
}
|
|
},
|
|
},
|
|
activated() {
|
|
activated() {
|
|
@@ -373,7 +374,6 @@ export default {
|
|
}
|
|
}
|
|
},
|
|
},
|
|
add() {
|
|
add() {
|
|
- console.log(this.deptBudgetList.tranCarInfoList, 'sasasasas')
|
|
|
|
this.deptBudgetList.tranCarInfoList.push({
|
|
this.deptBudgetList.tranCarInfoList.push({
|
|
driverName: '',
|
|
driverName: '',
|
|
driverPhone: '',
|
|
driverPhone: '',
|
|
@@ -387,9 +387,26 @@ export default {
|
|
tranType: '1',
|
|
tranType: '1',
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- selectwaterContent() {},
|
|
|
|
//提交按钮
|
|
//提交按钮
|
|
submit() {
|
|
submit() {
|
|
|
|
+ for (var i = this.index; i < this.deptBudgetList.tranCarInfoList.length; i++) {
|
|
|
|
+ if (!this.deptBudgetList.tranCarInfoList[i].driver) {
|
|
|
|
+ this.$message({
|
|
|
|
+ message: '姓名不能为空!',
|
|
|
|
+ type: 'warning',
|
|
|
|
+ })
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+ for(var j = 0 ; j < this.carList.length ; j++){
|
|
|
|
+ if (this.carList[j].driverName == this.deptBudgetList.tranCarInfoList[i].driver && this.carList[j].disableStatusFlag == 1) {
|
|
|
|
+ this.$message({
|
|
|
|
+ message: this.deptBudgetList.tranCarInfoList[i].driver+'该司机已被禁用!',
|
|
|
|
+ type: 'warning',
|
|
|
|
+ })
|
|
|
|
+ return
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ }
|
|
this.$confirm(`提交成功后,任务将下发给司机,是否确定提交?`, {
|
|
this.$confirm(`提交成功后,任务将下发给司机,是否确定提交?`, {
|
|
cancelButtonText: '取消',
|
|
cancelButtonText: '取消',
|
|
confirmButtonText: '确定',
|
|
confirmButtonText: '确定',
|
|
@@ -428,6 +445,7 @@ export default {
|
|
.toPromise()
|
|
.toPromise()
|
|
.then((response) => {
|
|
.then((response) => {
|
|
if (response.tranCarInfoList.length > 0) {
|
|
if (response.tranCarInfoList.length > 0) {
|
|
|
|
+ this.index = response.tranCarInfoList.length
|
|
for (var i = 0; i < response.tranCarInfoList.length; i++) {
|
|
for (var i = 0; i < response.tranCarInfoList.length; i++) {
|
|
if (response.tranCarInfoList[i].id) {
|
|
if (response.tranCarInfoList[i].id) {
|
|
response.tranCarInfoList[i].disabled = true
|
|
response.tranCarInfoList[i].disabled = true
|
|
@@ -516,15 +534,15 @@ export default {
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
},
|
|
- selecttaskType(e) {
|
|
|
|
- for (var i = 0; i < this.taskTypeList.length; i++) {
|
|
|
|
- if (this.taskTypeList[i].value == e) {
|
|
|
|
- this.searchType = this.taskTypeList[i].type
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
- },
|
|
|
|
- approve() {},
|
|
|
|
- listQuery() {},
|
|
|
|
|
|
+ // selecttaskType(e) {
|
|
|
|
+ // for (var i = 0; i < this.taskTypeList.length; i++) {
|
|
|
|
+ // if (this.taskTypeList[i].value == e) {
|
|
|
|
+ // this.searchType = this.taskTypeList[i].type
|
|
|
|
+ // }
|
|
|
|
+ // }
|
|
|
|
+ // },
|
|
|
|
+ // approve() {},
|
|
|
|
+ // listQuery() {},
|
|
},
|
|
},
|
|
}
|
|
}
|
|
</script>
|
|
</script>
|