luobang vor 2 Jahren
Ursprung
Commit
734fe5c7ba

+ 2 - 1
build/utils.js

@@ -21,7 +21,8 @@ const devPathSrc = path.resolve(__dirname, "../../../src"); // node_modules应
 // let devModules = ["index", "WMS", "inward"];
 // let devModules = ["index", "inward", "WMS", "queue"];
 // let devModules = ["index", "appoint", "statisticalReport", "sale"];
-let devModules = ["index", "appoint", "statisticalReport", "WMS"];
+// let devModules = ["index", "appoint", "statisticalReport", "WMS", "sale"];
+let devModules = ["all"];
 //let devModules = ["BMS","index","sale","appoint","AMS","queue","QMS","RMS",'statisticalReport',"inward"];
 
 //let devModules = ["BMS","index","sale","appoint","AMS","queue","QMS","RMS",'statisticalReport'];

+ 2 - 2
config/index.js

@@ -65,8 +65,8 @@ let proxyTable = {
   },
   // 所有数据的请求域名地址
   "/api/v1": {
-    // target: "http://172.16.33.166:80",
-    target: "http://localhost:8080",
+    target: "http://172.16.33.166:80",
+    // target: "http://localhost:8080",
     // target: "http://192.168.1.101:8080",
     ws: true,
     pathRewrite: {

+ 1 - 0
src/views/index/components/login.vue

@@ -172,6 +172,7 @@ export default {
                   }
                   // 普通用户
                 } else {
+                  // this.$router.push("printScan");
                   if (
                     userInfo.hasOwnProperty("sysGroup") &&
                     userInfo.sysGroup !== "" &&

+ 158 - 0
src/views/index/components/printScan.vue

@@ -0,0 +1,158 @@
+<template xmlns="http://www.w3.org/1999/html">
+  <div class="saleSelfMachine">
+    <div class="background">
+      <img :src="backgroundImgURL" width="100%" height="100%" />
+    </div>
+    <div class="orderNumberData">
+      <el-input
+        placeholder="请将二维码放置在扫描区"
+        v-model="orderNumber"
+        :focus="true"
+        ref="inputs"
+        :disabled="!isEdit"
+        v-show="false"
+      >
+      </el-input>
+      <!--style="display:block;width:120px"-->
+      <div v-show="false">
+        手动输入开关:
+      </div>
+      <i class="el-icon-full-screen" @click="fullScreen" v-show="edit1"></i>
+      <!--      <el-switch
+        v-model="isEdit"
+        active-color="#66ccff"
+        inactive-color="#ffffff"
+      >
+      </el-switch>-->
+    </div>
+    <div class="tip">
+      <h1>将手机二维码对准摄像头</h1>
+      <h1>扫描</h1>
+      <!-- 将手机二维码对准摄像头 扫描<br /> -->
+      <i class="el-icon-bottom" style="font-size: 100px"></i>
+    </div>
+  </div>
+</template>
+<script>
+import screenfull from "screenfull";
+export default {
+  data() {
+    return {
+      orderNumber: null,
+      isEdit: true,
+      edit1: true,
+      backgroundImgURL: require("@/assets/saleSelfMachine/backgroundImg.jpg")
+    };
+  },
+  created() {
+    this.changfouce();
+  },
+  // watch:{
+  //    data:"toSaleSelfMachine"
+  // },
+  methods: {
+    //输入框自动聚焦
+    changfouce() {
+      this.$nextTick(x => {
+        this.$refs.inputs.focus();
+      });
+    },
+    fullScreen() {
+      if (screenfull.isEnabled && !screenfull.isFullscreen) {
+        screenfull.request();
+        this.edit1 = false;
+      }
+    },
+    async querynumber() {
+      console.log(this.orderNumber);
+      let orderNumber = this.orderNumber;
+      let i = 0;
+      await this.axios
+        .post("/api/v1/tms/queryNumber?orderNumber=" + orderNumber)
+        .then(res => {
+          console.log("查找出来的数据");
+          console.log(res.data);
+          console.log("-------------------------");
+          if (res.data.printnumber == 1) {
+            i = 1;
+          }
+        });
+      console.log(i);
+      return i;
+    }
+    //失去焦点后自动执行获得焦点事件
+    // onInputBlur(){
+    //     console.log("获取焦点")
+    //     this.changfouce();
+    // }
+    // toSaleSelfMachine(){
+    //      this.$router.push({
+    //         path:'/saleSelfMachine',
+    //     })
+    // }
+  },
+  mounted() {
+    console.log(screenfull.isFullscreen);
+    // this.changfouce();
+    const timer = setInterval(async () => {
+      // if(this.$refs.inputs.focus==false){
+      //     console.log("false")
+      this.changfouce();
+      //}
+      if (this.orderNumber != null && this.orderNumber.length == 21) {
+        if (
+          this.orderNumber.startsWith("WYSDD") == true ||
+          this.orderNumber.startsWith("wysdd") == true
+        ) {
+          let promise = await this.querynumber(this.orderNumber);
+          console.log(promise);
+          if (promise == 1) {
+            this.$message.error("你已经打印过了");
+            this.orderNumber = null;
+            return;
+          }
+          this.$router.push({
+            path: "/printReceipt?orderNumber=" + this.orderNumber
+          });
+        }
+      } else if (this.orderNumber.length > 21) {
+        //清空输入框,免得一次多个重复订单还无法删除
+        this.orderNumber = null;
+      }
+    }, 3000);
+    this.$once("hook:beforeDestroy", () => {
+      clearInterval(timer);
+    });
+  }
+};
+</script>
+<style lang="scss">
+.saleSelfMachine {
+  width: 100vh;
+  height: 100vh;
+  .background {
+    width: 100%;
+    height: 100%;
+    z-index: -1;
+    position: absolute;
+    overflow: hidden;
+  }
+  .orderNumberData {
+    width: 100%;
+    color: #fff;
+    position: absolute;
+    display: flex;
+    justify-content: center;
+    align-items: center;
+  }
+  .tip {
+    display: flex;
+    justify-content: center;
+    align-items: center;
+    width: 1000px;
+    height: 300px;
+    font-size: 60px;
+    color: #e6e6e6;
+  }
+}
+</style>

+ 73 - 62
src/views/index/router/index.js

@@ -1,81 +1,92 @@
-import Vue from 'vue'
-import Router from 'vue-router'
-import routerBefore from '@/config/routerBefore.js'
+import Vue from "vue";
+import Router from "vue-router";
+import routerBefore from "@/config/routerBefore.js";
 
 // 主页
-import main from '@/components/main.vue'
+import main from "@/components/main.vue";
 
 // 登录
-import login from '@/views/index/components/login.vue'// 登录
-import download from '@/views/index/components/download.vue'
+import login from "@/views/index/components/login.vue"; // 登录
+import download from "@/views/index/components/download.vue";
 // 抽奖结果
-import luckDraw from '@/views/index/components/luckDraw.vue'
-
+import luckDraw from "@/views/index/components/luckDraw.vue";
 
 // 网页登录不可访问
-import page404 from '@/views/index/components/page404.vue'
+import page404 from "@/views/index/components/page404.vue";
 
 // 集团公司选择过渡页
-import selectCompany from '@/views/index/components/selectCompany.vue'
+import selectCompany from "@/views/index/components/selectCompany.vue";
+
+import printScan from "@/views/index/components/printScan.vue";
 
-Vue.use(Router)
+Vue.use(Router);
 
-export const constantRouterMap = [{
-        path: '/',
-        meta: {
-            'title': '登录'
-        },
-        component: login
+export const constantRouterMap = [
+  {
+    path: "/",
+    meta: {
+      title: "登录"
+    },
+    component: login
+  },
+  {
+    path: "/printScan",
+    name: "printScan",
+    meta: {
+      title: "自助一体机"
     },
-    
-    {
-        path: '/download',
-        name: 'download',
-        meta: {
-            'title': '下载'
-        },
-        component: download
+    component: printScan
+  },
+  {
+    path: "/download",
+    name: "download",
+    meta: {
+      title: "下载"
     },
-    {
-        path: '/login',
-        name: 'login',
-        meta: {
-            'title': '登录'
-        },
-        component: login
+    component: download
+  },
+  {
+    path: "/login",
+    name: "login",
+    meta: {
+      title: "登录"
     },
-    {
-        path:'/luckDraw',
-        name:'luckDraw',
-        meta:{
-            'title':'抽奖结果'
-        },
-        component:luckDraw
+    component: login
+  },
+  {
+    path: "/luckDraw",
+    name: "luckDraw",
+    meta: {
+      title: "抽奖结果"
     },
-    {
-        path: '/default',
-        name: 'default',
-        component: main,
-        meta: {
-            'title': '首页'
-        }
+    component: luckDraw
+  },
+  {
+    path: "/default",
+    name: "default",
+    component: main,
+    meta: {
+      title: "首页"
+    }
+  },
+  {
+    path: "/selectCompany",
+    name: "selectCompany",
+    component: selectCompany,
+    meta: {
+      title: "集团与公司用户跳转页"
+    }
+  },
+  ,
+  {
+    path: "/page404",
+    name: "page404",
+    meta: {
+      title: "404"
     },
-    {
-        path: '/selectCompany',
-        name: 'selectCompany',
-        component: selectCompany,
-        meta: {
-            'title': '集团与公司用户跳转页'
-        }
-    },,
-    {
-        path: '/page404',
-        name: 'page404',
-        meta: {
-            'title': '404'
-        },
-        component: page404
-}];
+    component: page404
+  }
+];
 
 const router = new Router({
   // mode: 'history', // require service support

+ 11 - 6
src/views/statisticalReport/components/salesLogisticsStatistics/saleSteelAllReport.vue

@@ -159,7 +159,12 @@
           width="150px"
         >
         </el-table-column>
-        <el-table-column prop="materialSpe" label="物资规格" align="center" sortable>
+        <el-table-column
+          prop="materialSpe"
+          label="物资规格"
+          align="center"
+          sortable
+        >
         </el-table-column>
         <el-table-column
           prop="materialNum"
@@ -309,7 +314,7 @@
               @click="updateconsigneeTel(scope.row)"
               type="primary"
               v-if="scope.row.isconsigneeTelShow == 1"
-            >提交</el-button
+              >提交</el-button
             >
           </template>
         </el-table-column>
@@ -947,9 +952,9 @@ export default {
       }
       this.axios
         .post("/api/v1/ams/updateConsigneeTel", {
-          saleOrderNo:row.saleOrderNo,
-          saleMaterialId:row.saleMaterialId,
-          consigneeTel:row.consigneeTel
+          saleOrderNo: row.saleOrderNo,
+          saleOrderMaterialId: row.saleOrderMaterialId,
+          consigneeTel: row.consigneeTel
         })
         .then(res => {
           if (res.data.code == "200") {
@@ -1053,7 +1058,7 @@ export default {
         this.axios
           .post("/api/v1/ams/dispatchToCarrier", arr)
           .then(res => {
-            if (res.data.code == "200") {
+            if (res.data.code == "0") {
               this.$message.success("授权承运商成功");
               this.getSteelReport();
               loading.close();

+ 406 - 79
src/views/statisticalReport/components/salesLogisticsStatistics/saleSteelReports.vue

@@ -9,7 +9,7 @@
             placeholder="请选择需筛选的内容"
             clearable
             @change="changeScreen"
-            style="width:150px"
+            style="width:120px"
           >
             <el-option
               v-for="item in options"
@@ -20,12 +20,34 @@
             </el-option>
           </el-select>
           <el-input
-            style="width:200px"
+            style="width:180px"
             v-model="input"
             placeholder="请输入查询条件"
             clearable
           ></el-input>
         </el-form-item>
+        <el-form-item>
+          <el-select
+            v-model="screen1"
+            placeholder="请选择需筛选的内容"
+            clearable
+            style="width:120px"
+          >
+            <el-option
+              v-for="item in options1"
+              :key="item.value"
+              :label="item.label"
+              :value="item.value"
+            >
+            </el-option>
+          </el-select>
+          <el-input
+            style="width:180px"
+            v-model="input1"
+            placeholder="请输入查询条件"
+            clearable
+          ></el-input>
+        </el-form-item>
         <el-form-item>
           <label class="el-form-item__label" style="width: auto;"
             >订单时间:</label
@@ -34,7 +56,7 @@
             v-model="startTime"
             type="datetime"
             placeholder="选择日期时间"
-            style="width:200px"
+            style="width:180px"
           >
           </el-date-picker>
           <span>至</span>
@@ -42,7 +64,7 @@
             v-model="endTime"
             type="datetime"
             placeholder="选择日期时间"
-            style="width:200px"
+            style="width:180px"
           >
           </el-date-picker>
           <el-button type="primary" class="btn" @click="onclick">
@@ -60,20 +82,10 @@
           </el-button>
         </el-form-item>
         <el-form-item>
-          <span style="margin-left: 1rem">合计车数:</span>
-          <el-input
-            v-model="totalCapacity"
-            :disabled="true"
-            style="width: 100px;"
-          ></el-input>
-        </el-form-item>
-        <el-form-item>
-          <span style="margin-left: 1rem">合计件数:</span>
-          <el-input
-            v-model="totalNumber"
-            :disabled="true"
-            style="width: 100px;"
-          ></el-input>
+          <span style="margin-left: 1rem;font-size:16px">车数/件数:</span>
+          <span style="font-size:16px"
+            >{{ totalCapacity }}/{{ totalNumber }}</span
+          >
         </el-form-item>
       </el-form>
     </div>
@@ -239,7 +251,7 @@
       <el-dialog
         title="运单详情"
         :visible.sync="centerDialogVisible"
-        width="80%"
+        width="90%"
         center
       >
         <div class="steelMapClass">
@@ -323,8 +335,128 @@
                 @click="addAddressClick"
               ></el-button>
             </div>
+            <div
+              class="steelMapClass23"
+              v-if="
+                steelMap.carStatus == 4 ||
+                  steelMap.carStatus == 5 ||
+                  steelMap.carStatus == null
+              "
+            >
+              <el-button type="danger" round @click="deleteEasEntryId"
+                >关闭运单</el-button
+              >
+            </div>
+          </div>
+          <div class="steelMapClass3">
+            <div class="steelMapClass32">
+              <span>收货客户电话:</span>
+              <el-input
+                v-model="steelMap.consigneeTel"
+                style="width:200px"
+              ></el-input>
+              <el-button
+                type="success"
+                icon="el-icon-check"
+                circle
+                @click="updateconsigneeTel"
+              ></el-button>
+            </div>
+            <div class="steelMapClass33">
+              <span>承运商:</span>
+              <el-autocomplete
+                style="width:150px"
+                v-model="steelMap.carrierName"
+                :fetch-suggestions="querySearchCarrier"
+                placeholder="请输入承运商"
+                @select="handleSelectCarrier"
+              >
+              </el-autocomplete>
+              <el-button
+                type="success"
+                icon="el-icon-check"
+                circle
+                @click="updateTruckCarrier"
+              ></el-button>
+            </div>
+            <div class="steelMapClass33">
+              <span>车牌号:</span>
+              <el-autocomplete
+                style="width:120px"
+                v-model="steelMap.capacityNo"
+                :fetch-suggestions="querySearch"
+                placeholder="请输入车牌号"
+                @select="handleSelect()"
+              ></el-autocomplete>
+              <el-button
+                type="success"
+                icon="el-icon-check"
+                circle
+                @click="updateCapacity"
+              ></el-button>
+            </div>
+            <div class="steelMapClass33">
+              <span>司机电话:</span>
+              <el-input
+                style="width:120px"
+                v-model="steelMap.capacityTel"
+                placeholder="请输入电话号码"
+              ></el-input>
+              <el-button
+                type="success"
+                icon="el-icon-check"
+                circle
+                @click="updateDriverTel"
+              ></el-button>
+            </div>
+          </div>
+          <div class="steelMapClass4">
+            <div class="steelMapClass42" v-if="steelMap.orderNo != null">
+              <span>运输订单号:</span>
+              <span>{{ steelMap.orderNo }}</span>
+            </div>
+            <div class="steelMapClass43">
+              <span>运单状态:</span>
+              <span>{{ steelMap.orderStatus }}</span>
+            </div>
+            <div
+              class="steelMapClass43"
+              v-if="steelMap.orderStatusTime != null"
+            >
+              <span>状态更新时间:</span>
+              <span>{{ steelMap.orderStatusTime }}</span>
+            </div>
+          </div>
+          <div class="steelMapClass5">
+            <div class="steelMapClass52" v-if="steelMap.arrivalAddress != null">
+              <span>抵达地址:</span>
+              <span>{{ steelMap.arrivalAddress }}</span>
+              <span class="steelMapClass521"
+                ><el-button
+                  type="success"
+                  icon="el-icon-money"
+                  circle
+                  @click="toPhotoClick"
+                ></el-button
+              ></span>
+            </div>
+          </div>
+          <div class="steelMapClass6">
+            <div class="steelMapClass62" v-if="steelMap.receiptAddress != null">
+              <span>签收地址:</span>
+              <span>{{ steelMap.receiptAddress }}</span>
+              <span class="steelMapClass621"
+                ><el-button
+                  type="success"
+                  icon="el-icon-money"
+                  circle
+                  @click="receipctPhotoClick"
+                ></el-button
+              ></span>
+            </div>
           </div>
         </div>
+
         <div class="table">
           <el-table
             :data="steelMap.mapList"
@@ -349,8 +481,31 @@
               prop="materialNum"
               label="物资件数"
               align="center"
-              width="150px"
+              width="200px"
             >
+              <template slot-scope="scope">
+                <button
+                  type="primary"
+                  @click="scope.row.materialNum--"
+                  style="height:40px"
+                >
+                  -
+                </button>
+                <input
+                  v-model="scope.row.materialNum"
+                  style="width:40px;height: 40px;font-size:16px;line-height: 40px;text-align: center;"
+                />
+                <button
+                  type="primary"
+                  @click="scope.row.materialNum--"
+                  style="height:40px"
+                >
+                  +
+                </button>
+                <el-button type="primary" @click="updateBillOrder(scope.row)"
+                  >提交</el-button
+                >
+              </template>
             </el-table-column>
             <el-table-column prop="grossWeight" label="毛重"> </el-table-column>
             <el-table-column
@@ -375,6 +530,29 @@
               width="100px"
             >
             </el-table-column>
+            <el-table-column
+              label="分录操作"
+              fixed="right"
+              width="120px"
+              align="center"
+            >
+              <template slot-scope="scope">
+                <el-button
+                  type="text"
+                  size="small"
+                  @click="closeEasEntryId(scope.row)"
+                  v-if="scope.row.deletedStatus == null"
+                  >关闭分录</el-button
+                >
+                <el-button
+                  type="text"
+                  size="small"
+                  @click="adverseCloseSaleMaterial(scope.row)"
+                  v-if="scope.row.deletedStatus != null"
+                  >反关闭分录</el-button
+                >
+              </template>
+            </el-table-column>
           </el-table>
         </div>
         <span slot="footer" class="dialog-footer">
@@ -417,6 +595,7 @@ import { getCookie } from "@/utils/util.js";
 export default {
   data() {
     return {
+      consigneeFiltList: [],
       //弹出框
       centerDialogVisible: false,
       //根据车序号查询的值
@@ -426,6 +605,7 @@ export default {
       drawer: false,
       input: null,
       screen: "",
+      screen1: "",
       options: [
         {
           value: "下单客户",
@@ -440,6 +620,20 @@ export default {
           lable: "车牌号"
         }
       ],
+      options1: [
+        {
+          value: "下单客户",
+          lable: "下单客户"
+        },
+        {
+          value: "承运商",
+          lable: "承运商"
+        },
+        {
+          value: "车牌号",
+          lable: "车牌号"
+        }
+      ],
       startTime: null,
       endTime: null,
       //合计净重
@@ -521,14 +715,21 @@ export default {
       isShow: false,
       srcList2: [],
       src2: "",
-      isShow2: false
+      isShow2: false,
+      input1: ""
     };
   },
   created() {
     this.getSteelReport();
   },
   mounted() {},
+  computed: {},
   methods: {
+    //筛选
+    //筛选客户
+    filterConsignee(value, row, column) {
+      return row.consigneeName === value;
+    },
     //点击操作弹出框
     operation(row) {
       console.log(row);
@@ -548,9 +749,11 @@ export default {
       this.centerDialogVisible = true;
     },
     //查看抵达图
-    toPhotoClick(orderNo) {
+    toPhotoClick() {
       this.axios
-        .post("/api/v1/otms/getArrivalPhoto?orderNumber=" + orderNo)
+        .post(
+          "/api/v1/otms/getArrivalPhoto?orderNumber=" + this.steelMap.orderNo
+        )
         .then(res => {
           this.srcList = [];
           this.src = res.data.data;
@@ -559,9 +762,12 @@ export default {
         });
     },
     //查看签收图
-    receipctPhotoClick(orderNo) {
+    receipctPhotoClick() {
       this.axios
-        .post("/api/v1/otms/getReceivingPhotoByUrl?orderNumber=" + orderNo)
+        .post(
+          "/api/v1/otms/getReceivingPhotoByUrl?orderNumber=" +
+            this.steelMap.orderNo
+        )
         .then(res => {
           console.log(res.data);
           this.isShow2 = true;
@@ -590,9 +796,11 @@ export default {
           .then(res => {
             if (res.data.code == "200") {
               this.$message.success("反关闭成功");
+              this.operation(this.steelMap);
               this.getSteelReport();
             } else {
               this.$message.error("反关闭失败");
+              this.operation(this.steelMap);
               this.getSteelReport();
             }
           })
@@ -636,17 +844,17 @@ export default {
     },
     changeScreen() {},
     //承运商弹出层
-    handleSelectCarrier(row, index, item) {
+    handleSelectCarrier() {
       this.carrierList.forEach(item => {
-        if (item.carrierName == row.carrierName) {
-          row.newCarrierId = item.carrierId;
-          row.carrierId = item.carrierId;
+        if (item.carrierName == this.steelMap.carrierName) {
+          this.steelMap.newCarrierId = item.carrierId;
+          this.steelMap.carrierId = item.carrierId;
         }
       });
     },
     //承运商边输边查
     querySearchCarrier(queryString, cb) {
-      if (queryString.length > 1) {
+      if (queryString != null && queryString != "" && queryString.length > 1) {
         this.axios
           .post("/api/v1/uc/getCarrierMesByLike?index=" + queryString)
           .then(res => {
@@ -676,7 +884,7 @@ export default {
     },
     //以下是车牌号边输边查搜索
     querySearch(queryString, cb) {
-      if (queryString.length > 3) {
+      if (queryString != null && queryString != "" && queryString.length > 3) {
         this.axios
           .post("/api/v1/uc/getCapacityByLike?index=" + queryString)
           .then(res => {
@@ -706,24 +914,24 @@ export default {
       };
     },
     //车牌号弹出层
-    handleSelect(row, index) {
+    handleSelect() {
       this.capacityList.forEach(item => {
-        if (item.capacityNumber === row.capacityNo) {
-          row.newsCapacityId = item.capacityId;
+        if (item.capacityNumber === this.steelMap.capacityNo) {
+          this.steelMap.newsCapacityId = item.capacityId;
         }
       });
     },
-    updateCapacity(row) {
-      row.capacityId = row.newsCapacityId;
-      if (row.newsCapacityId == null) {
+    updateCapacity() {
+      this.steelMap.capacityId = this.steelMap.newsCapacityId;
+      if (this.steelMap.newsCapacityId == null) {
         this.$message.warning("请先注册车牌号或者选中弹出后再提交!");
         return;
       }
-      if (!isVehicleNumber(row.capacityNo)) {
+      if (!isVehicleNumber(this.steelMap.capacityNo)) {
         this.$message.error("请输入正确格式的车牌号!");
         return;
       }
-      if (row.capacityIds != 0) {
+      if (this.steelMap.capacityIds != 0) {
         const loading = this.$loading({
           lock: true,
           text: "正在变更车牌号",
@@ -731,42 +939,39 @@ export default {
           background: "rgba(0, 0, 0, 0.7)"
         });
         this.axios
-          .post("/api/v1/ams/updateCapacityNumberInFactory", row)
+          .post("/api/v1/ams/updateCapacityNumberInFactory", this.steelMap)
           .then(res => {
             if (res.data.code == 200) {
               this.$message.success("变更车牌号成功!");
+              this.operation(this.steelMap);
               this.getSteelReport();
               loading.close();
             } else {
               this.$message.success("变更失败,请联系管理员");
+              this.operation(this.steelMap);
               this.getSteelReport();
               loading.close();
             }
           })
           .catch(() => {
             this.$message.success("变更失败,请联系管理员");
+            this.operation(this.steelMap);
             this.getSteelReport();
             loading.close();
           });
       } else {
-        if (row.carrierIds == 0) {
+        if (this.steelMap.carrierIds == 0) {
           this.$message.error("请先选择承运商!");
           return;
         }
-        let i = 0;
-        this.tableData.forEach(e => {
-          if (row.group == e.group) {
-            i++;
-          }
-        });
-        row.lineId = this.lineSpelling[i];
-        row.driverTel = row.capacityTel;
-        row.capacityNumber = row.capacityNo;
+        this.steelMap.lineId = this.lineSpelling[this.steelMap.mapList.length];
+        this.steelMap.driverTel = this.steelMap.capacityTel;
+        this.steelMap.capacityNumber = this.steelMap.capacityNo;
         let arr = [];
-        arr.push(row);
+        arr.push(this.steelMap);
         const loading = this.$loading({
           lock: true,
-          text: "正在变更车牌号",
+          text: "正在派车,请稍候",
           spinner: "el-icon-loading",
           background: "rgba(0, 0, 0, 0.7)"
         });
@@ -775,92 +980,107 @@ export default {
           .then(res => {
             if (res.data.code == "200") {
               this.$message.success("派车成功!");
+              this.operation(this.steelMap);
               this.getSteelReport();
               loading.close();
             } else {
               this.$message.error("派车失败,请联系管理员");
               this.getSteelReport();
+              this.operation(this.steelMap);
               loading.close();
             }
           })
           .catch(() => {
             this.$message.error("派车失败,请联系管理员");
+            this.operation(this.steelMap);
             this.getSteelReport();
             loading.close();
           });
       }
     },
     //修改司机电话号码
-    updateDriverTel(row) {
+    updateDriverTel() {
       const loading = this.$loading({
         lock: true,
         text: "修改电话号码中",
         spinner: "el-icon-loading",
         background: "rgba(0, 0, 0, 0.7)"
       });
-      if (row.capacityTel == null || row.capacityTel == "") {
+      if (
+        this.steelMap.capacityTel == null ||
+        this.steelMap.capacityTel == ""
+      ) {
         this.$message.error("电话号码不能为空");
         return;
       }
       this.axios
         .post("/api/v1/uc/updateDriverTel", {
-          orderId: parseInt(row.orderId),
-          driverTel: row.capacityTel
+          orderId: parseInt(this.steelMap.orderId),
+          driverTel: this.steelMap.capacityTel
         })
         .then(res => {
           if (res.data.code == "200") {
             this.$message.success("修改成功");
+            this.operation(this.steelMap);
             this.getSteelReport();
             loading.close();
           } else {
             this.$message.error("修改失败");
+            this.operation(this.steelMap);
             this.getSteelReport();
             loading.close();
           }
         })
         .catch(() => {
           this.$message.error("修改失败");
+          this.operation(this.steelMap);
           this.getSteelReport();
           loading.close();
         });
     },
     //修改收货客户电话
-    updateconsigneeTel(row) {
+    updateconsigneeTel() {
       const loading = this.$loading({
         lock: true,
         text: "修改电话号码中",
         spinner: "el-icon-loading",
         background: "rgba(0, 0, 0, 0.7)"
       });
-      if (row.consigneeTel == null || row.consigneeTel == "") {
+      if (
+        this.steelMap.consigneeTel == null ||
+        this.steelMap.consigneeTel == ""
+      ) {
         this.$message.error("电话号码不能为空");
         return;
       }
       this.axios
         .post("/api/v1/ams/updateConsigneeTel", {
-          saleOrderNo: row.saleOrderNo,
-          saleMaterialId: row.saleMaterialId,
-          consigneeTel: row.consigneeTel
+          saleOrderNo: this.steelMap.saleOrderNo,
+          saleOrderMaterialId: this.steelMap.saleOrderMaterialId,
+          consigneeTel: this.steelMap.consigneeTel
         })
         .then(res => {
           if (res.data.code == "200") {
             this.$message.success("修改成功");
+            this.operation(this.steelMap);
             this.getSteelReport();
             loading.close();
           } else {
             this.$message.error("修改失败");
+            this.operation(this.steelMap);
             this.getSteelReport();
             loading.close();
           }
         })
         .catch(() => {
           this.$message.error("修改失败");
+          this.operation(this.steelMap);
           this.getSteelReport();
           loading.close();
         });
     },
     //关闭车辆金蝶分录
-    deleteEasEntryId(row) {
+    deleteEasEntryId() {
       this.$confirm("确定关闭该车金蝶分录吗?", "提示", {
         confirmButtonText: "是",
         cancelButtonText: "否",
@@ -868,7 +1088,8 @@ export default {
         type: "warning"
       })
         .then(() => {
-          let map = row;
+          let map = this.steelMap;
+          map.operateName = getCookie("loginName");
           map.isCloseEas = Number(0);
           const loading = this.$loading({
             lock: true,
@@ -882,15 +1103,18 @@ export default {
               if (res.data.code == "200") {
                 this.$message.success("关闭车辆成功");
                 this.getSteelReport();
+                this.operation(this.steelMap);
                 loading.close();
               } else {
                 this.$message.error("关闭车辆失败");
+                this.operation(this.steelMap);
                 this.getSteelReport();
                 loading.close();
               }
             })
             .catch(() => {
               this.$message.error("关闭车辆失败");
+              this.operation(this.steelMap);
               this.getSteelReport();
               loading.close();
             });
@@ -900,13 +1124,14 @@ export default {
         });
     },
     //修改承运商授权
-    updateTruckCarrier(row) {
-      if (row.newCarrierId == null) {
+    updateTruckCarrier() {
+      console.log(this.steelMap);
+      if (this.steelMap.newCarrierId == null) {
         this.$message.warning("请注册承运商或者选中弹出层之后再提交!");
         this.getSteelReport();
         return;
       }
-      if (row.carrierIds != 0) {
+      if (this.steelMap.carrierIds != 0) {
         const loading = this.$loading({
           lock: true,
           text: "正在修改承运商授权",
@@ -914,27 +1139,30 @@ export default {
           background: "rgba(0, 0, 0, 0.7)"
         });
         this.axios
-          .post("/api/v1/ams/updateTruckNoCarrier", row)
+          .post("/api/v1/ams/updateTruckNoCarrier", this.steelMap)
           .then(res => {
             if (res.data.code == "200") {
               this.$message.success("修改承运商授权成功");
+              this.operation(this.steelMap);
               this.getSteelReport();
               loading.close();
             } else {
               this.$message.error("修改失败,请联系管理员!");
+              this.operation(this.steelMap);
               this.getSteelReport();
               loading.close();
             }
           })
           .catch(() => {
             this.$message.error("修改失败,请联系管理员!");
+            this.operation(this.steelMap);
             this.getSteelReport();
             loading.close();
           });
       } else {
         //授权承运商
         let arr = [];
-        arr.push(row);
+        arr.push(this.steelMap);
         const loading = this.$loading({
           lock: true,
           text: "正在授权承运商",
@@ -944,18 +1172,21 @@ export default {
         this.axios
           .post("/api/v1/ams/dispatchToCarrier", arr)
           .then(res => {
-            if (res.data.code == "200") {
+            if (res.data.code == "0") {
               this.$message.success("授权承运商成功");
+              this.operation(this.steelMap);
               this.getSteelReport();
               loading.close();
             } else {
               this.$message.error("授权失败,请联系管理员");
+              this.operation(this.steelMap);
               this.getSteelReport();
               loading.close();
             }
           })
           .catch(() => {
             this.$message.error("授权失败,请联系管理员");
+            this.operation(this.steelMap);
             this.getSteelReport();
             loading.close();
           });
@@ -1066,20 +1297,20 @@ export default {
         .then(res => {
           if (res.data.code == "200") {
             this.$message.success("修改收货地址成功!");
+            this.operation(this.steelMap);
             this.getSteelReport();
-            this.drawer = false;
             loading.close();
           } else {
             this.$message.error("修改失败,请联系管理员!");
+            this.operation(this.steelMap);
             this.getSteelReport();
-            this.drawer = false;
             loading.close();
           }
         })
         .catch(() => {
           this.$message.error("修改失败,请联系管理员!");
+          this.operation(this.steelMap);
           this.getSteelReport();
-          this.drawer = false;
           loading.close();
         });
     },
@@ -1135,9 +1366,9 @@ export default {
       let arr = [];
       arr.push(map);
       let updateMap = {
-        orderId: row.orderId,
-        saleOrderId: row.saleOrderId,
-        saleOrderMaterialId: row.saleOrderMaterialId,
+        orderId: this.steelMap.orderId,
+        saleOrderId: this.steelMap.saleOrderId,
+        saleOrderMaterialId: this.steelMap.saleOrderMaterialId,
         mapList: arr
       };
       this.axios
@@ -1161,7 +1392,10 @@ export default {
     },
     //关闭单条分录
     closeEasEntryId(row) {
-      console.log(row);
+      if (this.steelMap.mapList.length == 1) {
+        this.deleteEasEntryId();
+        return;
+      }
       this.$prompt("确定关闭该条分录吗?", "警告", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
@@ -1177,11 +1411,11 @@ export default {
               background: "rgba(0, 0, 0, 0.7)"
             });
             let map = {
-              orderId: row.orderId,
-              saleOrderMaterialId: row.saleOrderMaterialId,
+              orderId: this.steelMap.orderId,
+              saleOrderMaterialId: this.steelMap.saleOrderMaterialId,
               saleMaterialId: row.saleMaterialId,
               reason: value,
-              number: row.saleOrderNo,
+              number: this.steelMap.saleOrderNo,
               closeEntryId: row.closeEntryId
             };
             this.axios
@@ -1189,16 +1423,19 @@ export default {
               .then(res => {
                 if (res.data.code == "200") {
                   this.$message.success("关闭成功");
+                  this.operation(this.steelMap);
                   this.getSteelReport();
                   loading.close();
                 } else {
                   this.$message.error("关闭失败,请联系管理员");
+                  this.operation(this.steelMap);
                   this.getSteelReport();
                   loading.close();
                 }
               })
               .catch(() => {
                 this.$message.error("关闭失败,请联系管理员");
+                this.operation(this.steelMap);
                 this.getSteelReport();
                 loading.close();
               });
@@ -1237,6 +1474,15 @@ export default {
       } else {
         remark = this.input;
       }
+      if (this.screen1 == "下单客户") {
+        consigneeName = this.input1;
+      } else if (this.screen == "承运商") {
+        carrierName = this.input1;
+      } else if (this.screen == "车牌号") {
+        capacityNo = this.input1;
+      } else {
+        remark = this.input1;
+      }
       this.axios
         .post(
           "/api/v1/tms/getSaleSteelReport?startTime=" +
@@ -1296,6 +1542,15 @@ export default {
       } else {
         remark = this.input;
       }
+      if (this.screen1 == "下单客户") {
+        consigneeName = this.input1;
+      } else if (this.screen == "承运商") {
+        carrierName = this.input1;
+      } else if (this.screen == "车牌号") {
+        capacityNo = this.input1;
+      } else {
+        remark = this.input1;
+      }
       if (getCookie("orgCode") == "chengyunshang") {
         carrierSsoId = getCookie("userId");
       }
@@ -1325,6 +1580,16 @@ export default {
         )
         .then(res => {
           this.tableData = res.data.data;
+
+          // { text: '专用线', value: '专用线' }
+          // { text: '达州站', value: '达州站' }
+          // this.consigneeFiltList = this.tableData.forEach(e => {
+          //   let map = {};
+          //   map.text = e.consigneeName;
+          //   map.value = e.consigneeName;
+          //   return map;
+          // });
+
           this.getSpanArr(res.data.data);
         });
     }
@@ -1361,6 +1626,7 @@ export default {
         }
       }
       .steelMapClass2 {
+        margin-top: 20px;
         display: flex;
         flex-direction: row;
         justify-content: flex-start;
@@ -1378,6 +1644,67 @@ export default {
           }
         }
       }
+      .steelMapClass3 {
+        margin-top: 20px;
+        display: flex;
+        flex-direction: row;
+        justify-content: flex-start;
+        align-items: flex-start;
+        font-size: 16px;
+        .steelMapClass32 {
+          margin-left: 50px;
+          margin-right: 10px;
+        }
+        .steelMapClass33 {
+          margin-left: 40px;
+          margin-right: 10px;
+        }
+      }
+      .steelMapClass4 {
+        margin-top: 20px;
+        display: flex;
+        flex-direction: row;
+        justify-content: flex-start;
+        align-items: flex-start;
+        font-size: 16px;
+
+        .steelMapClass42 {
+          margin-left: 50px;
+          margin-right: 10px;
+        }
+        .steelMapClass43 {
+          margin-left: 50px;
+          margin-right: 10px;
+        }
+      }
+      .steelMapClass5 {
+        margin-top: 20px;
+        display: flex;
+        flex-direction: row;
+        justify-content: flex-start;
+        align-items: flex-start;
+        font-size: 16px;
+
+        .steelMapClass52 {
+          margin-left: 50px;
+          margin-right: 10px;
+          .steelMapClass521 {
+            margin-left: 20px;
+          }
+        }
+      }
+      .steelMapClass6 {
+        margin-top: 20px;
+        display: flex;
+        flex-direction: row;
+        justify-content: flex-start;
+        align-items: flex-start;
+        font-size: 16px;
+        .steelMapClass62 {
+          margin-left: 50px;
+          margin-right: 10px;
+        }
+      }
     }
   }
   .address {