Bläddra i källkod

Merge branch 'master' of https://git.steerinfo.com/DAL-DAZHOU/icore-pass

luobang 2 år sedan
förälder
incheckning
892083045c

+ 128 - 0
src/views/RMS/components/addMaterialCoke.vue

@@ -0,0 +1,128 @@
+<template>
+  <!-- 添加运力信息 -->
+  <div class="addCapacity">
+    <PageTitle>返回</PageTitle>
+    <div class="form_box">
+      <el-form>
+        <el-form-item label="APP备注:">
+          <el-input v-model="form.materialCokeName"></el-input>
+        </el-form-item>
+      </el-form>
+    </div>
+
+    <div class="button_box">
+      <el-button @click="cancel">取消</el-button>
+      <el-button type="primary" @click="makeSure" :loading="addLoading"
+        >确定</el-button
+      >
+    </div>
+  </div>
+</template>
+
+<script>
+import PageTitle from "@/components/Page/Title";
+import { getCookie } from "@/utils/util.js";
+export default {
+  components: { PageTitle },
+  data() {
+    return {
+      form:{
+        materialCokeName:null
+      },
+      addLoading:false
+    };
+  },
+  created() {
+  
+  },
+  mounted() {
+    
+  },
+  methods: {
+    makeSure() {
+      this.addLoading=true;
+      if(!this.form || !this.form.materialCokeName){
+        this.$message.warning("请输入!");
+        this.addLoading=false;
+      }else{
+        this.axios.post("/api/v1/rms/insertMaterialCoke",this.form).then(res => {
+          if (res.data.code == "200") {
+            this.$message.success("新增成功!");
+            this.cancel();
+          }else{
+            this.$message.warning("新增失败!");
+          }
+          this.addLoading=false;
+        }).catch(()=>{
+          this.addLoading=false;
+        });
+      }
+    },
+    // 取消
+    cancel() {
+      this.$router.go(-1);
+    }
+  }
+};
+</script>
+<style lang="scss">
+.shippingCertificate {
+  width: 200px;
+}
+.el-form--inline .el-form-item__content {
+  display: inline-block;
+  vertical-align: top;
+  position: relative;
+  left: 37px;
+}
+.addCapacity {
+  .elForm {
+    margin-left: 40%;
+  }
+  .form_box {
+    width: 100%;
+    margin-top: 30px;
+    margin-left: 50px;
+    display: flex;
+    justify-content: center;
+    .el-form-item {
+      display: flex;
+      justify-content: center;
+      .el-form-item__label {
+        display: flex;
+        align-items: center;
+      }
+      .el-form-item__content {
+        .el-select {
+          width: 250px;
+        }
+        .el-input {
+          width: 250px;
+        }
+      }
+    }
+  }
+  .inputBox {
+    display: flex;
+    justify-content: center;
+    margin-bottom: 30px;
+    .text {
+      text-align: right;
+      display: flex;
+      align-items: center;
+      margin-right: 5px;
+    }
+    .input {
+      width: 250px;
+    }
+  }
+  .button_box {
+    display: flex;
+    justify-content: center;
+    .el-button {
+      width: 80px;
+      margin-right: 10px;
+    }
+  }
+}
+</style>

+ 131 - 0
src/views/RMS/components/addReceivingCompany.vue

@@ -0,0 +1,131 @@
+<template>
+  <!-- 添加运力信息 -->
+  <div class="addCapacity">
+    <PageTitle>返回</PageTitle>
+    <div class="form_box">
+      <el-form>
+        <el-form-item label="收款客户编码:">
+          <el-input v-model="form.companyCode"></el-input>
+        </el-form-item>
+        <el-form-item label="收款客户名称:">
+          <el-input v-model="form.companyName"></el-input>
+        </el-form-item>
+      </el-form>
+    </div>
+
+    <div class="button_box">
+      <el-button @click="cancel">取消</el-button>
+      <el-button type="primary" @click="makeSure" :loading="addLoading"
+        >确定</el-button
+      >
+    </div>
+  </div>
+</template>
+
+<script>
+import PageTitle from "@/components/Page/Title";
+import { getCookie } from "@/utils/util.js";
+export default {
+  components: { PageTitle },
+  data() {
+    return {
+      form:{
+        materialCokeName:null
+      },
+      addLoading:false
+    };
+  },
+  created() {
+  
+  },
+  mounted() {
+    
+  },
+  methods: {
+    makeSure() {
+      this.addLoading=true;
+      if(!this.form || !this.form.companyCode || !this.form.companyName){
+        this.$message.warning("请输入!");
+        this.addLoading=false;
+      }else{
+        this.axios.post("/api/v1/rms/insertReceiveCompany",this.form).then(res => {
+          if (res.data.code == "200") {
+            this.$message.success("新增成功!");
+            this.cancel();
+          }else{
+            this.$message.warning("新增失败!");
+          }
+          this.addLoading=false;
+        }).catch(()=>{
+          this.addLoading=false;
+        });
+      }
+    },
+    // 取消
+    cancel() {
+      this.$router.go(-1);
+    }
+  }
+};
+</script>
+<style lang="scss">
+.shippingCertificate {
+  width: 200px;
+}
+.el-form--inline .el-form-item__content {
+  display: inline-block;
+  vertical-align: top;
+  position: relative;
+  left: 37px;
+}
+.addCapacity {
+  .elForm {
+    margin-left: 40%;
+  }
+  .form_box {
+    width: 100%;
+    margin-top: 30px;
+    margin-left: 50px;
+    display: flex;
+    justify-content: center;
+    .el-form-item {
+      display: flex;
+      justify-content: center;
+      .el-form-item__label {
+        display: flex;
+        align-items: center;
+      }
+      .el-form-item__content {
+        .el-select {
+          width: 250px;
+        }
+        .el-input {
+          width: 250px;
+        }
+      }
+    }
+  }
+  .inputBox {
+    display: flex;
+    justify-content: center;
+    margin-bottom: 30px;
+    .text {
+      text-align: right;
+      display: flex;
+      align-items: center;
+      margin-right: 5px;
+    }
+    .input {
+      width: 250px;
+    }
+  }
+  .button_box {
+    display: flex;
+    justify-content: center;
+    .el-button {
+      width: 80px;
+      margin-right: 10px;
+    }
+  }
+}
+</style>

+ 153 - 0
src/views/RMS/components/materialCoke.vue

@@ -0,0 +1,153 @@
+<template>
+  <div class="steel_inbound">
+    <div class="sache">
+      <el-input placeholder="请输入内容" v-model="textInput" clearable>
+      </el-input>
+      <el-button
+        type="primary"
+        class="btn"
+        @click="onclick"
+        :loading="selectLoading"
+      >
+        <i class="el-icon-search"></i>查询
+      </el-button>
+      <el-button type="primary" class="btn" @click="toInsert">
+        <i class="el-icon-plus"></i>新增
+      </el-button>
+  
+      <!-- <el-button type="primary" @click="exportAllExcel()"
+        ><i class="el-icon-download"></i>导出(Excel)
+      </el-button> -->
+    </div>
+    <div class="table">
+      <dilTable
+        ref="excelDom"
+        v-bind.sync="options"
+        :loading="tableloading"
+        @func="func"
+        :isKuang="isKuang"
+      >
+        <el-table-column fixed="right" label="操作" width="50">
+          <template slot-scope="scope">
+            <!-- <el-button
+              type="text"
+              size="small"
+              @click="updateMaterialCoke(scope.row.capacityCarrierId)"
+            >
+              修改
+            </el-button> -->
+            <el-button
+              type="text"
+              size="small"
+              @click="deleteMaterialCoke(scope.row)"
+            >
+              删除
+            </el-button>
+            <!-- <el-button
+              type="text"
+              size="small"
+              @click="showMaterialCoke(scope.row.capacityId)"
+              v-if="show == false"
+            >
+              查看详情
+            </el-button> -->
+          </template>
+        </el-table-column>
+      </dilTable>
+    </div>
+  </div>
+</template>
+<script>
+import { getCookie } from "@/utils/util.js";
+export default {
+  data() {
+    return {
+      selectLoading: false,
+      isKuang: false,
+      tableloading: false,
+      show: false,
+      name: "homeworkPath",
+      textInput: "",
+      restaurants: [],
+      ssoId: null,
+      options: {
+        // first请求数据的地址
+        requestUrl: "/api/v1/rms/getMaterialCoke?apiId=524"
+      },
+      noSettleDetailsColumn: [],
+      exportAllList:[]
+    };
+  },
+  created() {
+  },
+  methods: {
+    func(res) {
+      if (this.tableloading) {
+        this.tableloading = false;
+      }
+      if (this.isKuang) {
+        this.isKuang = false;
+      }
+      if (this.selectLoading) {
+        this.selectLoading = false;
+      }
+    },
+    onclick() {
+      this.isKuang = true;
+      this.tableloading = true;
+      this.selectLoading = true;
+      this.options.requestUrl="/api/v1/rms/getMaterialCoke?apiId=524&con="+this.textInput+"&i="+new Date();
+    },
+    toInsert() {
+      this.$router.push("/addMaterialCoke");
+    },
+    updateMaterialCoke(capacityCarrierId) {
+      // console.log("capacityCarrierId" +capacityCarrierId);
+      this.$router.push("/editCapacity/" + capacityCarrierId);
+    },
+    showMaterialCoke(capacityId) {
+      this.$router.push("/showMaterialCoke/" + capacityId);
+    },
+    deleteUser(userId) {
+      this.axios.delete("pass/v1/sysusers/" + userId).then(res => {});
+    },
+    deleteMaterialCoke(row) {
+      console.log("row", row);
+      console.log(row);
+        this.$confirm(
+          "是否删除?",
+          "提示",
+          {
+            confirmButtonText: "确定",
+            cancelButtonText: "取消",
+            type: "warning"
+          }
+        ).then(() => {
+            this.axios
+              .post("/api/v1/rms/deleteMaterialCoke/"+row.materialCokeId)
+              .then(res => {
+                this.onclick();
+                this.$message.success("删除成功!");
+          });
+          })
+          .catch(() => {
+            this.$message({
+              type: "info",
+              message: "已取消删除"
+            });
+          });
+    }
+  }
+};
+</script>
+<style lang="scss" scode>
+.steel_inbound {
+  .sache {
+    padding: 1.25rem 0.375rem;
+    .el-input {
+      width: 20%;
+      margin-right: 1.25rem;
+    }
+  }
+}
+</style>

+ 153 - 0
src/views/RMS/components/receivingCompany.vue

@@ -0,0 +1,153 @@
+<template>
+  <div class="steel_inbound">
+    <div class="sache">
+      <el-input placeholder="请输入内容" v-model="textInput" clearable>
+      </el-input>
+      <el-button
+        type="primary"
+        class="btn"
+        @click="onclick"
+        :loading="selectLoading"
+      >
+        <i class="el-icon-search"></i>查询
+      </el-button>
+      <el-button type="primary" class="btn" @click="toInsert">
+        <i class="el-icon-plus"></i>新增
+      </el-button>
+  
+      <!-- <el-button type="primary" @click="exportAllExcel()"
+        ><i class="el-icon-download"></i>导出(Excel)
+      </el-button> -->
+    </div>
+    <div class="table">
+      <dilTable
+        ref="excelDom"
+        v-bind.sync="options"
+        :loading="tableloading"
+        @func="func"
+        :isKuang="isKuang"
+      >
+        <el-table-column fixed="right" label="操作" width="50">
+          <template slot-scope="scope">
+            <!-- <el-button
+              type="text"
+              size="small"
+              @click="updateReceivingCompany(scope.row.capacityCarrierId)"
+            >
+              修改
+            </el-button> -->
+            <el-button
+              type="text"
+              size="small"
+              @click="deleteReceivingCompany(scope.row)"
+            >
+              删除
+            </el-button>
+            <!-- <el-button
+              type="text"
+              size="small"
+              @click="showReceivingCompany(scope.row.capacityId)"
+              v-if="show == false"
+            >
+              查看详情
+            </el-button> -->
+          </template>
+        </el-table-column>
+      </dilTable>
+    </div>
+  </div>
+</template>
+<script>
+import { getCookie } from "@/utils/util.js";
+export default {
+  data() {
+    return {
+      selectLoading: false,
+      isKuang: false,
+      tableloading: false,
+      show: false,
+      name: "homeworkPath",
+      textInput: "",
+      restaurants: [],
+      ssoId: null,
+      options: {
+        // first请求数据的地址
+        requestUrl: "/api/v1/rms/getReceiveCompany?apiId=525"
+      },
+      noSettleDetailsColumn: [],
+      exportAllList:[]
+    };
+  },
+  created() {
+  },
+  methods: {
+    func(res) {
+      if (this.tableloading) {
+        this.tableloading = false;
+      }
+      if (this.isKuang) {
+        this.isKuang = false;
+      }
+      if (this.selectLoading) {
+        this.selectLoading = false;
+      }
+    },
+    onclick() {
+      this.isKuang = true;
+      this.tableloading = true;
+      this.selectLoading = true;
+      this.options.requestUrl="/api/v1/rms/getReceiveCompany?apiId=525&con="+this.textInput+"&i="+new Date();
+    },
+    toInsert() {
+      this.$router.push("/addReceivingCompany");
+    },
+    updateReceivingCompany(capacityCarrierId) {
+      // console.log("capacityCarrierId" +capacityCarrierId);
+      this.$router.push("/editCapacity/" + capacityCarrierId);
+    },
+    showReceivingCompany(capacityId) {
+      this.$router.push("/showReceivingCompany/" + capacityId);
+    },
+    deleteUser(userId) {
+      this.axios.delete("pass/v1/sysusers/" + userId).then(res => {});
+    },
+    deleteReceivingCompany(row) {
+      console.log("row", row);
+      console.log(row);
+        this.$confirm(
+          "是否删除?",
+          "提示",
+          {
+            confirmButtonText: "确定",
+            cancelButtonText: "取消",
+            type: "warning"
+          }
+        ).then(() => {
+            this.axios
+              .post("/api/v1/rms/deleteReceiveCompany/"+row.companyId)
+              .then(res => {
+                this.onclick();
+                this.$message.success("删除成功!");
+          });
+          })
+          .catch(() => {
+            this.$message({
+              type: "info",
+              message: "已取消删除"
+            });
+          });
+    }
+  }
+};
+</script>
+<style lang="scss" scode>
+.steel_inbound {
+  .sache {
+    padding: 1.25rem 0.375rem;
+    .el-input {
+      width: 20%;
+      margin-right: 1.25rem;
+    }
+  }
+}
+</style>

+ 8 - 0
src/views/RMS/router/index.js

@@ -9,6 +9,10 @@ const addCapacity = () => import( '../components/addCapacity.vue')
 const addCapacityType = () => import( '../components/addCapacityType.vue')
 const addTransRange = () => import( '../components/addTransRange.vue')
 const transRange = () => import( '../components/transRange.vue')
+const addMaterialCoke = () => import( '../components/addMaterialCoke.vue')
+const materialCoke = () => import( '../components/materialCoke.vue')
+const addReceivingCompany = () => import( '../components/addReceivingCompany.vue')
+const receivingCompany = () => import( '../components/receivingCompany.vue')
 const addCarDriver = () => import( '../components/addCarDriver.vue')
 const addCarrier = () => import( '../components/addCarrier.vue')
 const addConsignee = () => import( '../components/addConsignee.vue')
@@ -86,6 +90,10 @@ const constantRouterMap = [
 		{path: 'addCapacityType', name: 'addCapacityType', meta: {code: 'xtpzgl-jggl'}, component: addCapacityType},
 		{path: 'addTransRange', name: 'addTransRange', meta: {code: 'xtpzgl-jggl'}, component: addTransRange},
 		{path: 'transRange', name: 'transRange', meta: {code: 'xtpzgl-jggl'}, component: transRange},
+		{path: 'addMaterialCoke', name: 'addMaterialCoke', meta: {code: 'xtpzgl-jggl'}, component: addMaterialCoke},
+		{path: 'materialCoke', name: 'materialCoke', meta: {code: 'xtpzgl-jggl'}, component: materialCoke},
+		{path: 'addReceivingCompany', name: 'addReceivingCompany', meta: {code: 'xtpzgl-jggl'}, component: addReceivingCompany},
+		{path: 'receivingCompany', name: 'receivingCompany', meta: {code: 'xtpzgl-jggl'}, component: receivingCompany},
 		{path: 'addCarDriver', name: 'addCarDriver', meta: {code: 'xtpzgl-yhgl'}, component: addCarDriver},
 		{path: 'addCarrier', name: 'addCarrier', meta: {code: 'xtpzgl-yhgl'}, component: addCarrier},
 		{path: 'addConsignee',name: 'addConsignee',meta: {code:'xtpzgl-yhgl'},component: addConsignee},

+ 16 - 11
src/views/statisticalReport/components/salesLogisticsStatistics/saleSteelReports.vue

@@ -2515,17 +2515,22 @@ export default {
         this.$message.warning('该车未出厂,不允许签收')
         return
       }
-      //获取车辆定位
-      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("获取不到车辆定位!请联系销售公司上传!");
-          }
-      });
+      if(row.arrivalAddress){
+        //优先获取抵达地址
+        this.location=row.arrivalAddress;
+      }else{
+        //其次获取车辆定位
+          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