Bladeren bron

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

qukaidi 2 jaren geleden
bovenliggende
commit
9aa2b591a6

+ 3 - 0
src/App.vue

@@ -37,4 +37,7 @@ export default {
 .el-dialog__headerbtn {
   top: 9px !important;
 }
+.el-dialog__headerbtn{
+  margin-top: 5px !important;
+}
 </style>

+ 232 - 222
src/views/desk/notice.vue

@@ -27,175 +27,188 @@
                    @click="handleDelete">删 除
         </el-button>
       </template>
+      <template slot="fileListForm">
+        <c-upload :basic="true" :data="form.fileList"></c-upload>
+      </template>
       <template slot-scope="{row}"
                 slot="category">
-        <el-tag>{{row.categoryName}}</el-tag>
+        <el-tag>{{ row.categoryName }}</el-tag>
       </template>
     </avue-crud>
   </basic-container>
 </template>
 
 <script>
-  import {getList, remove, update, add, getNotice} from "@/api/desk/notice";
-  import {mapGetters} from "vuex";
+import {getList, remove, update, add, getNotice} from "@/api/desk/notice";
+import {mapGetters} from "vuex";
 
-  export default {
-    data() {
-      return {
-        form: {},
-        query: {},
-        loading: true,
-        page: {
-          pageSize: 10,
-          currentPage: 1,
-          total: 0
-        },
-        selectionList: [],
-        option: {
-          height: 'auto',
-          calcHeight: 30,
-          dialogWidth: 950,
-          tip: false,
-          searchShow: true,
-          searchMenuSpan: 6,
-          border: true,
-          index: true,
-          viewBtn: true,
-          selection: true,
-          excelBtn: true,
-          dialogClickModal: false,
-          column: [
-            {
-              label: "通知标题",
-              prop: "title",
-              span: 24,
-              row: true,
-              search: true,
-              rules: [{
-                required: true,
-                message: "请输入通知标题",
-                trigger: "blur"
-              }]
+export default {
+  data() {
+    return {
+      form: {},
+      query: {},
+      loading: true,
+      page: {
+        pageSize: 10,
+        currentPage: 1,
+        total: 0
+      },
+      selectionList: [],
+      option: {
+        height: 'auto',
+        calcHeight: 30,
+        dialogWidth: 950,
+        tip: false,
+        searchShow: true,
+        searchMenuSpan: 6,
+        border: true,
+        index: true,
+        viewBtn: true,
+        selection: true,
+        excelBtn: true,
+        dialogClickModal: false,
+        column: [
+          {
+            label: "通知标题",
+            prop: "title",
+            span: 12,
+            // row: true,
+            search: true,
+            rules: [{
+              required: true,
+              message: "请输入通知标题",
+              trigger: "blur"
+            }]
+          }, {
+            label: "发送范围",
+            prop: "sendRange",
+            span: 12
+          },
+          {
+            label: "通知类型",
+            type: "select",
+            dicUrl: "/api/blade-system/dict/dictionary?code=notice",
+            props: {
+              label: "dictValue",
+              value: "dictKey"
             },
-            {
-              label: "通知类型",
-              type: "select",
-              dicUrl: "/api/blade-system/dict/dictionary?code=notice",
+            dataType: "number",
+            slot: true,
+            prop: "category",
+            search: true,
+            rules: [{
+              required: true,
+              message: "请输入通知类型",
+              trigger: "blur"
+            }]
+          },
+          {
+            label: "通知时间",
+            prop: "releaseTimeRange",
+            type: "datetime",
+            format: "yyyy-MM-dd hh:mm:ss",
+            valueFormat: "yyyy-MM-dd hh:mm:ss",
+            searchRange: true,
+            hide: true,
+            addDisplay: false,
+            editDisplay: false,
+            viewDisplay: false,
+            search: true,
+            rules: [{
+              required: true,
+              message: "请输入通知时间",
+              trigger: "blur"
+            }]
+          },
+          {
+            label: "通知日期",
+            prop: "releaseTime",
+            type: "datetime",
+            format: "yyyy-MM-dd hh:mm:ss",
+            valueFormat: "yyyy-MM-dd hh:mm:ss",
+            rules: [{
+              required: true,
+              message: "请输入通知日期",
+              trigger: "click"
+            }]
+          },
+          {
+            label: "通知内容",
+            prop: "content",
+            component: 'AvueUeditor',
+            options: {
+              action: '/api/blade-resource/oss/endpoint/put-file',
               props: {
-                label: "dictValue",
-                value: "dictKey"
-              },
-              dataType: "number",
-              slot: true,
-              prop: "category",
-              search: true,
-              rules: [{
-                required: true,
-                message: "请输入通知类型",
-                trigger: "blur"
-              }]
-            },
-            {
-              label: "通知时间",
-              prop: "releaseTimeRange",
-              type: "datetime",
-              format: "yyyy-MM-dd hh:mm:ss",
-              valueFormat: "yyyy-MM-dd hh:mm:ss",
-              searchRange:true,
-              hide: true,
-              addDisplay: false,
-              editDisplay: false,
-              viewDisplay: false,
-              search: true,
-              rules: [{
-                required: true,
-                message: "请输入通知时间",
-                trigger: "blur"
-              }]
+                res: "data",
+                url: "link",
+              }
             },
-            {
-              label: "通知日期",
-              prop: "releaseTime",
-              type: "date",
-              format: "yyyy-MM-dd hh:mm:ss",
-              valueFormat: "yyyy-MM-dd hh:mm:ss",
-              rules: [{
-                required: true,
-                message: "请输入通知日期",
-                trigger: "click"
-              }]
-            },
-            {
-              label: "通知内容",
-              prop: "content",
-              component: 'AvueUeditor',
-              options: {
-                action: '/api/blade-resource/oss/endpoint/put-file',
-                props: {
-                  res: "data",
-                  url: "link",
-                }
-              },
-              hide: true,
-              minRows: 6,
-              span: 24,
-            }
-          ]
-        },
-        data: []
+            hide: true,
+            minRows: 6,
+            span: 24,
+          }, {
+            hide: true,
+            showColumn: false,
+            label: "附件明细",
+            prop: "fileList",
+            span: 24,
+          },
+        ]
+      },
+      data: []
+    };
+  },
+  computed: {
+    ...mapGetters(["permission"]),
+    permissionList() {
+      return {
+        addBtn: this.vaildData(this.permission.notice_add, false),
+        viewBtn: this.vaildData(this.permission.notice_view, false),
+        delBtn: this.vaildData(this.permission.notice_delete, false),
+        editBtn: this.vaildData(this.permission.notice_edit, false)
       };
     },
-    computed: {
-      ...mapGetters(["permission"]),
-      permissionList() {
-        return {
-          addBtn: this.vaildData(this.permission.notice_add, false),
-          viewBtn: this.vaildData(this.permission.notice_view, false),
-          delBtn: this.vaildData(this.permission.notice_delete, false),
-          editBtn: this.vaildData(this.permission.notice_edit, false)
-        };
-      },
-      ids() {
-        let ids = [];
-        this.selectionList.forEach(ele => {
-          ids.push(ele.id);
+    ids() {
+      let ids = [];
+      this.selectionList.forEach(ele => {
+        ids.push(ele.id);
+      });
+      return ids.join(",");
+    }
+  },
+  methods: {
+    rowSave(row, done, loading) {
+      add(row).then(() => {
+        this.onLoad(this.page);
+        this.$message({
+          type: "success",
+          message: "操作成功!"
         });
-        return ids.join(",");
-      }
+        done();
+      }, error => {
+        window.console.log(error);
+        loading();
+      });
     },
-    methods: {
-      rowSave(row, done, loading) {
-        add(row).then(() => {
-          this.onLoad(this.page);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
-        });
-      },
-      rowUpdate(row, index, done, loading) {
-        update(row).then(() => {
-          this.onLoad(this.page);
-          this.$message({
-            type: "success",
-            message: "操作成功!"
-          });
-          done();
-        }, error => {
-          window.console.log(error);
-          loading();
+    rowUpdate(row, index, done, loading) {
+      update(row).then(() => {
+        this.onLoad(this.page);
+        this.$message({
+          type: "success",
+          message: "操作成功!"
         });
-      },
-      rowDel(row) {
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
+        done();
+      }, error => {
+        window.console.log(error);
+        loading();
+      });
+    },
+    rowDel(row) {
+      this.$confirm("确定将选择数据删除?", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      })
           .then(() => {
             return remove(row.id);
           })
@@ -206,34 +219,34 @@
               message: "操作成功!"
             });
           });
-      },
-      searchReset() {
-        this.query = {};
-        this.onLoad(this.page);
-      },
-      searchChange(params, done) {
-        this.query = params;
-        this.page.currentPage = 1;
-        this.onLoad(this.page, params);
-        done();
-      },
-      selectionChange(list) {
-        this.selectionList = list;
-      },
-      selectionClear() {
-        this.selectionList = [];
-        this.$refs.crud.toggleSelection();
-      },
-      handleDelete() {
-        if (this.selectionList.length === 0) {
-          this.$message.warning("请选择至少一条数据");
-          return;
-        }
-        this.$confirm("确定将选择数据删除?", {
-          confirmButtonText: "确定",
-          cancelButtonText: "取消",
-          type: "warning"
-        })
+    },
+    searchReset() {
+      this.query = {};
+      this.onLoad(this.page);
+    },
+    searchChange(params, done) {
+      this.query = params;
+      this.page.currentPage = 1;
+      this.onLoad(this.page, params);
+      done();
+    },
+    selectionChange(list) {
+      this.selectionList = list;
+    },
+    selectionClear() {
+      this.selectionList = [];
+      this.$refs.crud.toggleSelection();
+    },
+    handleDelete() {
+      if (this.selectionList.length === 0) {
+        this.$message.warning("请选择至少一条数据");
+        return;
+      }
+      this.$confirm("确定将选择数据删除?", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      })
           .then(() => {
             return remove(this.ids);
           })
@@ -245,50 +258,47 @@
             });
             this.$refs.crud.toggleSelection();
           });
-      },
-      beforeOpen(done, type) {
-        if (["edit", "view"].includes(type)) {
-          getNotice(this.form.id).then(res => {
-            this.form = res.data.data;
-          });
-        }
-        done();
-      },
-      currentChange(currentPage) {
-        this.page.currentPage = currentPage;
-      },
-      sizeChange(pageSize) {
-        this.page.pageSize = pageSize;
-      },
-      refreshChange() {
-        this.onLoad(this.page, this.query);
-      },
-      onLoad(page, params = {}) {
-        const {releaseTimeRange} = this.query;
-        let values = {
+    },
+    beforeOpen(done, type) {
+      if (["edit", "view"].includes(type)) {
+        getNotice(this.form.id).then(res => {
+          this.form = res.data.data;
+        });
+      }
+      done();
+    },
+    currentChange(currentPage) {
+      this.page.currentPage = currentPage;
+    },
+    sizeChange(pageSize) {
+      this.page.pageSize = pageSize;
+    },
+    refreshChange() {
+      this.onLoad(this.page, this.query);
+    },
+    onLoad(page, params = {}) {
+      const {releaseTimeRange} = this.query;
+      let values = {
+        ...params,
+      };
+      if (releaseTimeRange) {
+        values = {
           ...params,
+          releaseTime_datege: releaseTimeRange[0],
+          releaseTime_datelt: releaseTimeRange[1],
+          ...this.query
         };
-        if (releaseTimeRange) {
-          values = {
-            ...params,
-            releaseTime_datege: releaseTimeRange[0],
-            releaseTime_datelt: releaseTimeRange[1],
-            ...this.query
-          };
-          values.releaseTimeRange = null;
-        }
-        this.loading = true;
-        getList(page.currentPage, page.pageSize, values).then(res => {
-          const data = res.data.data;
-          this.page.total = data.total;
-          this.data = data.records;
-          this.loading = false;
-          this.selectionClear();
-        });
+        values.releaseTimeRange = null;
       }
+      this.loading = true;
+      getList(page.currentPage, page.pageSize, values).then(res => {
+        const data = res.data.data;
+        this.page.total = data.total;
+        this.data = data.records;
+        this.loading = false;
+        this.selectionClear();
+      });
     }
-  };
+  }
+};
 </script>
-
-<style>
-</style>

+ 16 - 6
src/views/landTransportation/bulkCargo/detailPage.vue

@@ -2095,12 +2095,17 @@ export default {
           decimals: 0
         }],
         column: [{
-          label: '公司名称',
-          width: 200,
-          slot: true,
-          overHidden: true,
-          prop: 'corpId',
-          index: 1
+          label: '客户名称',
+          cell: true,
+          width: 300,
+          prop: 'fleetId',
+          type: "select",
+          index: 1,
+          cascader: ['plateNo'],
+          props: {
+            label: "fleetName",
+            value: "fleetId"
+          }
         }, {
           label: '车号',
           prop: 'plateNo',
@@ -2214,6 +2219,7 @@ export default {
       if (this.id.slice(0, 4) === 'copy') {
         detailDelegationList({id: this.id.slice(4, this.id.length)}).then(res => {
           this.goodsForm = res.data.data
+          this.findObject(this.paymentOption.column, "fleetId").dicUrl = "/api/blade-land/order-fee/fleet?orderId=" + this.goodsForm.id
           this.tableData = res.data.data.loadingAddressList || []
           this.tableDataTwo = res.data.data.unloadedAddressList || []
           this.entrustList = res.data.data.itemList
@@ -2258,6 +2264,7 @@ export default {
         }
         detailDelegationList({id: this.id.slice(2, this.id.length)}).then(res => {
           this.goodsForm = res.data.data
+          this.findObject(this.paymentOption.column, "fleetId").dicUrl = "/api/blade-land/order-fee/fleet?orderId=" + this.goodsForm.id
           this.tableData = res.data.data.loadingAddressList || []
           this.tableDataTwo = res.data.data.unloadedAddressList || []
           this.entrustList = res.data.data.itemList
@@ -2291,6 +2298,7 @@ export default {
       } else {
         detailDelegationList({id: this.id}).then(res => {
           this.goodsForm = res.data.data
+          this.findObject(this.paymentOption.column, "fleetId").dicUrl = "/api/blade-land/order-fee/fleet?orderId=" + this.goodsForm.id
           if (this.roleName.indexOf('经理') !== -1 || this.roleName.indexOf('部门经理') !== -1 || this.roleName.indexOf('总经理') !== -1 || this.roleName.indexOf('总调度') !== -1) {
             this.goodsForm.status = 5
           }
@@ -2588,6 +2596,7 @@ export default {
       }
       detailDelegationList({id: ids}).then(res => {
         this.goodsForm = res.data.data
+        this.findObject(this.paymentOption.column, "fleetId").dicUrl = "/api/blade-land/order-fee/fleet?orderId=" + this.goodsForm.id
         this.tableData = res.data.data.loadingAddressList
         this.tableDataTwo = res.data.data.unloadedAddressList
         this.entrustList = res.data.data.itemList
@@ -2623,6 +2632,7 @@ export default {
     //切换收付费
     handleSelect(tab, event) {
       this.activeIndex = tab.name
+      this.key++
     },
     //箱信息保存
     rowSaveT(row, index, done, loading) {

+ 1 - 0
src/views/landTransportation/bulkReportAnalysis/index.vue

@@ -1232,6 +1232,7 @@ export default {
     incidentalConfirm(row) {
       incidental({
         orderId: row.orderId,
+        itemId: row.itemId,
         plateNo: row.plateNo,
         type: '1'
       }).then(res => {

+ 2 - 2
vue.config.js

@@ -31,10 +31,10 @@ module.exports = {
     proxy: {
       '/api': {
         //本地服务接口地址
-        // target: 'http://192.168.3.240:1080',
+        // target: 'http://192.168.1.150:1080',
         // target: 'http://192.168.1.102:1080',
         // target: 'http://124.222.119.174:1080',
-        // 打包地址.
+        // 打包地址
         // target: 'http://121.37.83.47:10004',//服务器ip
         target: 'http://trade.tubaosoft.com:10004',//服务器域名
         ws: true,