liyg vor 2 Jahren
Ursprung
Commit
d81e4bd123

+ 14 - 7
src/views/statisticalReport/components/salesLogisticsStatistics/saleSteelReports.vue

@@ -1090,7 +1090,7 @@
           ></el-input>
         </el-form-item>
         <el-form-item label="签收地址">
-          <el-input v-model="location" style="width:400px"></el-input>
+          <el-input v-model="location" style="width:400px" :disabled="orgCode!='wuliuyunshubu'"></el-input>
         </el-form-item>
         <el-form-item label="抵达图片(车头、满货箱)" style="">
           <el-upload
@@ -2515,11 +2515,17 @@ export default {
         this.$message.warning('该车未出厂,不允许签收')
         return
       }
-      if (row.arrivalAddress) {
-        this.location = row.arrivalAddress
-      } else {
-        this.location = row.addressPlace
-      }
+      //获取车辆定位
+      this.axios
+        .get('/api/v1/otms/getCurrentLocation?capcityNumber=' + row.newCapacityNo)
+        .then(res => {
+          if (res.data.status=='succeed' && res.data.data.result.status==1001) {
+            this.location=res.data.data.result.adr;
+          }else{
+            this.location=null;
+            this.$message.warning("获取不到车辆定位!请联系销售公司上传!");
+          }
+      });
       this.orderNumber = row.orderNo
       this.capacityNumber = row.capacityNo
       this.arrivalReceiving = true
@@ -2558,7 +2564,7 @@ export default {
     },
     arrivalAndReceive() {
       if (!this.location) {
-        this.$message.warning('请填写签收地址')
+        this.$message.warning('签收地址必须取车辆定位!若取不到请联系销售公司上传!')
         return
       }
       if (this.fileListArrival.length < 2) {
@@ -2625,6 +2631,7 @@ export default {
       this.dialogVisible = true
     },
     closeUpload() {
+      this.location=null
       this.arrivalReceiving = false
       this.isLoading = false
       this.$refs.arrival.clearFiles()