zhangyuewww 3 năm trước cách đây
mục cha
commit
f0dc7ab88e

+ 4 - 1
src/api/V2/transport/index.js

@@ -43,8 +43,11 @@ export const API_GET_AUTOMOBILE_NAME = "/driverViewInfo/selectDriverName"
 export const API_GET_AUTOMOBILE_ARRANGE = "/driverViewInfo/selectDriverDetail"
 //发货反馈
 export const API_POST_AUTOMOBILE_FEEDBACK = '/tranProcessInfo/api/insertTranCar'
-//更改反馈状态
+//更改发货反馈状态
 export const API_POST_AUTOMOBILE_STATE = '/tranProcessInfo/api/editFeedbackStatus'
+//更改收货反馈状态
+export const API_POST_AUTOMOBILE_STATEREC = '/tranProcessInfo/api/editReceivingStatus'
+
 //状态
 export const API_POST_AUTOMOBILE_ALSOSTATE = '/tranProcessInfo/editStatus'
 //运输价格

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

@@ -28,7 +28,8 @@ import {
     API_POST_AUTOMOBILE_STATE,
     API_POST_AUTOMOBILE_TRANPRICE,
     API_POST_DEL_HAULAGE_STAGE, 
-    API_POST_AUTOMOBILE_ALSOSTATE
+    API_POST_AUTOMOBILE_ALSOSTATE,
+    API_POST_AUTOMOBILE_STATEREC
 
 } from '@/api/V2/transport'
 // 司机列表
@@ -75,8 +76,11 @@ export const nameXiala = appRx.get(API_GET_AUTOMOBILE_NAME, errorCatcher, errorH
 export const arrange = appRx.get(API_GET_AUTOMOBILE_ARRANGE, errorCatcher, errorHandle, filter)
 //发货反馈
 export const feedback = appRx.post(API_POST_AUTOMOBILE_FEEDBACK, errorCatcher, errorHandle, filter)
-//更改反馈状态
+//更改发货反馈状态
 export const state = appRx.post(API_POST_AUTOMOBILE_STATE, errorCatcher, errorHandle, filter)
+//更改收货反馈状态
+export const stateRec = appRx.post(API_POST_AUTOMOBILE_STATEREC, errorCatcher, errorHandle, filter)
+
 //状态
 export const alsostate = appRx.post(API_POST_AUTOMOBILE_ALSOSTATE, errorCatcher, errorHandle, filter)
 //设置运输价格

+ 14 - 21
src/views/tranManagement/tranManagementReceivingFeedback.vue

@@ -107,18 +107,18 @@
               <template>
                 <span slot="reference">
                   <span
-                    v-if="scope.row.feedbackStatus == '待执行'"
+                    v-if="scope.row.receivingStatus == '待执行'"
                     class="executory"
                   ></span>
                   <span
-                    v-if="scope.row.feedbackStatus == '执行中'"
+                    v-if="scope.row.receivingStatus == '执行中'"
                     class="inExecution"
                   ></span>
                   <span
-                    v-if="scope.row.feedbackStatus == '已完成'"
+                    v-if="scope.row.receivingStatus == '已完货'"
                     class="done"
                   ></span
-                  >{{ scope.row.feedbackStatus }}
+                  >{{ scope.row.receivingStatus }}
                 </span>
               </template>
               <div>
@@ -156,24 +156,17 @@
           <template slot-scope="scope">
             <template
               v-if="
-                scope.row.tranType == '汽运' &&
-                scope.row.feedbackStatus != '已完成'
+                scope.row.receivingStatus != '已完货'
               "
             >
               <div class="record" @click="trainSee(scope.row)">查看</div>
               <div class="adjustment" @click="feedback(scope.row)">反馈</div>
             </template>
             <template
-              v-else-if="
-                scope.row.tranType == '汽运' &&
-                scope.row.feedbackStatus == '已完成'
-              "
+              v-else
             >
               <div class="record1" @click="trainSee(scope.row)">查看</div>
             </template>
-            <template v-else>
-              <div class="record1">—— ——</div>
-            </template>
           </template>
         </el-table-column>
       </el-table>
@@ -193,7 +186,7 @@
   </div>
 </template>
 <script>
-import { shippingList, state } from '@/model/transport/index'
+import { shippingList, stateRec } from '@/model/transport/index'
 import { downloadFile } from '@/utils/batchDown'
 import Pagination from '@/components/Pagination'
 import WsUpload from '@/components/WsUpload'
@@ -228,14 +221,14 @@ export default {
       year: '',
       currentPage: 1,
       pageSize: 10,
-      feedbackFlag: 1,
+      feedbackFlag: 4,
       searchType: 1,
       searchTypeText: '执行中',
       searchKeyWord: '',
       contractType: 2,
       taskTypeList: [
-        { value: '执行中', type: 1 },
-        { value: '已完成', type: 2 },
+        { value: '执行中', type: 4 },
+        { value: '已完货', type: 5 },
         { value: '全部任务', type: 3 },
       ],
 
@@ -397,10 +390,10 @@ export default {
     },
     editClick(row) {
       var status = ''
-      if (row.feedbackStatus == '待执行' || row.feedbackStatus == '已完成') {
+      if (row.receivingStatus == '待执行' || row.receivingStatus == '已完货') {
         status = '执行中'
-      } else if (row.feedbackStatus == '执行中') {
-        status = '已完'
+      } else if (row.receivingStatus == '执行中') {
+        status = '已完'
       }
       //cancelButtonClass: "btn-custom-cancel"
       this.$confirm(`是否将状态改为${status}`, {
@@ -409,7 +402,7 @@ export default {
         type: 'warning',
       })
         .then(() => {
-          state({ id: row.id })
+          stateRec({ id: row.id })
             .toPromise()
             .then((response) => {
               this.$notify.success({

+ 93 - 6
src/views/tranManagement/tranManagementReceivingloading.vue

@@ -79,14 +79,34 @@
             <ws-form-item label="运输方式" span="1" prop="contractNo">{{ deptBudgetList.contractNo }}</ws-form-item>
           </ws-info-table>
 
-          <div class="small-title" style="font-size: 16px">卸车详情</div>
-
+          <div class="small-title" style="font-size: 16px;width: 50%;float: left;">卸车详情</div>
+          <!-- 导入 -->
+          <div style="font-size: 16px;width: 50%; margin-left: 1150px;">
+          <el-button
+            class="bg-bottom"
+            type="primary"
+            size="small"
+            @click="import(deptBudgetList)"
+            >导入</el-button
+          >
+        </div>
           <div
             class="driver position liaison"
             v-for="(item, index) in deptBudgetList.tranCarInfoList"
+            :key="index"
           >
             <ws-info-table>
-              <div class="catNos" v-show="item.temporaryDriverFlag == 0">司机-{{index+1}}</div>
+              <div class="catNos" v-show="item.temporaryDriverFlag == 0">司机-{{index+1}}
+                 <span class="noservice" v-show="item.status == '未装车'">{{
+                  item.status
+                }}</span>
+                <span class="service" v-show="item.status == '已装车'">
+                   未卸车
+                </span>
+                 <span class="serviced" v-show="item.status == '已送达'">
+                   已卸车
+                </span>
+              </div>
               <div class="catNos catNosCor" v-show="item.temporaryDriverFlag != 0">司机-{{index+1}}(临)</div>
               <!--姓名-->
               <ws-form-item
@@ -136,6 +156,24 @@
                   size="small"
                 />
               </ws-form-item>
+               <!--卸车日期-->
+            <el-form-item label="卸车日期:" span="1" prop="receiveDateEnd" >
+            <ws-date-picker
+              v-model="item.receiveDateEnd"
+              v-if="item.status == '已送达'" 
+              :disabled="readonly"
+              type="date"
+              style="width: 300px;"
+              value-format="yyyy-MM-dd"
+            />
+            <ws-date-picker
+              v-model="item.receiveDateEnd"
+              v-else
+              type="date"
+              placeholder="请选择日期"
+              value-format="yyyy-MM-dd"
+            />
+          </el-form-item>
               <!--磅单-->
               <ws-form-item label="磅单:" span="1" prop="unloadPoundImg">
                 <template >
@@ -185,13 +223,27 @@
             </div>
             </ws-info-table>
           </div>
+        </div>
           <div
             style="text-align: right; color: #8890b1; font-size: 16px"
-          >合计{{ total }}/{{ deptBudgetList.weight }}</div>
+          >合计{{ total }}/{{ deptBudgetList.weight }}
+           <!--阶段状态-->
+         <span class="noservice" v-show="deptBudgetList.receivingStatus=='执行中'">
+          未完货
+        </span>
+        <span class="service" v-show="deptBudgetList.receivingStatus=='已完货'">{{
+          deptBudgetList.receivingStatus
+        }}</span></div>
           <div style="text-align: right; padding: 10px">
             <el-button class="bg-bottom-up" type="primary" size="small" @click="submit()">提交</el-button>
+             <el-button
+                class="bg-bottom"
+                type="primary"
+                size="small"
+                @click="finished (deptBudgetList)"
+                >完货</el-button
+              >
           </div>
-        </div>
       </ws-form>
     </div>
   </div>
@@ -199,7 +251,7 @@
 <script>
 import Pagination from '@/components/Pagination'
 import WsUpload from '@/components/WsUpload'
-import { seeCat, packList, feedback, getbank } from '@/model/transport/index'
+import { seeCat, packList, feedback, getbank,stateRec } from '@/model/transport/index'
 // import { dayjs, fmoney, EventBus } from 'base-core-lib'
 import { dayjs, EventBus } from 'base-core-lib'
 export default {
@@ -362,7 +414,42 @@ export default {
           return false
         })
     },
+    //导入
+    import(){
+
+    },
+    finished(){
+       this.$confirm(`完货操作后,卸车信息不可修改,是否确定完货?`, {
+        confirmButtonText: '确定',
+        cancelButtonText: '取消',
+        type: 'warning',
+      })
+        .then(() => {
+          this.$refs.deptBudgetList.validate((valid) => {
+            if (valid) {
+              var tranProcessInfo = {}
+              tranProcessInfo.id = this.deptBudgetList.id
+              stateRec(tranProcessInfo)
+                .toPromise()
+                .then((response) => {
+                  this.$message.success('完货成功')
+                  this.deptBudgetList = {}
+                  this.freightspace = {}
+                  this.selectedOptions = ''
+                  this.$router.push({
+                    path: 'tranManagementTransporHairRespond',
+                  })
+                })
+            } else {
+              return false
+            }
+          })
+        })
+        .catch(() => {
+          return false
+        })
 
+    },
     handleClose() {
       this.accessoryTFs = false
     },

+ 41 - 2
src/views/tranManagement/tranManagementReceivingloadingLook.vue

@@ -99,7 +99,17 @@
           
         >
           <ws-info-table>
-            <div class="catNos" v-show="item.temporaryDriverFlag == 0">司机-{{index+1}}</div>
+            <div class="catNos" v-show="item.temporaryDriverFlag == 0">司机-{{index+1}}
+              <span class="noservice" v-show="item.status == '未装车'">{{
+                  item.status
+                }}</span>
+                <span class="service" v-show="item.status == '已装车'">
+                  未卸车
+                </span>
+                 <span class="serviced" v-show="item.status == '已送达'">
+                  已卸车
+                </span>
+            </div>
              <div class="catNos catNosCor" v-show="item.temporaryDriverFlag != 0">司机-{{index+1}}(临)</div>
             <!--姓名-->
             <ws-form-item label="姓名:" span="1" prop="driver" v-show="freightspace[index].temporaryDriverFlag == 0">
@@ -128,7 +138,11 @@
             <ws-form-item label="卸车净重(吨):" span="1" prop="unloadNetWeight">
               {{ item.unloadNetWeight }}
             </ws-form-item>
-             <el-divider direction="vertical" class="line"></el-divider>
+            <el-divider direction="vertical" class="line"></el-divider>
+            <!--卸车日期-->
+            <el-form-item label="卸车日期:" span="1" prop="receiveDateEnd" >
+              {{ item.receiveDateEnd }}
+          </el-form-item>
             <!--磅单-->
             <ws-form-item label="磅单:" span="1" prop="unloadPoundImg">
               <template >
@@ -164,6 +178,7 @@
                 </div> -->
               </template>
             </ws-form-item>
+            <el-divider direction="vertical" class="line"></el-divider>
             <!--箱号-->
             <ws-form-item label="箱号:" span="1" prop="caseNo">
              <span>{{ item.caseNo }}</span>
@@ -184,6 +199,13 @@
       </div>
       <div style="text-align: right;color: #8890B1;font-size: 16px;">
         合计(吨):{{ total }}/{{ deptBudgetList.weight }}
+         <!--阶段状态-->
+         <span class="noservice" v-show="deptBudgetList.feedbackStatus=='执行中'">
+          未完货
+        </span>
+        <span class="service" v-show="deptBudgetList.feedbackStatus=='已完货'">{{
+          deptBudgetList.feedbackStatus
+        }}</span>
       </div>
     </ws-form>
     <!-- 提交 -->
@@ -829,4 +851,21 @@ margin-top: 20px;
   color: #5473e8;
   line-height: 24px;
 }
+//送达/未送达
+.noservice,
+.service {
+  display: inline-block;
+  border-radius: 4px;
+  border: 1px solid #d8dce6;
+  padding: 2px;
+  font-size: 12px;
+}
+.noservice {
+  background: #c4cada;
+  color: #ffffff;
+}
+.service {
+  background: #e5f1f7;
+  color: #50cad4;
+}
 </style>

+ 74 - 2
src/views/tranManagement/tranManagementTransporFeedback.vue

@@ -89,7 +89,17 @@
           {{ deptBudgetList.contractNo }}
         </ws-form-item>
       </ws-info-table>
-      <div class="small-title" style="font-size: 16px">装车详情</div>
+      <div class="small-title" style="font-size: 16px; width: 50%;float: left;">装车详情</div>
+          <!-- 导入 -->
+      <div style="font-size: 16px; width: 50%;float: left;text-align: right;">
+      <el-button
+        class="bg-bottom"
+        type="primary"
+        size="small"
+        @click="import(deptBudgetList)"
+        >导入</el-button
+      >
+    </div>
       <div class="liaison">
         <div
           style="width: 100%"
@@ -198,6 +208,16 @@
             <!--装车日期-->
             <el-form-item label="装车日期:" span="1" prop="sendDateStart" >
             <ws-date-picker
+              v-if="item.status == '已装车'||item.status == '已送达'" 
+              :disabled="readonly"
+              v-model="item.sendDateStart"
+              type="date"
+              style="width: 150px;"
+              placeholder="请选择日期"
+              value-format="yyyy-MM-dd"
+            />
+               <ws-date-picker
+              v-else
               v-model="item.sendDateStart"
               type="date"
               style="width: 150px;"
@@ -285,12 +305,19 @@
         @click="submit(deptBudgetList)"
         >提交</el-button
       >
+      <el-button
+        class="bg-bottom"
+        type="primary"
+        size="small"
+        @click="finished (deptBudgetList)"
+        >完货</el-button
+      >
     </div>
   </div>
 </template>
 <script>
 import { regionData, CodeToText, TextToCode } from 'element-china-area-data'
-import { seeCat, packList, feedback, getbank } from '@/model/transport/index'
+import { seeCat, packList, feedback, getbank ,state} from '@/model/transport/index'
 import { getstaff } from '@/model/warehouse/index'
 import WsUpload from '@/components/WsUpload'
 import mapDrag from '@/components/mapdrag/mapdrag'
@@ -482,6 +509,42 @@ export default {
     handleClose() {
       this.accessoryTFs = false
     },
+    //导入
+    import(){
+
+    },
+    finished(){
+       this.$confirm(`完货操作后,装车信息不可修改,是否确定完货?`, {
+        confirmButtonText: '确定',
+        cancelButtonText: '取消',
+        type: 'warning',
+      })
+        .then(() => {
+          this.$refs.deptBudgetList.validate((valid) => {
+            if (valid) {
+              var tranProcessInfo = {}
+              tranProcessInfo.id = this.deptBudgetList.id
+              state(tranProcessInfo)
+                .toPromise()
+                .then((response) => {
+                  this.$message.success('完货成功')
+                  this.deptBudgetList = {}
+                  this.freightspace = {}
+                  this.selectedOptions = ''
+                  this.$router.push({
+                    path: 'tranManagementTransporHairRespond',
+                  })
+                })
+            } else {
+              return false
+            }
+          })
+        })
+        .catch(() => {
+          return false
+        })
+
+    },
     submit() {
       for (var i = 0; i < this.freightspace.length; i++) {
         if (this.freightspace[i].temporaryDriverFlag != 0) {
@@ -1029,6 +1092,15 @@ export default {
   margin-top: 6px;
   left: 2px;
 }
+//送达/未送达
+.noservice,
+.service {
+  display: inline-block;
+  border-radius: 4px;
+  border: 1px solid #d8dce6;
+  padding: 2px;
+  font-size: 12px;
+}
 .noservice {
   background: #c4cada;
   color: #ffffff;

+ 9 - 0
src/views/tranManagement/tranManagementTransporFeedbackLook.vue

@@ -828,6 +828,15 @@ export default {
   color: #5473e8;
   line-height: 24px;
 }
+//送达/未送达
+.noservice,
+.service {
+  display: inline-block;
+  border-radius: 4px;
+  border: 1px solid #d8dce6;
+  padding: 2px;
+  font-size: 12px;
+}
 .noservice {
   background: #c4cada;
   color: #ffffff;