浏览代码

Merge branch 'dev' of http://git.echepei.com/caojunjie/Smart_platform_ui into dev

QuKatie 3 年之前
父节点
当前提交
77845bd99b

+ 8 - 4
src/page/index/top/top-notice.vue

@@ -30,6 +30,7 @@
 
 <script>
   import { getMsgLogs , getMsgDetail,getMessage } from "@/api/logs";
+  import { getToken } from "@/util/auth";
 export default {
   name: "top-notice",
   data () {
@@ -110,10 +111,13 @@ export default {
       console.log("socket已经关闭")
     },
     assistMessage(){
-      //辅助消息接口
-      getMessage().then(res=>{
-        this.getMessage(JSON.stringify(res))
-      })
+      // 判断是否有token
+      if (getToken() !== undefined) {
+        //辅助消息接口
+        getMessage().then(res=>{
+          this.getMessage(JSON.stringify(res))
+        })
+      }
     },
     goUrl(row){
       if(row.url){

+ 2 - 3
src/views/basicData/customerInformation/detailsPageEdit.vue

@@ -1207,10 +1207,9 @@ export default {
                 );
               }
               this.form = res.data.data;
+              this.contactsData = res.data.data.corpsAttnList
               if (this.form.belongtoarea) {
-                this.form.belongtoarea = this.form.belongtoarea
-                  .split(",")
-                  .map(item => item.split("/"));
+                this.form.belongtoarea = this.form.belongtoarea.split(",").map(item => item.split("/"));
               }
               this.disabled = false;
             }

+ 2 - 0
src/views/dealer/purchase/detail.vue

@@ -142,6 +142,7 @@
                 type="primary"
                 size="small"
                 icon="el-icon-upload"
+                :disabled="disabled || confirmDisabled"
               >导 入</el-button>
             </el-upload>
           </template>
@@ -1332,6 +1333,7 @@ export default {
       res.data.forEach(item => {
       })
       this.dataList = this.dataList.concat(res.data)
+      this.$message.success('导入成功')
     },
     uploadError(err, file, fileList) {
       this.openFullScreen(true)

+ 2 - 0
src/views/dealer/purchaseContract/detail.vue

@@ -167,6 +167,7 @@
                 type="primary"
                 size="small"
                 icon="el-icon-upload"
+                :disabled="disabled || confirmDisabled || checkDisabled"
               >导 入</el-button>
             </el-upload>
           </template>
@@ -1404,6 +1405,7 @@ export default {
       res.data.forEach(item => {
       })
       this.dataList = this.dataList.concat(res.data)
+      this.$message.success('导入成功')
     },
     uploadError(err, file, fileList) {
       this.openFullScreen(true)

+ 9 - 6
src/views/financialManagement/paymentSettle/paymentSettleDetailsPage.vue

@@ -571,7 +571,7 @@
       confirmSettlement(status){
         this.$refs["form"].validate((valid,done) => {
           done();
-          if(valid && this.verificationData()){
+          if(valid && this.verificationData('付费')){
             this.$confirm("是否确认" + (this.financeDisabled? '付费': '撤销付费'), "提示", {
               confirmButtonText: "确认",
               cancelButtonText: "取消",
@@ -631,7 +631,7 @@
           }
         })
       },
-      saveSettlement(){
+      saveSettlement(type){
         this.$refs["form"].validate((valid,done) => {
           if(valid){
             for (let i = 0; i < this.dataList.length; i++) {
@@ -655,14 +655,14 @@
               this.$message.success("操作成功!")
               // this.detailData.disabled = true
               // this.editDisable = true
-              this.afterEcho(res.data.data)
+              this.afterEcho(res.data.data, type)
               done();
             }).finally(()=>{
               this.buttonLoading = false
             })
           }})
       },
-      async afterEcho(data){
+      async afterEcho(data, type){
         this.form = data;
         this.financeDisabled =  this.form.financeStatus == "待结算"?true:false;
         if (this.category == 2) {
@@ -703,8 +703,11 @@
           this.dataList = data.itemsList
           this.oldDataList = this.deepClone(data.itemsList)
         }
+        if (type == '付费') {
+          this.confirmSettlement()
+        }
       },
-      verificationData(){
+      verificationData(type){
         if(contrastObj(this.form,this.oldForm) || contrastList(this.dataList,this.oldDataList)
         ){
           this.$confirm("数据发生变化,请先提交保存!", "提示", {
@@ -712,7 +715,7 @@
             cancelButtonText: "取消",
             type: "warning",
           }).then(() => {
-            this.saveSettlement()
+            this.saveSettlement(type)
           }).catch(()=>{
             return false
           })

+ 13 - 8
src/views/financialManagement/receiptSettle/receiptSettleDetailsPage.vue

@@ -11,16 +11,18 @@
             size="small"
             @click="editHandle"
             v-if="editDisable"
+            :loading="buttonLoading"
           >编 辑</el-button>
           <el-button type="primary"
                      size="small"
                      :disabled="!form.id || editDisable"
                      @click="postMessage"
+                     :loading="buttonLoading"
           >发送消息</el-button>
           <el-button type="warning"
                      size="small"
                      class="el-button--small-yh"
-                     :buttonLoading="buttonLoading"
+                     :loading="buttonLoading"
                      :disabled="!form.id || editDisable"
                      @click.stop="confirmSettlement"
           >{{financeDisabled?"收费":"撤销收费"}}
@@ -28,7 +30,7 @@
           <el-button class="el-button--small-yh"
                      type="primary"
                      size="small"
-                     :buttonLoading="buttonLoading"
+                     :loading="buttonLoading"
                      :disabled="!financeDisabled || editDisable"
                      @click.stop="saveSettlement"
           >保存数据
@@ -609,7 +611,7 @@
         if (!this.form.corpId) return this.$message.error('往来单位不能为空')
         this.$refs["form"].validate((valid,done) => {
           done();
-          if(valid && this.verificationData()){
+          if(valid && this.verificationData('收费')){
             this.$confirm("是否确认" + (this.financeDisabled? '收费': '撤销收费'), "提示", {
               confirmButtonText: "确认",
               cancelButtonText: "取消",
@@ -669,7 +671,7 @@
           }
         })
       },
-      saveSettlement(){
+      saveSettlement(type){
         this.$refs["form"].validate((valid,done) => {
           done();
           if(valid){
@@ -695,13 +697,13 @@
               this.$message.success("操作成功!")
               // this.detailData.disabled = true
               // this.editDisable = true
-              this.afterEcho(res.data.data)
+              this.afterEcho(res.data.data, type)
             }).finally(()=>{
               this.buttonLoading = false
             })
           }})
       },
-      async afterEcho(data){
+      async afterEcho(data, type){
         this.form = data;
         this.financeDisabled = this.form.financeStatus === "待结算"?true:false;
         // 溢付款余额获取
@@ -741,8 +743,11 @@
           this.dataList = data.itemsList
           this.oldDataList = this.deepClone(data.itemsList)
         }
+        if (type == '收费') {
+          this.confirmSettlement()
+        }
       },
-      verificationData(){
+      verificationData(type){
         if(contrastObj(this.form,this.oldForm) || contrastList(this.dataList,this.oldDataList)
         ){
           this.$confirm("数据发生变化,请先提交保存!", "提示", {
@@ -750,7 +755,7 @@
             cancelButtonText: "取消",
             type: "warning",
           }).then(() => {
-            this.saveSettlement()
+            this.saveSettlement(type)
           }).catch(()=>{
             return false
           })

+ 36 - 16
src/views/landTransportation/dispatchingCars/detailPage.vue

@@ -393,6 +393,8 @@ import {
   dispatchCollection,
   cancelDispatchCollection, dispatchBatch, fleetDriverSave, recordingDetails, changeFleet
 } from "@/api/landTransportation";
+import website from "@/config/website";
+import {getDeptTree} from "@/api/system/dept";
 
 export default {
   props: {
@@ -874,14 +876,6 @@ export default {
             trigger: "change"
           }],
         }, {
-          label: '业务员',
-          prop: 'salesman',
-          rules: [{
-            required: true,
-            message: " ",
-            trigger: "blur"
-          }]
-        }, {
           label: '业务员部门',
           prop: 'salesmanDept',
           type: "tree",
@@ -891,18 +885,32 @@ export default {
             label: "title"
           }
         }, {
+          label: '业务员',
+          prop: 'salesman',
+          type: "select",
+          dicUrl: "/api/blade-user/userList",
+          props: {
+            label: "realName",
+            value: "id"
+          },
+          rules: [{
+            required: true,
+            message: " ",
+            trigger: "blur"
+          }]
+        }, {
           label: '委托日期',
           prop: 'bsDate',
           type: "datetime",
           format: 'yyyy-MM-dd HH:mm:ss',
           valueFormat: 'yyyy-MM-dd HH:mm:ss',
         }, {
-          label: '联系电话',
-          prop: 'tel'
-        }, {
           label: '票据号',
           prop: 'receiptNo'
         }, {
+          label: '联系电话',
+          prop: 'tel'
+        }, {
           label: '提单号',
           prop: 'billNo',
           rules: [{
@@ -977,8 +985,8 @@ export default {
             prop: 'etd',
             type: 'date'
           }, {
-            label: '截港日期',
-            prop: 'etc',
+            label: '预配箱量',
+            prop: 'expectCtnQty',
             type: 'date'
           }, {
             label: '起运港',
@@ -987,8 +995,8 @@ export default {
             label: '目的港',
             prop: 'podId'
           }, {
-            label: '预配箱量',
-            prop: 'expectCtnQty',
+            label: '截港日期',
+            prop: 'etc',
             type: 'date'
           }, {
             label: '截单日期',
@@ -1244,6 +1252,12 @@ export default {
       })
     }
     this.$refs.other.show = false
+    // 非租户模式默认加载管理组数据
+    if (!website.tenantMode) {
+      this.initData(website.tenantId);
+    } else {
+      this.initData();
+    }
   },
   methods: {
     //自定义列保存
@@ -1273,7 +1287,6 @@ export default {
       this.formData.fleetName = val.cname
     },
     confirmChange(){
-      console.log(this.form.id)
       changeFleet({
         ...this.formData,
         id: this.formDataList.id,
@@ -1286,6 +1299,13 @@ export default {
         this.$message.success("变更成功");
       })
     },
+    //查询业务部门
+    initData(tenantId) {
+      getDeptTree(tenantId).then(res => {
+        const column = this.findObject(this.goodsOptionForm.column, "salesmanDept");
+        column.dicData = res.data.data;
+      });
+    },
     //多选触发
     selectionChange(list) {
       this.selectionList = list

+ 3 - 0
src/views/landTransportation/dispatchingCars/index.vue

@@ -51,6 +51,7 @@
     </basic-container>
     <basic-container v-show="show">
       <avue-crud
+          :key="key"
           :table-loading="loading"
           :data="dataList"
           :page.sync="page"
@@ -116,6 +117,7 @@ export default {
       id: '',
       show: true,
       loading: false,
+      key:0,
       dataList: [],
       totalData: {},
       page: {
@@ -277,6 +279,7 @@ export default {
   },
   async created() {
     this.option = await this.getColumnData(this.getColumnName(86), this.optionList);
+    this.key++
     let i = 0;
     this.option.column.forEach(item => {
       if (item.search) i++

+ 11 - 11
src/views/landTransportation/placeAnOrder/detailPage.vue

@@ -898,14 +898,6 @@ export default {
             trigger: "change"
           }],
         }, {
-          label: '业务员',
-          prop: 'salesman',
-          rules: [{
-            required: true,
-            message: " ",
-            trigger: "blur"
-          }]
-        }, {
           label: '业务员部门',
           prop: 'salesmanDept',
           type: "tree",
@@ -915,18 +907,26 @@ export default {
             label: "title"
           }
         }, {
+          label: '业务员',
+          prop: 'salesman',
+          rules: [{
+            required: true,
+            message: " ",
+            trigger: "blur"
+          }]
+        }, {
           label: '委托日期',
           prop: 'bsDate',
           type: "datetime",
           format: 'yyyy-MM-dd HH:mm:ss',
           valueFormat: 'yyyy-MM-dd HH:mm:ss',
         }, {
-          label: '联系电话',
-          prop: 'tel'
-        }, {
           label: '票据号',
           prop: 'receiptNo'
         }, {
+          label: '联系电话',
+          prop: 'tel'
+        }, {
           label: '提单号',
           prop: 'billNo',
           rules: [{

+ 7 - 5
src/views/landTransportation/placeAnOrder/index.vue

@@ -334,11 +334,13 @@ export default {
       }
     }
   },
-  // activated() {
-  //   if (this.$route.query.params){
-  //     this.rowCell({id:this.$route.query.params},0)
-  //   }
-  // },
+  activated() {
+    if (this.$route.query.id){
+      this.rowCell({id:this.$route.query.id},0)
+      this.$router.$avueRouter.closeTag(window.location.hash.slice(1))
+      this.$router.push({ query: {} });
+    }
+  },
   async created() {
     this.option = await this.getColumnData(this.getColumnName(85), this.optionList);
     this.key++

+ 1 - 1
src/views/wel/home/landTransportation/components/quick-launch.vue

@@ -25,7 +25,7 @@
         </div>
         <div class="content-icon" @click="inPage('lytz')">
           <i class="tradingIcon icon-sales" style="color:#143056"></i>
-          <span>陆运台账</span>
+          <span>台账</span>
         </div>
       </div>
     </el-card>

+ 4 - 4
src/views/wel/home/landTransportation/components/sales-reached.vue

@@ -14,13 +14,13 @@
         </span>
       </div>
       <div class="content" v-loading="loading">
-        <div style="width: 100%;height: 560px;display: flex;justify-content: space-around;flex-wrap: wrap">
+        <div style="width: 100%;height: 350px;display: flex;justify-content: space-around;flex-wrap: wrap">
           <div id="totalContainer" style="width: 26%;height: 210px;"></div>
           <div id="totalBulkCargo" style="width: 26%;height: 210px;"></div>
           <div id="specialTotal" style="width: 26%;height: 210px;"></div>
-          <div id="totalContainerTwo" style="width: 26%;height: 210px;"></div>
-          <div id="totalBulkCargoTwo" style="width: 26%;height: 210px;"></div>
-          <div id="specialTotalTwo" style="width: 26%;height: 210px;"></div>
+<!--          <div id="totalContainerTwo" style="width: 26%;height: 210px;"></div>-->
+<!--          <div id="totalBulkCargoTwo" style="width: 26%;height: 210px;"></div>-->
+<!--          <div id="specialTotalTwo" style="width: 26%;height: 210px;"></div>-->
         </div>
       </div>
     </el-card>

+ 20 - 13
src/views/wel/home/landTransportation/components/sales-trend.vue

@@ -4,7 +4,7 @@
       <div>
         <div class="title">
           <span>
-            运行车辆
+            今日业务详情(集装箱)
           </span>
           <span>
             <i
@@ -53,7 +53,7 @@
               prop="billNo">
               <template slot-scope="{row}">
                 <span class="el-button--text" style="cursor: pointer"
-                      @click="openTrack(row)">{{ row.billNo }}</span>
+                      @click="openTrack(row,0)">{{ row.billNo }}</span>
               </template>
             </el-table-column>
             <el-table-column
@@ -63,7 +63,7 @@
               prop="billNo">
               <template slot-scope="{row}">
                 <span class="el-button--text" style="cursor: pointer"
-                      @click="openTrack(row)">{{ row.plateNo }}</span>
+                      @click="openTrack(row,1)">{{ row.plateNo }}</span>
               </template>
             </el-table-column>
             <el-table-column
@@ -192,16 +192,23 @@ export default {
     this.map && this.map.destroy();
   },
   methods: {
-    openTrack(row){
-      this.dialogVisible = true
-      gaude({itemId: row.id,plateNo:row.plateNo}).then(res => {
-        this.lineArr = res.data.data
-        this.initMap();
-      })
-      location({itemId: row.id,plateNo:'陕YH0008'}).then(res => {
-        // console.log(res.data.data)
-        // console.log(this.lineArr[this.lineArr.length - 1])
-      })
+    openTrack(row,index){
+      if (index == 0){
+        this.$router.push({
+          path: '/landTransportation/placeAnOrder/index',
+          query: {id:row.orderId},
+        });
+      }else {
+        gaude({itemId: row.id,plateNo:row.plateNo}).then(res => {
+          this.lineArr = res.data.data
+          this.dialogVisible = true
+          this.initMap();
+        })
+        location({itemId: row.id,plateNo:'陕YH0008'}).then(res => {
+          // console.log(res.data.data)
+          // console.log(this.lineArr[this.lineArr.length - 1])
+        })
+      }
     },
     initMap() {
       this.map = new AMap.Map("container", {

+ 1 - 1
src/views/wel/home/landTransportation/landTransportation.vue

@@ -58,7 +58,7 @@ export default {
   width: 100%;
   height: 95.5vh;
   grid-template-columns: repeat(auto-fill, 10%);
-  grid-template-rows: 140px 600px 480px;
+  grid-template-rows: 140px 300px 480px;
   grid-template-areas:
     "a a a a a a a a a a"
     "b b b b b b b b b b"

+ 23 - 4
src/views/workManagement/handoverSheet/detail.vue

@@ -111,6 +111,25 @@
               ></el-option>
             </el-select>
           </template>
+          <template slot="handingUserName">
+            <el-select
+              v-model="form.handingUserName"
+              filterable
+              clearable
+              allow-create
+              default-first-option
+              size="small"
+              placeholder="请选择"
+              :disabled="disabled || checkDisabled || form.chargeStatus == 0 || confirmDisabled"
+            >
+              <el-option
+                v-for="(item,index) in userList"
+                :key="index"
+                :label="item.realName"
+                :value="item.realName"
+              ></el-option>
+            </el-select>
+          </template>
           <template slot="external">
             <el-switch
               v-model="form.external"
@@ -328,7 +347,7 @@ export default {
   data() {
     const validateHandingUser = (rule, value, callback) => {
       if (this.form.chargeStatus == 1 && !this.form.handingUser) {
-        callback(new Error('接人不能为空'))
+        callback(new Error('接人不能为空'))
       } else {
         callback()
       }
@@ -392,7 +411,7 @@ export default {
             span: 8,
           },
           {
-            label: "接人",
+            label: "接人",
             prop: "handingUser",
             span: 8,
             rules: [
@@ -738,9 +757,9 @@ export default {
     chargeStatusChange(data) {
       if (data === 0) this.form.handingUser = null;
     },
-    // 接人选择触发
+    // 接人选择触发
     handingUserChange(data) {
-      this.$set(this.form, 'handingUserName', this.userList.find(item => data == item.id).realName);
+      this.$set(this.form, 'handingUserName', this.userList.find(item => data == item.id)? this.userList.find(item => data == item.id).realName: null);
     },
     // 提交确认
     submitConfirm() {