Browse Source

前端火运sdy

zhongtianhaoyuan 4 years ago
parent
commit
0868ebe72f

+ 9 - 0
src/api/V2/transport/index.js

@@ -26,3 +26,12 @@ export const API_GET_PRAAMETER = '/commonSysParameter/getInfo'
 export const API_POST_TRAN_LOOK = '/tranTaskInfo/getTranTask'
 // 汽运调度列表
 export const API_GET_AUTOMOBILE_TRAN_LIST = '/tranProcessInfo/selectTranProcessInfo'
+
+//派车
+export const API_POST_AUTOMOBILE_DISPATCH= "/tranCarInfo/api/insertTranCar"
+//派车查看
+export const API_GET_AUTOMOBILE_SEE = "/tranProcessInfo/getTranProcess"
+//派车查看下拉姓名
+export const API_GET_AUTOMOBILE_NAME = "/driverViewInfo/selectDriverName"
+//派车查看联络员及车次
+export const API_GET_AUTOMOBILE_ARRANGE = "/driverViewInfo/selectDriverDetail"

+ 7 - 2
src/lang/zh.js

@@ -519,6 +519,8 @@
     tranManagementVehicleDispatching: '汽车调度',
     tranManagementVehicleLook: '查看派车详情',
     tranManagementTransporTationFire: '火运调度',
+    tranManagementTransporTrainNo: '车次安排',
+    tranManagementTransporTrainDetails: '火运调度详情',
 
     // 采购模块
     procurement: '采购管理',
@@ -4720,7 +4722,8 @@
     tranManagementDriver: '司机管理',
     tranManagementDriverAdd: '添加司机',
     tranManagementDriverLook: '查看司机',
-    tranManagementDriverEdit: '编辑司机'
+    tranManagementDriverEdit: '编辑司机',
+ 
   },
   tranManagementTransport: {
     tranManagementTransport: '运输任务',
@@ -4734,7 +4737,9 @@
     tranManagementVehicleLook: '查看派车详情',
   },
   tranManagementTransporTationFire: {
-    tranManagementTransporTationFire: '火运调度'
+    tranManagementTransporTationFire: '火运调度',
+    tranManagementTransporTrainNo: '车次安排',
+    tranManagementTransporTrainDetails: '火运调度详情',
   },
   // 任务管理
   tranManagement: '任务管理',

+ 1 - 1
src/model/tasksport/index.js

@@ -17,4 +17,4 @@ export const getidentity = appRx.get(API_POST_PERSON, errorCatcher, errorHandle,
 //运输任务查看
 export const lookTranTask = appRx.get(API_POST_TRAN_LOOK, errorCatcher, errorHandle, filter)
 //运输任务-添加-根据仓库类型选库名
-export const getwarehousename = appRx.get(API_GET_TRAN_TASK_WAREHOUSE, errorCatcher, errorHandle, filter)
+export const getwarehousename = appRx.get(API_GET_TRAN_TASK_WAREHOUSE, errorCatcher, errorHandle, filter)

+ 14 - 2
src/model/transport/index.js

@@ -16,7 +16,11 @@ import {
     API_POST_EDIT_DRIVER,
     API_GET_PRAAMETER,
     API_POST_TRAN_LOOK,
-    API_GET_AUTOMOBILE_TRAN_LIST
+    API_GET_AUTOMOBILE_TRAN_LIST,
+    API_POST_AUTOMOBILE_DISPATCH,
+    API_GET_AUTOMOBILE_SEE,
+    API_GET_AUTOMOBILE_ARRANGE,
+    API_GET_AUTOMOBILE_NAME,
 } from '@/api/V2/transport'
 // 司机列表
 export const selectDriver = appRx.get(API_GET_TRAN_DRIVERINFO, errorCatcher, errorHandle, filter)
@@ -47,4 +51,12 @@ export const packList = appRx.get(API_GET_PRAAMETER, errorCatcher, errorHandle,
 //运输任务查看
 export const lookTranTask = appRx.get(API_POST_TRAN_LOOK, errorCatcher, errorHandle, filter)
 //汽运调度列表
-export const automobileList = appRx.get(API_GET_AUTOMOBILE_TRAN_LIST, errorCatcher, errorHandle, filter)
+export const automobileList = appRx.get(API_GET_AUTOMOBILE_TRAN_LIST, errorCatcher, errorHandle, filter)
+//派车提交
+export const dispatchCat = appRx.post(API_POST_AUTOMOBILE_DISPATCH, errorCatcher, errorHandle, filter)
+//派车查看
+export const seeCat = appRx.get(API_GET_AUTOMOBILE_SEE, errorCatcher, errorHandle, filter)
+//派车查看姓名下拉
+export const nameXiala = appRx.get(API_GET_AUTOMOBILE_NAME, errorCatcher, errorHandle, filter)
+//派车查看联络员及车次
+export const arrange = appRx.get(API_GET_AUTOMOBILE_ARRANGE, errorCatcher, errorHandle, filter)

+ 33 - 1
src/views/tranManagement/component/routers/route.js

@@ -25,9 +25,41 @@ const tranManagementRouter = {
         permissicon: [],
         keepAlive: true
       },
+    },
+    //车次安排
+    {
+      path: 'tranManagementTransporTrainNo',
+      component: () =>
+        import(/* webpackChunkName: "applDetail" */ '@/views/tranManagement/tranManagementTransporTrainNo'),
+      name: 'tranManagementTransporTrainNo',
+      meta: {
+        title: 'tranManagementTransporTrainNo',
+        shortcutEntrance: 'tranManagement',
+        module: 'tranManagement.tranManagementDriver.tranManagementTransporTrainNo',
+        permissicon: [],
+        keepAlive: true
+      },
+      hidden: true
+    },
+     //火运调度详情
+     {
+      path: 'tranManagementTransporTrainDetails',
+      component: () =>
+        import(/* webpackChunkName: "applDetail" */ '@/views/tranManagement/tranManagementTransporTrainDetails'),
+      name: 'tranManagementTransporTrainDetails',
+      meta: {
+        title: 'tranManagementTransporTrainDetails',
+        shortcutEntrance: 'tranManagement',
+        module: 'tranManagement.tranManagementDriver.tranManagementTransporTrainDetails',
+        permissicon: [],
+        keepAlive: true
+      },
+      hidden: true
+    },
+
+
 
 
-    },
     //添加司机
     {
       path: 'tranManagementDriverAdd',

+ 87 - 193
src/views/tranManagement/tranManagementTransporTationFire.vue

@@ -1,7 +1,7 @@
 //火运调度
 <template>
   <div>
-    <BaseHeaderLayout :leftSpan="20">
+    <BaseHeaderLayout :leftSpan="12">
       <template slot="left">
         <ws-button
           class="but"
@@ -75,67 +75,31 @@
         /></ws-button>
       </template>
     </BaseHeaderLayout>
-    <div>
+    <div class="container">
       <el-table
         class="wenzi"
-        :data="warehouseList"
+        :data="tranManagementList.records"
         style="width: 100%; margin-top: 20px"
         height="780"
       >
-        <el-table-column prop="warehouseName" label="序号" width="80">
+      <el-table-column type="index" label="序号" width="80" >
+        <template scope="scope">
+          <span v-if="scope.$index < 9">0{{ scope.$index + 1 }}</span>
+          <span v-else>{{ scope.$index + 1 }}</span>
+        </template>
+      </el-table-column>
+        <el-table-column prop="processNo" label="运输任务编号" width="120">
         </el-table-column>
-        <el-table-column prop="binNumber" label="运输任务编号" width="120">
+           <el-table-column prop="goodsName" label="货名" width="80">
         </el-table-column>
-        <el-table-column prop="capacity" label="货名">
-          <template slot-scope="scope">
-            <div
-              v-if="scope.row.capacity != 'null' && scope.row.capacity != null"
-            >
-              {{ scope.row.capacity }}
-            </div>
-          </template>
+           <el-table-column prop="weight" label="重量(吨)" width="120">
         </el-table-column>
-        <el-table-column class="table_td" label="重量(吨)">
-          <template slot-scope="scope">
-            <div
-              style="height: 24px"
-              v-for="(item, i) in scope.row.warehouseNumViewList"
-            >
-              {{ item.inNetWeight }}
-            </div>
-          </template>
+           <el-table-column prop="send" label="发货" width="160">
         </el-table-column>
-        <el-table-column class="table_td" label="发货">
-          <template slot-scope="scope">
-            <div
-              style="height: 24px"
-              v-for="(item, i) in scope.row.warehouseNumViewList"
-            >
-              {{ item.outNetWeight }}
-            </div>
-          </template>
+           <el-table-column prop="receive" label="收货" width="160">
         </el-table-column>
-        <el-table-column class="table_td" label="收货">
-          <template slot-scope="scope">
-            <div
-              style="height: 24px"
-              v-for="(item, i) in scope.row.warehouseNumViewList"
-            >
-              {{ item.storage }}
-            </div>
-          </template>
+           <el-table-column prop="tranCycle" label="运输周期" width="120">
         </el-table-column>
-        <el-table-column class="table_td" label="运输周期">
-          <template slot-scope="scope">
-            <div
-              style="height: 24px"
-              v-for="(item, i) in scope.row.warehouseNumViewList"
-            >
-              {{ item.storage }}
-            </div>
-          </template>
-        </el-table-column>
-
         <el-table-column prop="status" label="状态">
           <template slot-scope="scope">
             <el-popover
@@ -188,33 +152,20 @@
             />
           </template>
         </el-table-column>
-        <el-table-column class="table_td" label="接单日期">
-          <template slot-scope="scope">
-            <div
-              style="height: 24px"
-              v-for="(item, i) in scope.row.warehouseNumViewList"
-            >
-              {{ item.storage }}
-            </div>
-          </template>
+        <el-table-column prop="receivingDate" class="table_td" label="接单日期">
         </el-table-column>
         <el-table-column prop="seller" label="操作" width="300">
           <template slot-scope="scope">
             <ws-button
               class="completed"
-              @click="nocomplete(scope.row)"
-              v-hasPermission="
-                `${$permission('PERMISSIONS.PURSPAPPLINFO_CREATEINSTORE')}`
-              "
+              @click="trainSee(scope.row)"
+             
             >
-              查看({{ scope.row.number }})
+              查看
             </ws-button>
             <ws-button
               class="putstorage"
-              @click="warehousing(scope.row)"
-              v-hasPermission="
-                `${$permission('PERMISSIONS.PURSPAPPLINFO_CREATEINSTORE')}`
-              "
+              @click="trainNumber(scope.row)"  
             >
               车次
             </ws-button>
@@ -227,11 +178,9 @@
 </template>
 <script>
 import {
-  getList,
-  export1,
-  editstatus,
-  billoperatehis,
-} from '@/model/warehouse/index'
+ automobileList,
+ dispatchCat
+} from '@/model/transport/index'
 import { downloadFile } from '@/utils/batchDown'
 import Pagination from '@/components/Pagination'
 import WsUpload from '@/components/WsUpload'
@@ -270,6 +219,7 @@ export default {
       searchTypeText: '未完成',
       searchKeyWord: '',
       contractType: 2,
+      tranTypeKey: 2,
       // 提交类型
       submitType: true,
       size: 10,
@@ -277,7 +227,7 @@ export default {
       warehouseName: '',
       compId: sessionStorage.getItem('ws-pf_compId'),
       deptCircularPage: {},
-      warehouseList: [],
+      tranManagementList: [],
       deptBudgetList: {},
       historyList: [],
       pickerBeginDateBefore: {
@@ -296,47 +246,12 @@ export default {
     this.showType = this.isShow
   },
   methods: {
-    //出库
-    delivery(item) {
-      this.$router.push({
-        path: 'warehouseManagementDelivery',
-        query: {
-          baseId: item.warehouseId,
-          positionId: item.binNumberId,
-          warehouseName: item.warehouseName,
-          binNumber: item.binNumber,
-          capacity: item.capacity,
-        },
-      })
-    },
-    //派车
-    warehousing(item) {
-      var free = 0
-      for (var i = 0; i < item.warehouseNumViewList.length; i++) {
-        free += Number(item.warehouseNumViewList[i].storage)
-      }
-      this.$router.push({
-        path: 'tranManagementVehicleDispatching',
-        query: {
-          baseId: item.warehouseId,
-          positionId: item.binNumberId,
-          warehouseName: item.warehouseName,
-          binNumber: item.binNumber,
-          capacity: item.capacity - free,
-        },
-      })
-    },
     getSpanArr(data) {
       let that = this
-
       //页面展示的数据,不一定是全部的数据,所以每次都清空之前存储的 保证遍历的数据是最新的数据。以免造成数据渲染混乱
-
       that.spanArr = []
-
       that.pos = 0
-
       //遍历数据
-
       data.forEach((item, index) => {
         //判断是否是第一项
 
@@ -357,46 +272,25 @@ export default {
         // }
       })
     },
-    //查看//传参
-    nocomplete(row) {
-      this.$router.push({
-        path: 'tranManagementVehicleLook',
-        // query: {
-        //   baseId: row.warehouseId,
-        //   positionId: row.binNumberId,
-        //   warehouseName: row.warehouseName,
-        //   binNumber: row.binNumber,
-        // },
-      })
-    },
-    //记录
-    record(item) {
+    //查看火运调度详细
+    trainSee(row) {
       this.$router.push({
-        name: 'warehouseManagementRecord',
-        query: {
-          baseId: item.warehouseId,
-          positionId: item.binNumberId,
-          warehouseName: item.warehouseName,
-        },
-        params: {
-          remark: item.remark,
-          binNumber: item.binNumber,
-          capacity: item.capacity,
-        },
+        path: 'tranManagementTransporTrainDetails',
+        query:{
+          id:row.id
+        }
       })
     },
-    //盘损
-    loss(item) {
+    //车次
+    trainNumber(row) {
       this.$router.push({
-        path: 'warehouseManagementIoss',
-        query: {
-          baseId: item.warehouseId,
-          positionId: item.binNumberId,
-          warehouseName: item.warehouseName,
-          binNumber: item.binNumber,
-        },
+        path: 'tranManagementTransporTrainNo',
+        query:{
+          id : row.id
+        }
       })
     },
+   
     //查看
     handleLook() {
       this.$router.push({ path: 'tranManagementVehicleLook' })
@@ -409,10 +303,7 @@ export default {
     handleEdit() {
       this.$router.push({ path: 'tranManagementTransportEdit' })
     },
-    // 派车
-    warehousing() {
-      this.$router.push({ path: 'tranManagementVehicleDispatching' })
-    },
+
     dateFormat(fmt, date) {
       let ret
       const opt = {
@@ -448,14 +339,17 @@ export default {
       console.log(`当前页: ${val}`)
       this.getList()
     },
-    getList() {
-      getList({
+     getList() {
+      automobileList({
         compId: sessionStorage.getItem('ws-pf_compId'),
-        warehouseName: this.warehouseName,
+        contractType: this.contractType,
+        currentPage: this.currentPage,
+        pageSize: this.pageSize,
+        tranTypeKey:this.tranTypeKey
       })
         .toPromise()
         .then((response) => {
-          this.warehouseList = response
+          this.tranManagementList = response
         })
     },
     editClick(row) {
@@ -531,34 +425,34 @@ export default {
       this.currentPage = 1
       this.getList()
     },
-    async exportlist() {
-      const { data } = await export1(
-        {
-          compId: sessionStorage.getItem('ws-pf_compId'),
-          contractType: this.contractType,
-          currentPage: this.currentPage,
-          pageSize: this.pageSize,
-          searchType: this.searchType,
-          searchKeyWord: this.searchKeyWord,
-          startDate: this.startDate,
-          endDate: this.endDate,
-        },
-        {},
-        { responseType: 'blob' }
-      ).toPromise()
-      downloadFile({
-        res: data,
-        fileName: `${
-          this.date.year + (this.date.month ? `-${this.date.month}` : '')
-        }_采购合同`,
-        type: 'xls',
-      })
-    },
+    // async exportlist() {
+    //   const { data } = await export1(
+    //     {
+    //       compId: sessionStorage.getItem('ws-pf_compId'),
+    //       contractType: this.contractType,
+    //       currentPage: this.currentPage,
+    //       pageSize: this.pageSize,
+    //       searchType: this.searchType,
+    //       searchKeyWord: this.searchKeyWord,
+    //       startDate: this.startDate,
+    //       endDate: this.endDate,
+    //     },
+    //     {},
+    //     { responseType: 'blob' }
+    //   ).toPromise()
+    //   downloadFile({
+    //     res: data,
+    //     fileName: `${
+    //       this.date.year + (this.date.month ? `-${this.date.month}` : '')
+    //     }_采购合同`,
+    //     type: 'xls',
+    //   })
+    // },
   },
 }
 </script>
 <style lang="scss" scoped>
-.connert {
+.container {
   width: 90%;
   margin: 0 auto;
 }
@@ -604,23 +498,23 @@ export default {
 /deep/.el-table tr th.is-leaf:first-child {
   border-left: 1px solid #e9ecf7;
 }
-.record,
-.adjustment {
-  display: inline-block;
-  color: #5878e8;
-  padding: 0 4px !important;
-  position: relative;
-}
-.record:after {
-  position: absolute;
-  content: '';
-  display: block;
-  top: 5px;
-  right: -2px;
-  width: 1px;
-  height: 12px;
-  background: #e9ecf7;
-}
+// .record,
+// .adjustment {
+//   display: inline-block;
+//   color: #5878e8;
+//   padding: 0 4px !important;
+//   position: relative;
+// }
+// .record:after {
+//   position: absolute;
+//   content: '';
+//   display: block;
+//   top: 5px;
+//   right: -2px;
+//   width: 1px;
+//   height: 12px;
+//   background: #e9ecf7;
+// }
 .el-row {
   height: 150px;
 }

+ 837 - 0
src/views/tranManagement/tranManagementTransporTrainDetails.vue

@@ -0,0 +1,837 @@
+//火运调度详情
+<template>
+  <div class="container">
+    <el-row>
+      <el-col :span="12">
+        <h2 class="bg-left title">火运调度详情</h2>
+      </el-col>
+      <el-col :span="12" class="bg-right">
+        <el-button
+          class="bg-bottom"
+          type="primary"
+          size="small"
+          @click="returnsales()"
+          ><img
+            width="6"
+            height="10"
+            style="vertical-align: bottom; margin-right: 3px"
+            src="../../../public/img/lujing.png"
+            alt=""
+          />返回</el-button
+        >
+      </el-col>
+    </el-row>
+
+    <ws-form
+      class="position"
+      ref="deptBudgetList"
+      :rules="rules"
+      :model="deptBudgetList"
+    >
+      <div class="small-title">任务详情</div>
+      <ws-info-table>
+        <!--任务编号-->
+        <ws-form-item label="任务编号" span="1" prop="processNo">
+          <ws-input
+            v-model="deptBudgetList.processNo"
+            placeholder="请输入任务编号"
+            maxlength="20"
+            size="small"
+          />
+        </ws-form-item>
+        <!--货名-->
+        <ws-form-item label="货名" span="1" prop="goodsName">
+          <!-- <el-select
+            v-model="deptBudgetList.goodsName"
+            placeholder="请选择货名"
+            filterable
+            :filter-method="dataFilter"
+            @change="selectstaff"
+          >
+            <el-option
+              v-for="item in personCharge"
+              :key="item.value"
+              :label="item.staffName"
+              :value="item.staffName"
+            /> -->
+             <ws-input
+            v-model="deptBudgetList.goodsName"
+            placeholder="请输入货名"
+            maxlength="20"
+            size="small"
+          />
+          <!-- </el-select> -->
+        </ws-form-item>
+        <!--重量(吨)-->
+        <ws-form-item label="重量(吨)" span="1" prop="weight">
+          <ws-input
+            v-model="deptBudgetList.weight"
+            placeholder="请输入重量(吨)"
+            maxlength="100"
+            size="small"
+          />
+        </ws-form-item>
+
+        <!--发货地址-->
+        <ws-form-item label="发货地址" span="1" prop="sendDetailedAddress">
+           <!-- <ws-input
+            v-model="deptBudgetList.sendDetailedAddress"
+            placeholder=""
+            maxlength="100"
+            size="small"
+          /> -->
+          {{deptBudgetList.sendPrivate}}{{deptBudgetList.sendCity}}{{deptBudgetList.sendArea}}
+        </ws-form-item>
+
+        <!--发货人-->
+        <ws-form-item label="发货人" span="1" prop="sender" class="readonly"
+        >
+          <ws-input
+            v-model="deptBudgetList.sender"
+            placeholder="请输入发货人"
+            maxlength="100"
+            size="small"
+          />
+        </ws-form-item>
+
+        <!--发货人电话-->
+        <ws-form-item label="发货人电话" span="1" prop="senderPhone" class="readonly"
+        >
+          <ws-input
+            v-model="deptBudgetList.senderPhone"
+            placeholder="请输入发货人电话"
+            maxlength="100"
+            size="small"
+          />
+        </ws-form-item>
+        <!--收货地址-->
+        <ws-form-item label="收货地址" span="1" prop="receiveDetailedAddress">
+          <!-- <ws-input
+            v-model="deptBudgetList.receiveDetailedAddress"
+            placeholder="请输入仓库名"
+            maxlength="20"
+            size="small"
+          /> -->
+          {{deptBudgetList.receivePrivate}}{{deptBudgetList.receiveCity}}{{deptBudgetList.receiveArea}}
+        </ws-form-item>
+        <!--收货人-->
+        <ws-form-item label="收货人" span="1" prop="receiver">
+          <ws-input
+            v-model="deptBudgetList.receiver"
+            placeholder="请输入仓库名"
+            maxlength="20"
+            size="small"
+          />
+        </ws-form-item>
+        <!--收货人电话-->
+        <ws-form-item label="收货人电话" span="1" prop="receiverPhone">
+          <ws-input
+            v-model="deptBudgetList.receiverPhone"
+            placeholder="请输入仓库名"
+            maxlength="20"
+            size="small"
+          />
+        </ws-form-item>
+        <!--发货日期-->
+        <ws-form-item label="发货日期" span="1" prop="deliveryDateStart">
+          <ws-input
+            v-model="deptBudgetList.deliveryDateStart"
+            placeholder="请输入仓库名"
+            maxlength="20"
+            size="small"
+          />
+        </ws-form-item>
+        <!--最晚到货日期-->
+        <ws-form-item label="最晚到货日期" span="1" prop="deliveryDateEnd">
+          <ws-input
+            v-model="deptBudgetList.deliveryDateEnd"
+            placeholder="请输入仓库名"
+            maxlength="20"
+            size="small"
+          />
+        </ws-form-item>
+        <!--合同编号-->
+        <ws-form-item label="合同编号" span="1" prop="contractNo">
+          <ws-input
+            v-model="deptBudgetList.contractNo"
+            placeholder="请输入合同编号"
+            maxlength="20"
+            size="small"
+          />
+        </ws-form-item>
+      </ws-info-table>
+      <div class="small-title">联络员及车次</div>
+      <div
+        style="width: 100%"
+        class="flex position"
+        v-for="(item, index) in freightspace"
+      >
+        <ws-info-table>
+          <!--姓名-->
+          <ws-form-item label="姓名" span="1" prop="driver">
+            <ws-input
+              v-model="deptBudgetList.driver"
+              placeholder="请输入姓名"
+              maxlength="20"
+              size="small"
+            />
+          </ws-form-item>
+          <!--电话-->
+          <ws-form-item label="电话" span="1" prop="driverPhone">
+            <ws-input
+              v-model="deptBudgetList.driverPhone"
+              placeholder="请输入电话"
+              maxlength="20"
+              size="small"
+            />
+          </ws-form-item>
+          <!--发车日期-->
+          <ws-form-item label="发车日期" span="1" prop="sendDateStart">
+            <ws-input
+              v-model="deptBudgetList.sendDateStart"
+              placeholder="请输入发车日期"
+              maxlength="20"
+              size="small"
+            />
+          </ws-form-item>
+          <!--到站日期-->
+          <ws-form-item label="到站日期" span="1" prop="receiveDateEnd">
+            <ws-input
+              v-model="deptBudgetList.receiveDateEnd"
+              placeholder="请输入到站日期"
+              maxlength="20"
+              size="small"
+            />
+          </ws-form-item>
+          <!--车次-->
+          <ws-form-item label="车次" span="1" prop="trainNo">
+            <ws-input
+              v-model="deptBudgetList.trainNo"
+              placeholder="请输入车次"
+              maxlength="20"
+              size="small"
+            />
+          </ws-form-item>
+          <!-- 加减号 -->
+          <img
+            width="22"
+            height="22"
+            class="add"
+            @click="add"
+            src="../../../public/img/add.png"
+            alt=""
+          />
+          <img
+            width="22"
+            height="22"
+            class="del"
+            @click="del(index)"
+            src="../../../public/img/del.png"
+            alt=""
+          />
+        </ws-info-table>
+      </div>
+    </ws-form>
+
+    <!-- 提交 -->
+    <div style="text-align: right; padding: 10px" class="center">
+      <el-button
+        class="bg-bottom"
+        type="primary"
+        size="small"
+        @click="returnsales()"
+        >关闭</el-button
+      >
+    </div>
+  </div>
+</template>
+<script>
+import { regionData, CodeToText, TextToCode } from 'element-china-area-data'
+import { seeCat } from '@/model/transport/index'
+import WsUpload from '@/components/WsUpload'
+import mapDrag from '@/components/mapdrag/mapdrag'
+export default {
+  name: 'viewSpareMoney',
+  components: {
+    WsUpload,
+    mapDrag,
+  },
+  watch: {
+    vesselId(val) {
+      this.getVesselData()
+    },
+    isShow(val) {
+      this.showType = val
+    },
+  },
+  data() {
+    let self = this
+    return {
+      staffList: [],
+      deptBudgetList: {
+        totalStorage: 0,
+      },
+      options_: regionData,
+      heightData: '600px',
+      zoom: 7,
+      selectedOptions: [],
+      center: [116.244694, 39.517344],
+      window: '',
+      radio: 1,
+      personCharge: [],
+      district: null,
+      listDate: { country: '中国', level: 'country', city: '' },
+      citylist: [],
+      compId: sessionStorage.getItem('ws-pf_compId'),
+      rules: {
+        warehouseName: [
+          {
+            required: true,
+            message: '请输入仓库名称',
+            trigger: 'blur',
+          },
+          {
+            min: 2,
+            max: 20,
+            message: '仓库名长度不符合要求,请输入2-20字符之内',
+            trigger: 'blur',
+          },
+        ],
+      },
+      appendixIdsAdd: '',
+      size: 10,
+      value1: '',
+      unitList: [],
+      freightspace: [{ driver: '', driverPhone: '', sendDateStart: '', receiveDateEnd: '', trainNo: '' }],
+      name: '',
+      list: [],
+    }
+  },
+  // mounted() {
+  //   this.getList()
+  // },
+  computed: {
+    totalStorage: function () {
+      var maxStorage = 0
+      for (var i = 0; i < this.freightspace.length; i++) {
+        maxStorage += Number(this.freightspace[i].maxStorage)
+      }
+      return maxStorage
+    },
+  },
+  activated(){
+    this.deptBudgetList.id = this.$route.query.id
+    this.getList()
+  },
+  methods: {
+    //联系人下拉搜索
+    // dataFilter(val) {
+    //   this.deptBudgetList.personCharge = val
+    //   if (val) {
+    //     console.log(val)
+    //     this.options = this.staffList.filter((item) => {
+    //       if (
+    //         !!~item.staffName.indexOf(val) ||
+    //         !!~item.staffName.toUpperCase().indexOf(val.toUpperCase())
+    //       ) {
+    //         return true
+    //       }
+    //     })
+    //   } else {
+    //     this.options = this.staffList
+    //   }
+    // },
+    // selectstaff(e) {
+    //   for (var i = 0; i < this.staffList.length; i++) {
+    //     if (this.staffList[i].staffName == e) {
+    //       this.deptBudgetList.personPhone = this.staffList[i].staffMobilePhone
+    //       this.deptBudgetList.personChargeKey = this.staffList[i].staffId
+    //     }
+    //   }
+    // },
+    marker: function (item) {
+      this.deptBudgetList.warehousePositioning =
+        item.lnglat.lat + ',' + item.lnglat.lng
+    },
+    selectedAddress(e) {
+      this.deptBudgetList.warehousePositioning =
+        e.center.lat + ',' + e.center.lng
+    },
+    confirmPositioncity() {
+      this.listDate.level = 'city'
+      this.listDate.country = this.name
+    },
+    // 关闭 dialog时 处理文件url 初始化upload组件
+    handleClose() {
+      this.dialogViewSpareMoney = false
+    },
+    add() {
+      this.freightspace.push({
+        binNumber: '',
+        maxStorage: '',
+        remark: '',
+      })
+    },
+    del(index) {
+      if (this.freightspace.length > 1) {
+        this.freightspace.splice(index, 1)
+      }
+    },
+    handleChange(value) {
+      this.selectedOptions = value
+    },
+    returnsales() {
+      this.deptBudgetList = {}
+      this.freightspace = {}
+      this.selectedOptions = ''
+      this.$router.push({ path: 'tranManagementTransporTationFire' })
+    },
+    // confirmPosition() {
+    //   this.draggable = false
+    // },
+    // 上传附件
+    uploadSuccess(data, files, url) {
+      console.log(data, files, url)
+    },
+    // submit() {
+    //   this.$confirm(`确定提交仓库信息?`, {
+    //     confirmButtonText: '确定',
+    //     cancelButtonText: '取消',
+    //     type: 'warning',
+    //   })
+    //     .then(() => {
+    //       this.$refs.deptBudgetList.validate((valid) => {
+    //         if (valid) {
+    //           this.deptBudgetList.compId =
+    //             sessionStorage.getItem('ws-pf_compId')
+    //           this.deptBudgetList.warehousePrivate =
+    //             CodeToText[this.selectedOptions[0]]
+    //           this.deptBudgetList.warehouseCity =
+    //             CodeToText[this.selectedOptions[1]]
+    //           this.deptBudgetList.warehouseArea =
+    //             CodeToText[this.selectedOptions[2]]
+    //           this.deptBudgetList.warehousePositionInfoList = this.freightspace
+    //           this.deptBudgetList.totalStorage = this.totalStorage
+    //           addList(this.deptBudgetList)
+    //             .toPromise()
+    //             .then((response) => {
+    //               this.$message.success('添加成功')
+    //               this.deptBudgetList = {}
+    //               this.freightspace = {}
+    //               this.selectedOptions = ''
+    //               this.$router.push({ path: 'warehouseManagementList' })
+    //             })
+    //         } else {
+    //           // EventBus.$emit('error', this.$t('showMessage.asteriskRequired'))
+    //           return false
+    //         }
+    //       })
+    //     })
+    //     .catch(() => {
+    //       return false
+    //     })
+    // },
+    resetForm(deptBudgetList) {
+      this.$refs[deptBudgetList].resetFields()
+    },
+
+    getList() {
+      seeCat({ id : this.deptBudgetList.id })
+        .toPromise()
+        .then((response) => {
+          this.deptBudgetList = response
+        })
+    },
+    handleExamine() {},
+    approve() {},
+    // returnsales() {
+    //   this.$router.push({ path: 'purchaseContract' })
+    // },
+    selectChapterTwo(e) {
+      for (var i = 0; i < this.ChapterTwoList.length; i++) {
+        if (this.ChapterTwoList[i].constValue == e) {
+          this.deptBudgetList.gradeKey = this.ChapterTwoList[i].constKey
+        }
+      }
+    },
+    selectunitList(e) {
+      for (var i = 0; i < this.unitList.length; i++) {
+        if (this.unitList[i].constValue == e) {
+          this.deptBudgetList.acceptanceMethodKey = this.unitList[i].constKey
+        }
+      }
+    },
+    selectgrade(e) {
+      for (var i = 0; i < this.gradeList.length; i++) {
+        if (this.gradeList[i].constValue == e) {
+          this.deptBudgetList.gradeKey = this.gradeList[i].constKey
+        }
+      }
+    },
+    selectgoodsName(e) {
+      for (var i = 0; i < this.goodnameList.length; i++) {
+        if (this.goodnameList[i].constValue == e) {
+          this.deptBudgetList.goodsNameKey = this.goodnameList[i].constKey
+        }
+      }
+    },
+    selectpackingMethod(e) {
+      for (var i = 0; i < this.packtypeList.length; i++) {
+        if (this.packtypeList[i].constValue == e) {
+          this.deptBudgetList.packingMethodKey = this.packtypeList[i].constKey
+        }
+      }
+    },
+    // 编辑
+    editClick(item, index) {
+      const map = JSON.parse(JSON.stringify(item))
+      if (Object.is(item.id, 1)) {
+        return
+      }
+      if (Object.is(this.unitList[index].flag, 'delete')) {
+        map.flag = 'check'
+        this.$set(this.unitList, index, map)
+      } else {
+        map.flag = 'delete'
+        this.$set(this.unitList, index, map)
+      }
+    },
+    // 删除
+    deleteClick(item, index) {
+      if (Object.is(item.constKey, 1)) {
+        return
+      }
+      if (!item.constValue) {
+        this.unitList.splice(index, 1)
+        return
+      }
+      delxiala({ id: this.unitList[index].id })
+        .toPromise()
+        .then((response) => {
+          this.getUnitList()
+          this.pleaseChoose = ''
+        })
+    },
+  },
+}
+</script>
+
+<style lang="scss" scoped>
+/deep/.totalStorage .el-input__inner {
+  color: #afb5cb;
+  background: #f5f7fa;
+}
+.small-title {
+  position: relative;
+  padding: 10px;
+  font-weight: 600;
+}
+.small-title::before {
+  position: absolute;
+  content: '';
+  display: block;
+  background: #5473e8;
+  width: 4px;
+  height: 14px;
+  left: 0px;
+  top: 13px;
+}
+.position {
+  position: relative;
+}
+.add,
+.del {
+  position: absolute;
+  right: -38px;
+  top: 9px;
+  cursor: pointer;
+}
+.del {
+  right: -70px;
+}
+.amap-page-container {
+  width: 300px;
+  height: 300px;
+}
+.el-form {
+  padding: 0 15%;
+}
+/deep/.ws-info-table .el-form-item {
+  border-right: 1px solid transparent;
+  border-bottom: 1px solid transparent;
+}
+.readonly {
+  position: relative;
+}
+.readonly:after {
+  content: '*';
+  color: #ff2727;
+  position: absolute;
+  right: 8px;
+  z-index: 10;
+  top: 21%;
+  font-size: 20px;
+}
+.title {
+  position: relative;
+}
+.title::before {
+  content: '';
+  display: inline-block;
+  width: 5px;
+  height: 30px;
+  background: #5473e8;
+  position: absolute;
+  left: 0;
+}
+.ws-info-table {
+  border-left: 1px solid transparent;
+  border-top: 1px solid transparent;
+}
+.el-button--primary {
+  background-color: #5878e8;
+  border-color: #5878e8;
+}
+.el-col {
+  background: #f6f7fc;
+}
+/deep/.ws-info-table .el-form-item .el-form-item__content {
+  padding: 0 25px;
+  border-left: 1px solid transparent;
+  background: #fff;
+}
+/deep/.ws-info-table .el-form-item .el-form-item__label {
+  width: 100px;
+  text-align: center;
+  background: #fff;
+  // border: 1px solid #cdd2dc;
+}
+.button-container {
+  display: flex;
+  flex-wrap: nowrap;
+  justify-content: space-between;
+  align-items: center;
+  background-color: #fff;
+  width: 100%;
+  height: 50px;
+  padding: 0 10px;
+  & > div {
+    margin-left: 10px;
+    display: flex;
+    flex-wrap: nowrap;
+    flex-direction: row;
+    & > span {
+      line-height: 50px;
+    }
+  }
+
+  /deep/.auditFlow-box {
+    position: unset;
+    margin-left: 10px;
+    &/deep/.auditFlow-icon {
+      width: auto;
+      padding-right: 30px;
+    }
+    &/deep/.auditFlow-main {
+      position: absolute;
+    }
+  }
+}
+.box-app {
+  display: inline-block;
+  float: left;
+  margin-left: 30px;
+  line-height: 50px;
+}
+/deep/.el-dialog {
+  .el-form-item {
+    margin-bottom: 0 !important;
+    .el-input--medium {
+      textarea {
+        min-height: 100px !important;
+      }
+    }
+  }
+}
+.collapse-bottom {
+  margin-bottom: 20px;
+}
+.input-main .textarea .el-textarea__inner {
+  width: 100%;
+  z-index: 1;
+}
+.bg-left {
+  padding-left: 30px;
+}
+.bg-right {
+  padding-right: 10px;
+  text-align: right;
+}
+.bg-bottom {
+  margin: 15px 0px;
+}
+.wenzi {
+  width: 900px;
+  margin: 0 auto;
+}
+.wenzi h3 {
+  display: inline-block;
+  left: 10px;
+}
+.wenzi p {
+  display: inline-block;
+}
+.center {
+  width: 900px;
+  margin: 0 auto;
+}
+.el-form-item {
+  width: 50%;
+}
+.el-form-item__label {
+  text-align: center;
+}
+.ce {
+  width: 900px;
+  margin: 0 auto;
+}
+/*.crt-main .textarea /deep/ .el-form-item__label {*/
+/*  height: 82px;*/
+/*}*/
+// 控制select为只读的时候显示样式
+
+.hide-sel {
+  .el-input__inner {
+    border: 0px;
+  }
+  .el-icon-arrow-up {
+    display: none;
+  }
+  .el-textarea__inner {
+    background-color: #fff !important;
+    border: 0;
+  }
+  .el-date-editor {
+    i {
+      display: none;
+    }
+  }
+  .is-disabled {
+    .el-input__inner:hover {
+      background-color: #fff !important;
+      border: 0;
+    }
+    color: #606266;
+    .el-input__inner {
+      background-color: #fff !important;
+      border: 0;
+      color: #606266;
+    }
+    .el-textarea__inner {
+      background-color: #fff !important;
+      border: 0;
+      color: #606266;
+    }
+  }
+}
+
+// 控制select为只读的时候显示样式
+/deep/.ws-class-table-col {
+  height: auto;
+  padding: 0px 2px;
+  /deep/.el-input__inner {
+    padding: 0px 2px;
+  }
+}
+/deep/.is-disabled {
+  .el-input__prefix,
+  .el-input__suffix {
+    display: none;
+  }
+  .el-input__inner {
+    background-color: #fff;
+    border-color: #fff !important;
+    color: #000 !important;
+    font-size: 14px;
+    cursor: text;
+    padding: 0 !important;
+  }
+}
+.winseaview-view {
+  padding: 0 0 20px;
+}
+.container {
+  overflow: scroll;
+  height: 93vh;
+}
+.ws-info-table .el-form-item {
+  width: 33.3333%;
+}
+.readonly:after {
+  display: none;
+}
+.el-textarea__inner {
+  display: none;
+}
+.el-form {
+  margin-top: 50px;
+}
+.readonly {
+  width: 16%;
+}
+.ws-info-table .el-form-item {
+  width: 33.33%;
+}
+//去边框
+/deep/.el-form-item {
+  border-right: 0px;
+  border-bottom: 0px;
+}
+/deep/.ws-info-table {
+  border-left: 0px;
+  border-top: 0px;
+}
+.ws-info-table .el-form-item .el-form-item__content {
+  border-right: 0px;
+  border-bottom: 0px;
+  border-left: 0px;
+  border-top: 0px;
+}
+/deep/.ws-info-table .el-form-item {
+  border-right: 0px;
+  border-bottom: 0px;
+  border-left: 0px;
+  border-top: 0px;
+}
+/deep/.ws-info-table .el-form-item .el-form-item__content {
+  background: #f5f7fa;
+  border-radius: 4px;
+  border: 1px solid #d8dce6;
+  font-family: PingFangSC-Regular, PingFang SC;
+  margin-bottom: 5px;
+  background-color: #fff;
+  font-size: 14px;
+  font-weight: 400;
+  color: #8890b1;
+  line-height: 16px;
+}
+/deep/.ws-info-table .el-form-item .el-form-item__label {
+  background-color: #fff;
+  font-size: 14px;
+  font-family: PingFangSC-Regular, PingFang SC;
+  font-weight: 400;
+  color: #8890b1;
+  line-height: 16px;
+}
+
+/deep/.ws-info-table .el-form-item .el-form-item__content {
+  border: 0px;
+}
+//联络员及车次
+/deep/.flex .ws-info-table .el-form-item {
+  width: 20%;
+}
+/deep/.flex .ws-info-table .el-form-item .el-form-item__label{
+    width: 33%;
+}
+</style>

+ 849 - 0
src/views/tranManagement/tranManagementTransporTrainNo.vue

@@ -0,0 +1,849 @@
+//车次安排
+<template>
+  <div class="container">
+    <el-row>
+      <el-col :span="12">
+        <h2 class="bg-left title">车次安排</h2>
+      </el-col>
+      <el-col :span="12" class="bg-right">
+        <el-button
+          class="bg-bottom"
+          type="primary"
+          size="small"
+          @click="returnsales()"
+          ><img
+            width="6"
+            height="10"
+            style="vertical-align: bottom; margin-right: 3px"
+            src="../../../public/img/lujing.png"
+            alt=""
+          />返回</el-button
+        >
+      </el-col>
+    </el-row>
+
+    <ws-form
+      class="position"
+      ref="deptBudgetList"
+      :rules="rules"
+      :model="deptBudgetList"
+    >
+      <div class="small-title">任务详情</div>
+      <ws-info-table>
+        <!--任务编号-->
+        <ws-form-item label="任务编号" span="1" prop="processNo">
+          <ws-input
+            v-model="deptBudgetList.processNo"
+            placeholder="请输入任务编号"
+            maxlength="20"
+            size="small"
+          />
+        </ws-form-item>
+        <!--货名-->
+        <ws-form-item label="货名" span="1" prop="goodsName">
+          <ws-select
+            v-model="deptBudgetList.goodsName"
+            placeholder="请选择货名"
+          >
+            <ws-option
+              v-for="item in personCharge"
+              :key="item.value"
+              :label="item.staffName"
+              :value="item.staffName"
+            />
+          </ws-select>
+        </ws-form-item>
+        <!--重量(吨)-->
+        <ws-form-item label="重量(吨)" span="1" prop="weight">
+          <ws-input
+            v-model="deptBudgetList.weight"
+            placeholder="请输入重量(吨)"
+            maxlength="100"
+            size="small"
+          />
+        </ws-form-item>
+
+        <!--发货地址-->
+        <ws-form-item label="发货地址" span="1" prop="sendDetailedAddress">
+          <el-cascader
+            :options="options_"
+            v-model="deptBudgetList.sendDetailedAddress"
+            clearable
+            size="large"
+            placeholder="请选择发货地址"
+            style="width: 200%"
+            @change="handleChange"
+          />
+        </ws-form-item>
+
+        <!--发货人-->
+        <ws-form-item label="发货人" span="1" prop="sender" class="readonly">
+          <ws-input
+            v-model="deptBudgetList.sender"
+            placeholder="请输入发货人"
+            maxlength="100"
+            size="small"
+          />
+        </ws-form-item>
+
+        <!--发货人电话-->
+        <ws-form-item
+          label="发货人电话"
+          span="1"
+          prop="senderPhone"
+          class="readonly"
+        >
+          <ws-input
+            v-model="deptBudgetList.senderPhone"
+            placeholder="请输入发货人电话"
+            maxlength="100"
+            size="small"
+          />
+        </ws-form-item>
+        <!--收货地址-->
+        <ws-form-item label="收货地址" span="1" prop="receiveDetailedAddress">
+          <el-cascader
+            :options="options_"
+            v-model="deptBudgetList.receiveDetailedAddress"
+            clearable
+            size="large"
+            placeholder="请选择发货地址"
+            style="width: 200%"
+            @change="handleChange"
+          />
+        </ws-form-item>
+        <!--收货人-->
+        <ws-form-item label="收货人" span="1" prop="receiver">
+          <ws-input
+            v-model="deptBudgetList.receiver"
+            placeholder="请输入仓库名"
+            maxlength="20"
+            size="small"
+          />
+        </ws-form-item>
+        <!--收货人电话-->
+        <ws-form-item label="收货人电话" span="1" prop="receiverPhone">
+          <ws-input
+            v-model="deptBudgetList.receiverPhone"
+            placeholder="请输入仓库名"
+            maxlength="20"
+            size="small"
+          />
+        </ws-form-item>
+        <!--发货日期-->
+        <ws-form-item label="发货日期" span="1" prop="deliveryDateStart">
+          <ws-date-picker
+            v-model="deptBudgetList.deliveryDateStart"
+            type="date"
+            placeholder="请选择发货日期"
+            value-format="yyyy-MM-dd"
+          />
+        </ws-form-item>
+        <!--最晚到货日期-->
+        <ws-form-item label="最晚到货日期" span="1" prop="deliveryDateEnd">
+          <ws-date-picker
+            v-model="deptBudgetList.deliveryDateEnd"
+            type="date"
+            placeholder="请选择最晚到货日期"
+            value-format="yyyy-MM-dd"
+          />
+        </ws-form-item>
+        <!--合同编号-->
+        <ws-form-item label="合同编号" span="1" prop="contractNo">
+          <ws-input
+            v-model="deptBudgetList.contractNo"
+            placeholder="请输入仓库名"
+            maxlength="20"
+            size="small"
+          />
+        </ws-form-item>
+      </ws-info-table>
+      <div class="small-title">联络员及车次</div>
+      <div
+        style="width: 100%"
+        class="flex position"
+        v-for="(item, index) in freightspace"
+      >
+        <ws-info-table>
+          <!--姓名-->
+          <ws-form-item label="姓名" span="1" prop="driver">
+            <!-- <ws-input
+              v-model="deptBudgetList.driver"
+              placeholder="请输入姓名"
+              maxlength="20"
+              size="small"
+            /> -->
+            <ws-select
+              v-model="deptBudgetList.driver"
+              placeholder=""
+              class="typeselect"
+              @change="selectdriver"
+            >
+              <ws-option
+                v-for="item in driverList"
+                :key="item.constKey"
+                :label="item.driverName"
+                :value="item.driverName"
+              />
+            </ws-select>
+          </ws-form-item>
+          <!--电话-->
+          <ws-form-item label="电话" span="1" prop="driverPhone">
+            <ws-input
+              v-model="deptBudgetList.driverPhone"
+              placeholder="请输入电话"
+              maxlength="20"
+              size="small"
+            />
+          </ws-form-item>
+          <!--发车日期-->
+          <ws-form-item label="发车日期" span="1" prop="sendDateStart">
+            <ws-date-picker
+              v-model="deptBudgetList.sendDateStart"
+              type="date"
+              placeholder="请选择发货日期"
+              value-format="yyyy-MM-dd"
+            />
+          </ws-form-item>
+          <!--到站日期-->
+          <ws-form-item label="到站日期" span="1" prop="receiveDateEnd">
+            <ws-date-picker
+              v-model="deptBudgetList.receiveDateEnd"
+              type="date"
+              placeholder="请选择发货日期"
+              value-format="yyyy-MM-dd"
+            />
+          </ws-form-item>
+          <!--车次-->
+          <ws-form-item label="车次" span="1" prop="trainNo">
+            <ws-input
+              v-model="deptBudgetList.trainNo"
+              placeholder="请输入车次"
+              maxlength="20"
+              size="small"
+            />
+          </ws-form-item>
+          <!-- 加减号 -->
+          <img
+            width="22"
+            height="22"
+            class="add"
+            @click="add"
+            src="../../../public/img/add.png"
+            alt=""
+          />
+          <img
+            width="22"
+            height="22"
+            class="del"
+            @click="del(index)"
+            src="../../../public/img/del.png"
+            alt=""
+          />
+        </ws-info-table>
+      </div>
+    </ws-form>
+
+    <!-- 提交 -->
+    <div style="text-align: right; padding: 10px" class="center">
+      <el-button
+        class="bg-bottom"
+        type="primary"
+        size="small"
+        @click="submit(deptBudgetList)"
+        >提交</el-button
+      >
+    </div>
+  </div>
+</template>
+<script>
+import { regionData, CodeToText, TextToCode } from 'element-china-area-data'
+import { seeCat, dispatchCat, arrange, nameXiala } from '@/model/transport/index'
+import WsUpload from '@/components/WsUpload'
+import mapDrag from '@/components/mapdrag/mapdrag'
+export default {
+  name: 'viewSpareMoney',
+  components: {
+    WsUpload,
+    mapDrag,
+  },
+  watch: {
+    vesselId(val) {
+      this.getVesselData()
+    },
+    isShow(val) {
+      this.showType = val
+    },
+  },
+  data() {
+    return {
+      staffList: [],
+      deptBudgetList: {
+        totalStorage: 0,
+      },
+      options_: regionData,
+      heightData: '600px',
+      zoom: 7,
+      selectedOptions: [],
+      center: [116.244694, 39.517344],
+      window: '',
+      radio: 1,
+      personCharge: [],
+      district: null,
+      driverList: [],
+      listDate: { country: '中国', level: 'country', city: '' },
+      citylist: [],
+      compId: sessionStorage.getItem('ws-pf_compId'),
+      rules: {
+        warehouseName: [
+          {
+            required: true,
+            message: '请输入仓库名称',
+            trigger: 'blur',
+          },
+          {
+            min: 2,
+            max: 20,
+            message: '仓库名长度不符合要求,请输入2-20字符之内',
+            trigger: 'blur',
+          },
+        ],
+      },
+      appendixIdsAdd: '',
+      size: 10,
+      value1: '',
+      unitList: [],
+      freightspace: [
+        {
+          driver: '',
+          driverPhone: '',
+          sendDateStart: '',
+          receiveDateEnd: '',
+          trainNo: '',
+        },
+      ],
+      name: '',
+      list: [],
+    }
+  },
+  mounted() {
+    this.deptBudgetList.id = this.$route.query.id
+    this.getList()
+  },
+  computed: {
+    totalStorage: function () {
+      var maxStorage = 0
+      for (var i = 0; i < this.freightspace.length; i++) {
+        maxStorage += Number(this.freightspace[i].maxStorage)
+      }
+      return maxStorage
+    },
+  },
+  methods: {
+    marker: function (item) {
+      this.deptBudgetList.warehousePositioning =
+        item.lnglat.lat + ',' + item.lnglat.lng
+    },
+    selectedAddress(e) {
+      this.deptBudgetList.warehousePositioning =
+        e.center.lat + ',' + e.center.lng
+    },
+    confirmPositioncity() {
+      this.listDate.level = 'city'
+      this.listDate.country = this.name
+    },
+    // 关闭 dialog时 处理文件url 初始化upload组件
+    handleClose() {
+      this.dialogViewSpareMoney = false
+    },
+    add() {
+      this.freightspace.push({
+        binNumber: '',
+        maxStorage: '',
+        remark: '',
+      })
+    },
+    del(index) {
+      if (this.freightspace.length > 1) {
+        this.freightspace.splice(index, 1)
+      }
+    },
+    //下拉司机姓名改变事件
+    selectdriver(){
+
+
+    },
+    handleChange(value) {
+      this.selectedOptions = value
+    },
+    returnsales() {
+      this.deptBudgetList = {}
+      this.freightspace = {}
+      this.selectedOptions = ''
+      this.$router.push({ path: 'tranManagementTransporTationFire' })
+    },
+    // confirmPosition() {
+    //   this.draggable = false
+    // },
+    // 上传附件
+    uploadSuccess(data, files, url) {
+      console.log(data, files, url)
+
+      // this.deptBudgetList.
+      // this.formData.append('files', files)
+      // this.feedbackObj.uploadNameAttachment = data.appendixName
+      // this.feedbackObj.pathUploadAttachment = data.appendixPath
+      // // this.newAppendixs = files
+      // this.onChangeFlag = true
+    },
+    submit() {
+      this.$confirm(`提交成功后,任务将下发给相关人员,是否确定提交?`, {
+        confirmButtonText: '确定',
+        cancelButtonText: '取消',
+        type: 'warning',
+      })
+        .then(() => {
+          this.$refs.deptBudgetList.validate((valid) => {
+            console.log(this.freightspace)
+            if (valid) {
+              this.deptBudgetList.compId =
+                sessionStorage.getItem('ws-pf_compId')
+              this.deptBudgetList.warehousePrivate =
+                CodeToText[this.selectedOptions[0]]
+              this.deptBudgetList.warehouseCity =
+                CodeToText[this.selectedOptions[1]]
+              this.deptBudgetList.warehouseArea =
+                CodeToText[this.selectedOptions[2]]
+              this.deptBudgetList.tranCarInfoList = this.freightspace
+              this.deptBudgetList.totalStorage = this.totalStorage
+              dispatchCat(this.deptBudgetList)
+                .toPromise()
+                .then((response) => {
+                  this.$message.success('添加成功')
+                  this.deptBudgetList = {}
+                  this.freightspace = {}
+                  this.selectedOptions = ''
+                  this.$router.push({
+                    path: 'tranManagementTransporTationFire',
+                  })
+                })
+            } else {
+              // EventBus.$emit('error', this.$t('showMessage.asteriskRequired'))
+              return false
+            }
+          })
+        })
+        .catch(() => {
+          return false
+        })
+    },
+    resetForm(deptBudgetList) {
+      this.$refs[deptBudgetList].resetFields()
+    },
+
+    getList() {
+      seeCat({ id: this.deptBudgetList.id })
+        .toPromise()
+        .then((response) => {
+          this.deptBudgetList = response
+        })
+      //司机姓名下拉
+      nameXiala({compId: sessionStorage.getItem('ws-pf_compId') })
+        .toPromise()
+        .then((response) => {
+          this.driverList = response
+        })
+    },
+    handleExamine() {},
+    approve() {},
+    // returnsales() {
+    //   this.$router.push({ path: 'purchaseContract' })
+    // },
+    selectChapterTwo(e) {
+      for (var i = 0; i < this.ChapterTwoList.length; i++) {
+        if (this.ChapterTwoList[i].constValue == e) {
+          this.deptBudgetList.gradeKey = this.ChapterTwoList[i].constKey
+        }
+      }
+    },
+    selectunitList(e) {
+      for (var i = 0; i < this.unitList.length; i++) {
+        if (this.unitList[i].constValue == e) {
+          this.deptBudgetList.acceptanceMethodKey = this.unitList[i].constKey
+        }
+      }
+    },
+    selectgrade(e) {
+      for (var i = 0; i < this.gradeList.length; i++) {
+        if (this.gradeList[i].constValue == e) {
+          this.deptBudgetList.gradeKey = this.gradeList[i].constKey
+        }
+      }
+    },
+    selectgoodsName(e) {
+      for (var i = 0; i < this.goodnameList.length; i++) {
+        if (this.goodnameList[i].constValue == e) {
+          this.deptBudgetList.goodsNameKey = this.goodnameList[i].constKey
+        }
+      }
+    },
+    selectpackingMethod(e) {
+      for (var i = 0; i < this.packtypeList.length; i++) {
+        if (this.packtypeList[i].constValue == e) {
+          this.deptBudgetList.packingMethodKey = this.packtypeList[i].constKey
+        }
+      }
+    },
+    // 编辑
+    editClick(item, index) {
+      const map = JSON.parse(JSON.stringify(item))
+      if (Object.is(item.id, 1)) {
+        return
+      }
+      if (Object.is(this.unitList[index].flag, 'delete')) {
+        map.flag = 'check'
+        this.$set(this.unitList, index, map)
+      } else {
+        map.flag = 'delete'
+        this.$set(this.unitList, index, map)
+      }
+    },
+    // 删除
+    deleteClick(item, index) {
+      if (Object.is(item.constKey, 1)) {
+        return
+      }
+      if (!item.constValue) {
+        this.unitList.splice(index, 1)
+        return
+      }
+      delxiala({ id: this.unitList[index].id })
+        .toPromise()
+        .then((response) => {
+          this.getUnitList()
+          this.pleaseChoose = ''
+        })
+    },
+  },
+}
+</script>
+
+<style lang="scss" scoped>
+/deep/.totalStorage .el-input__inner {
+  color: #afb5cb;
+  background: #f5f7fa;
+}
+.small-title {
+  position: relative;
+  padding: 10px;
+  font-weight: 600;
+}
+.small-title::before {
+  position: absolute;
+  content: '';
+  display: block;
+  background: #5473e8;
+  width: 4px;
+  height: 14px;
+  left: 0px;
+  top: 13px;
+}
+.position {
+  position: relative;
+}
+.add,
+.del {
+  position: absolute;
+  right: -38px;
+  top: 9px;
+  cursor: pointer;
+}
+.del {
+  right: -70px;
+}
+.amap-page-container {
+  width: 300px;
+  height: 300px;
+}
+.el-form {
+  padding: 0 15%;
+}
+/deep/.ws-info-table .el-form-item {
+  border-right: 1px solid transparent;
+  border-bottom: 1px solid transparent;
+}
+.readonly {
+  position: relative;
+}
+.readonly:after {
+  content: '*';
+  color: #ff2727;
+  position: absolute;
+  right: 8px;
+  z-index: 10;
+  top: 21%;
+  font-size: 20px;
+}
+.title {
+  position: relative;
+}
+.title::before {
+  content: '';
+  display: inline-block;
+  width: 5px;
+  height: 30px;
+  background: #5473e8;
+  position: absolute;
+  left: 0;
+}
+.ws-info-table {
+  border-left: 1px solid transparent;
+  border-top: 1px solid transparent;
+}
+.el-button--primary {
+  background-color: #5878e8;
+  border-color: #5878e8;
+}
+.el-col {
+  background: #f6f7fc;
+}
+/deep/.ws-info-table .el-form-item .el-form-item__content {
+  padding: 0 25px;
+  border-left: 1px solid transparent;
+  background: #fff;
+}
+/deep/.ws-info-table .el-form-item .el-form-item__label {
+  width: 100px;
+  text-align: center;
+  background: #fff;
+  // border: 1px solid #cdd2dc;
+}
+.button-container {
+  display: flex;
+  flex-wrap: nowrap;
+  justify-content: space-between;
+  align-items: center;
+  background-color: #fff;
+  width: 100%;
+  height: 50px;
+  padding: 0 10px;
+  & > div {
+    margin-left: 10px;
+    display: flex;
+    flex-wrap: nowrap;
+    flex-direction: row;
+    & > span {
+      line-height: 50px;
+    }
+  }
+
+  /deep/.auditFlow-box {
+    position: unset;
+    margin-left: 10px;
+    &/deep/.auditFlow-icon {
+      width: auto;
+      padding-right: 30px;
+    }
+    &/deep/.auditFlow-main {
+      position: absolute;
+    }
+  }
+}
+.box-app {
+  display: inline-block;
+  float: left;
+  margin-left: 30px;
+  line-height: 50px;
+}
+/deep/.el-dialog {
+  .el-form-item {
+    margin-bottom: 0 !important;
+    .el-input--medium {
+      textarea {
+        min-height: 100px !important;
+      }
+    }
+  }
+}
+.collapse-bottom {
+  margin-bottom: 20px;
+}
+.input-main .textarea .el-textarea__inner {
+  width: 100%;
+  z-index: 1;
+}
+.bg-left {
+  padding-left: 30px;
+}
+.bg-right {
+  padding-right: 10px;
+  text-align: right;
+}
+.bg-bottom {
+  margin: 15px 0px;
+}
+.wenzi {
+  width: 900px;
+  margin: 0 auto;
+}
+.wenzi h3 {
+  display: inline-block;
+  left: 10px;
+}
+.wenzi p {
+  display: inline-block;
+}
+.center {
+  width: 900px;
+  margin: 0 auto;
+}
+.el-form-item {
+  width: 50%;
+}
+.el-form-item__label {
+  text-align: center;
+}
+.ce {
+  width: 900px;
+  margin: 0 auto;
+}
+/*.crt-main .textarea /deep/ .el-form-item__label {*/
+/*  height: 82px;*/
+/*}*/
+// 控制select为只读的时候显示样式
+
+.hide-sel {
+  .el-input__inner {
+    border: 0px;
+  }
+  .el-icon-arrow-up {
+    display: none;
+  }
+  .el-textarea__inner {
+    background-color: #fff !important;
+    border: 0;
+  }
+  .el-date-editor {
+    i {
+      display: none;
+    }
+  }
+  .is-disabled {
+    .el-input__inner:hover {
+      background-color: #fff !important;
+      border: 0;
+    }
+    color: #606266;
+    .el-input__inner {
+      background-color: #fff !important;
+      border: 0;
+      color: #606266;
+    }
+    .el-textarea__inner {
+      background-color: #fff !important;
+      border: 0;
+      color: #606266;
+    }
+  }
+}
+
+// 控制select为只读的时候显示样式
+/deep/.ws-class-table-col {
+  height: auto;
+  padding: 0px 2px;
+  /deep/.el-input__inner {
+    padding: 0px 2px;
+  }
+}
+/deep/.is-disabled {
+  .el-input__prefix,
+  .el-input__suffix {
+    display: none;
+  }
+  .el-input__inner {
+    background-color: #fff;
+    border-color: #fff !important;
+    color: #000 !important;
+    font-size: 14px;
+    cursor: text;
+    padding: 0 !important;
+  }
+}
+.winseaview-view {
+  padding: 0 0 20px;
+}
+.container {
+  overflow: scroll;
+  height: 93vh;
+}
+.ws-info-table .el-form-item {
+  width: 33.3333%;
+}
+.readonly:after {
+  display: none;
+}
+.el-textarea__inner {
+  display: none;
+}
+.el-form {
+  margin-top: 50px;
+}
+.readonly {
+  width: 16%;
+}
+.ws-info-table .el-form-item {
+  width: 33.33%;
+}
+//去边框
+/deep/.el-form-item {
+  border-right: 0px;
+  border-bottom: 0px;
+}
+/deep/.ws-info-table {
+  border-left: 0px;
+  border-top: 0px;
+}
+.ws-info-table .el-form-item .el-form-item__content {
+  border-right: 0px;
+  border-bottom: 0px;
+  border-left: 0px;
+  border-top: 0px;
+}
+/deep/.ws-info-table .el-form-item {
+  border-right: 0px;
+  border-bottom: 0px;
+  border-left: 0px;
+  border-top: 0px;
+}
+/deep/.ws-info-table .el-form-item .el-form-item__content {
+  background: #f5f7fa;
+  border-radius: 4px;
+  border: 1px solid #d8dce6;
+  font-family: PingFangSC-Regular, PingFang SC;
+  margin-bottom: 5px;
+  background-color: #fff;
+  font-size: 14px;
+  font-weight: 400;
+  color: #8890b1;
+  line-height: 16px;
+}
+/deep/.ws-info-table .el-form-item .el-form-item__label {
+  background-color: #fff;
+  font-size: 14px;
+  font-family: PingFangSC-Regular, PingFang SC;
+  font-weight: 400;
+  color: #8890b1;
+  line-height: 16px;
+}
+
+/deep/.ws-info-table .el-form-item .el-form-item__content {
+  border: 0px;
+}
+//联络员及车次
+/deep/.flex .ws-info-table .el-form-item {
+  width: 20%;
+}
+/deep/.flex .ws-info-table .el-form-item .el-form-item__label {
+  width: 33%;
+}
+</style>

+ 1 - 1
vue.config.js

@@ -144,7 +144,7 @@ module.exports = {
         // target: 'http://standard-dev.winsea.com/', //目标地址
         // target: 'http://localhost:8090/',
         // target: 'http://192.168.1.121:8090/',
-        target: 'http://192.168.1.119:8090/',
+        target: 'http://192.168.1.115:8090/',
         // target: 'http://192.168.1.119:8090/',
         // target: 'http://192.168.24.5:8098',//目标地址
         // target: 'http://product-server.winsea.com/',