| | |
| | | class="form-input" |
| | | type="digit" |
| | | placeholder="请输入行驶公里数" |
| | | v-model="taskForm.distance" |
| | | v-model="taskForm.transferDistance" |
| | | /> |
| | | </view> |
| | | |
| | |
| | | plannedEndTime: '', |
| | | startLocation: '', |
| | | endLocation: '', |
| | | distance: '', |
| | | transferDistance: '', |
| | | remark: '' |
| | | }, |
| | | loading: false |
| | |
| | | this.taskForm.plannedEndTime = this.taskDetail.plannedEndTime || '' |
| | | this.taskForm.startLocation = this.taskDetail.departureAddress || '' |
| | | this.taskForm.endLocation = this.taskDetail.destinationAddress || '' |
| | | this.taskForm.distance = this.taskDetail.estimatedDistance || '' |
| | | this.taskForm.transferDistance = this.taskDetail.transferDistance || '' |
| | | this.taskForm.remark = this.taskDetail.remark || '' |
| | | |
| | | // 设置车辆信息 |
| | |
| | | |
| | | // 监听mixin中的距离计算完成事件 |
| | | this.$once('distance-calculated', (distance) => { |
| | | this.taskForm.distance = this.formatDistance(distance) |
| | | this.taskForm.transferDistance = this.formatDistance(distance) |
| | | }) |
| | | |
| | | this.closeMapSelector() |
| | |
| | | destinationLatitude: this.addressCoordinates.endLocation ? this.addressCoordinates.endLocation.lat : null, |
| | | |
| | | // 距离(主任务字段) |
| | | distance: this.taskForm.distance ? parseFloat(this.taskForm.distance) : null, |
| | | transferDistance: this.taskForm.transferDistance ? parseFloat(this.taskForm.transferDistance) : null, |
| | | |
| | | remark: this.taskForm.remark |
| | | } |