Browse Source

Merge remote-tracking branch 'origin/ecp' into ecp

纪新园 1 month ago
parent
commit
b2faa4d95d

+ 172 - 180
src/components/upload/index.vue

@@ -1,28 +1,69 @@
 <template>
   <div>
     <basic-container v-if="!basic">
-      <avue-crud :data="data" ref="crud" :option="option" :key="key" @resetColumn="resetColumn" @saveColumn="saveColumn">
+      <avue-crud
+        :data="data"
+        ref="crud"
+        :option="option"
+        :key="key"
+        @resetColumn="resetColumn"
+        @saveColumn="saveColumn"
+      >
         <template slot="menuLeft">
-          <el-button type="primary" size="small" icon="el-icon-edit" @click="addDetail" :disabled="disabled" v-if="display">上传 </el-button>
+          <el-button
+            type="primary"
+            size="small"
+            icon="el-icon-edit"
+            @click="addDetail"
+            :disabled="disabled"
+            v-if="display"
+            >上传
+          </el-button>
           <slot name="c_button"></slot>
         </template>
         <template slot="url" slot-scope="{ row }">
-          <el-input placeholder="请输入内容" size="small" v-if="row.$cellEdit" v-model="row.url" class="input-with-select">
+          <el-input
+            placeholder="请输入内容"
+            size="small"
+            v-if="row.$cellEdit"
+            v-model="row.url"
+            class="input-with-select"
+          >
             <el-button slot="append" @click="singleLineUpload(row)">附件</el-button>
           </el-input>
           <span v-else>{{ row.url }}</span>
         </template>
         <template slot-scope="scope" slot="menu">
-          <el-button icon="el-icon-download" :size="scope.size" :type="scope.type" @click="download(scope)">查看 </el-button>
-          <el-button :type="scope.type" :size="scope.size" icon="el-icon-edit" @click.stop="rowCell(scope.row, scope.index)" :disabled="disabled">
+          <el-button icon="el-icon-download" :size="scope.size" :type="scope.type" @click="download(scope)"
+            >查看
+          </el-button>
+          <el-button
+            :type="scope.type"
+            :size="scope.size"
+            icon="el-icon-edit"
+            @click.stop="rowCell(scope.row, scope.index)"
+            :disabled="disabled"
+          >
             {{ scope.row.$cellEdit ? "保存" : "修改" }}
           </el-button>
-          <el-button :type="scope.type" :size="scope.size" icon="el-icon-delete" @click.stop="rowDel(scope.row, scope.index)" :disabled="disabled"
+          <el-button
+            :type="scope.type"
+            :size="scope.size"
+            icon="el-icon-delete"
+            @click.stop="rowDel(scope.row, scope.index)"
+            :disabled="disabled"
             >删除
           </el-button>
         </template>
       </avue-crud>
-      <el-dialog title="上传附件" append-to-body :visible.sync="excelBox" width="555px" :close-on-click-modal="false" v-dialog-drag>
+      <el-dialog
+        title="上传附件"
+        append-to-body
+        :visible.sync="excelBox"
+        width="555px"
+        :close-on-click-modal="false"
+        v-dialog-drag
+      >
         <el-upload
           class="upload-demo"
           drag
@@ -36,12 +77,17 @@
         >
           <i class="el-icon-upload"></i>
           <div class="el-upload__text">将文件拖到此处,或<em>点击上传</em></div>
-          <div class="el-upload__tip" slot="tip">
-            如上传文件过大,请耐心等待上传成功
-          </div>
+          <div class="el-upload__tip" slot="tip">如上传文件过大,请耐心等待上传成功</div>
         </el-upload>
       </el-dialog>
-      <el-dialog title="修改附件" append-to-body :visible.sync="excelTwo" width="555px" :close-on-click-modal="false" v-dialog-drag>
+      <el-dialog
+        title="修改附件"
+        append-to-body
+        :visible.sync="excelTwo"
+        width="555px"
+        :close-on-click-modal="false"
+        v-dialog-drag
+      >
         <el-upload
           class="upload-demo"
           drag
@@ -54,35 +100,68 @@
         >
           <i class="el-icon-upload"></i>
           <div class="el-upload__text">将文件拖到此处,或<em>点击上传</em></div>
-          <div class="el-upload__tip" slot="tip">
-            如上传文件过大,请耐心等待上传成功
-          </div>
+          <div class="el-upload__tip" slot="tip">如上传文件过大,请耐心等待上传成功</div>
         </el-upload>
       </el-dialog>
       <PreviewImage :visible.sync="innerVisible" :currentIndex="0" :previewImgList="[imgUrl]" />
     </basic-container>
     <span v-else-if="true">
-      <avue-crud :data="data" ref="crud" :option="option" :key="key" @resetColumn="resetColumn" @saveColumn="saveColumn">
+      <avue-crud
+        :data="data"
+        ref="crud"
+        :option="option"
+        :key="key"
+        @resetColumn="resetColumn"
+        @saveColumn="saveColumn"
+      >
         <template slot="menuLeft">
-          <el-button type="primary" size="small" icon="el-icon-edit" @click="addDetail" :disabled="disabled">上传 </el-button>
+          <el-button type="primary" size="small" icon="el-icon-edit" @click="addDetail" :disabled="disabled"
+            >上传
+          </el-button>
         </template>
         <template slot="url" slot-scope="{ row }">
-          <el-input placeholder="请输入内容" size="small" v-if="row.$cellEdit" v-model="row.url" class="input-with-select">
+          <el-input
+            placeholder="请输入内容"
+            size="small"
+            v-if="row.$cellEdit"
+            v-model="row.url"
+            class="input-with-select"
+          >
             <el-button slot="append" @click="singleLineUpload(row)">附件</el-button>
           </el-input>
           <span v-else>{{ row.url }}</span>
         </template>
         <template slot-scope="scope" slot="menu">
-          <el-button icon="el-icon-download" :size="scope.size" :type="scope.type" @click="download(scope)">查看 </el-button>
-          <el-button :type="scope.type" :size="scope.size" icon="el-icon-edit" @click.stop="rowCell(scope.row, scope.index)" :disabled="disabled">
+          <el-button icon="el-icon-download" :size="scope.size" :type="scope.type" @click="download(scope)"
+            >查看
+          </el-button>
+          <el-button
+            :type="scope.type"
+            :size="scope.size"
+            icon="el-icon-edit"
+            @click.stop="rowCell(scope.row, scope.index)"
+            :disabled="disabled"
+          >
             {{ scope.row.$cellEdit ? "保存" : "修改" }}
           </el-button>
-          <el-button :type="scope.type" :size="scope.size" icon="el-icon-delete" @click.stop="rowDel(scope.row, scope.index)" :disabled="disabled"
+          <el-button
+            :type="scope.type"
+            :size="scope.size"
+            icon="el-icon-delete"
+            @click.stop="rowDel(scope.row, scope.index)"
+            :disabled="disabled"
             >删除
           </el-button>
         </template>
       </avue-crud>
-      <el-dialog title="上传附件" append-to-body :visible.sync="excelBox" width="555px" :close-on-click-modal="false" v-dialog-drag>
+      <el-dialog
+        title="上传附件"
+        append-to-body
+        :visible.sync="excelBox"
+        width="555px"
+        :close-on-click-modal="false"
+        v-dialog-drag
+      >
         <el-upload
           class="upload-demo"
           drag
@@ -96,12 +175,17 @@
         >
           <i class="el-icon-upload"></i>
           <div class="el-upload__text">将文件拖到此处,或<em>点击上传</em></div>
-          <div class="el-upload__tip" slot="tip">
-            如上传文件过大,请耐心等待上传成功
-          </div>
+          <div class="el-upload__tip" slot="tip">如上传文件过大,请耐心等待上传成功</div>
         </el-upload>
       </el-dialog>
-      <el-dialog title="修改附件" append-to-body :visible.sync="excelTwo" width="555px" :close-on-click-modal="false" v-dialog-drag>
+      <el-dialog
+        title="修改附件"
+        append-to-body
+        :visible.sync="excelTwo"
+        width="555px"
+        :close-on-click-modal="false"
+        v-dialog-drag
+      >
         <el-upload
           class="upload-demo"
           drag
@@ -114,9 +198,7 @@
         >
           <i class="el-icon-upload"></i>
           <div class="el-upload__text">将文件拖到此处,或<em>点击上传</em></div>
-          <div class="el-upload__tip" slot="tip">
-            如上传文件过大,请耐心等待上传成功
-          </div>
+          <div class="el-upload__tip" slot="tip">如上传文件过大,请耐心等待上传成功</div>
         </el-upload>
       </el-dialog>
 
@@ -137,33 +219,37 @@ export default {
   components: { PreviewImage },
   props: {
     data: {
-      type: Object
+      type: Object,
     },
     incomingAction: {
-      type: String
+      type: String,
     },
     deleteUrl: {
-      type: String
+      type: String,
     },
     enumerationValue: {
-      type: Number
+      type: Number,
     },
     typeUpload: {
-      type: String
+      type: String,
     },
     disabled: {
-      type: Boolean
+      type: Boolean,
     },
     display: {
-      type: Boolean
+      type: Boolean,
     },
     basic: {
-      type: Boolean
+      type: Boolean,
     },
     mainImageType: {
       type: Boolean,
-      default: false
-    }
+      default: false,
+    },
+    HW: {
+      type: Boolean,
+      default: false,
+    },
   },
   data() {
     return {
@@ -175,9 +261,8 @@ export default {
       action: "/api/blade-resource/oss/endpoint/put-file",
       headers: { "Blade-Auth": "Bearer " + getToken() },
       option: {},
-      key: 0,
-      originalOptions: {
-        dialogDrag: true,
+      option1: {
+        // dialogDrag: true,
         index: true,
         refreshBtn: false,
         cellBtn: false,
@@ -188,95 +273,51 @@ export default {
         align: "center",
         column: [
           {
-            label: "文件名称",
-            prop: "fileName",
+            label: "花纹",
+            prop: "figure",
             index: 1,
-            width: 140,
             cell: true,
-            overHidden: true
-          },
-          {
-            label: "文件地址",
-            prop: "url",
-            index: 2,
-            overHidden: true
-          },
-          {
-            type: "select",
-            dicUrl: "/api/blade-system/dict-biz/dictionary?code=file_type",
-            props: {
-              label: "dictValue",
-              value: "dictValue"
-            },
-            label: "文件属性",
-            prop: "paymentType",
-            search: false,
-            index: 3,
-            width: 140,
             overHidden: true,
-            cell: true
           },
           {
-            label: "备注",
-            prop: "remarks",
-            index: 4,
-            cell: true,
-            overHidden: true
-          }
-        ]
-      },
-      originalOptionsTwo: {
-        dialogDrag: true,
-        index: true,
-        refreshBtn: false,
-        cellBtn: false,
-        cancelBtn: false,
-        delBtn: false,
-        editBtn: false,
-        addBtn: false,
-        align: "center",
-        column: [
-          {
             label: "文件名称",
             prop: "fileName",
-            index: 1,
             width: 140,
             cell: true,
-            overHidden: true
+            overHidden: true,
           },
           {
             label: "文件地址",
             prop: "url",
-            index: 2,
-            overHidden: true
+            overHidden: true,
           },
           {
-            type: "select",
-            dicUrl: "/api/blade-system/dict-biz/dictionary?code=picture_type",
-            props: {
-              label: "dictValue",
-              value: "dictKey"
-            },
-            label: "文件属性",
-            prop: "version",
-            search: false,
-            index: 3,
+            label: this.mainImageType ? "是否主图" : "文件属性",
+            prop: "mainImage",
+            type: this.mainImageType ? "select" : "input",
+            dicData: [
+              {
+                label: "是",
+                value: 1,
+              },
+              {
+                label: "否",
+                value: 0,
+              },
+            ],
             width: 140,
             overHidden: true,
-            cell: true
+            cell: true,
           },
           {
             label: "备注",
             prop: "remarks",
-            index: 4,
             cell: true,
-            overHidden: true
-          }
-        ]
+            overHidden: true,
+          },
+        ],
       },
-      // 基础信息轮胎附件
-      originalOptionsTwo_LT: {
-        // dialogDrag: true,
+      option2: {
         index: true,
         refreshBtn: false,
         cellBtn: false,
@@ -291,101 +332,52 @@ export default {
             prop: "fileName",
             width: 140,
             cell: true,
-            overHidden: true
+            overHidden: true,
           },
           {
             label: "文件地址",
             prop: "url",
-            overHidden: true
+            overHidden: true,
           },
           {
-            label: this.mainImageType?"是否主图":"文件属性",
+            label: this.mainImageType ? "是否主图" : "文件属性",
             prop: "mainImage",
-            type: "select",
+            type: this.mainImageType ? "select" : "input",
             dicData: [
               {
                 label: "是",
-                value: 1
+                value: 1,
               },
               {
                 label: "否",
-                value: 0
-              }
+                value: 0,
+              },
             ],
             width: 140,
             overHidden: true,
-            cell: true
-          },
-          {
-            label: "备注",
-            prop: "remarks",
             cell: true,
-            overHidden: true
-          }
-        ]
-      },
-      originalOptionsThree: {
-        dialogDrag: true,
-        index: true,
-        refreshBtn: false,
-        cellBtn: false,
-        cancelBtn: false,
-        delBtn: false,
-        editBtn: false,
-        addBtn: false,
-        align: "center",
-        column: [
-          {
-            label: "文件名称",
-            prop: "fileName",
-            index: 1,
-            width: 140,
-            cell: true,
-            overHidden: true
-          },
-          {
-            label: "文件地址",
-            prop: "url",
-            index: 2,
-            overHidden: true
           },
           {
             label: "备注",
             prop: "remarks",
-            index: 4,
             cell: true,
-            overHidden: true
-          }
-        ]
+            overHidden: true,
+          },
+        ],
       },
-      uploadCount: 0
+      key: 0,
+      uploadCount: 0,
     };
   },
   async created() {
-    console.log(this.enumerationValue);
-    this.option = this.originalOptionsTwo_LT;
+    if (this.HW) {
+      this.option = this.option1;
+    } else {
+      this.option = this.option2;
+    }
     this.key++;
   },
   methods: {
-    //自定义列保存
-    async saveColumn() {
-      /**
-       * 已定义全局方法,直接使用,saveColumnData保存列数据方法,参数传值(表格名称,当前表格的option数据)
-       * 已定义全局方法,直接使用,getColumnName方法用来获取枚举值,参数根据自己定义的code值获取中文名
-       * 一定要执行异步操作,要等接口成功返回,才能执行下一行代码
-       */
-      const inSave = await this.saveColumnData(this.getColumnName(this.enumerationValue), this.option);
-      if (inSave) {
-        this.$message.success("保存成功");
-        //关闭窗口
-        this.$refs.crud.$refs.dialogColumn.columnBox = false;
-      }
-    },
-    //自定义列重置
-    async resetColumn() {
-      this.option = this.originalOptionsTwo_LT;
-      this.$message.success("重置成功");
-    },
     beforeUpload(file) {
       if (file.type == "image/jpeg" || file.type == "image/png" || file.type == "image/bmp") {
         const fileSize = file.size / 1024 / 1024;
@@ -405,7 +397,7 @@ export default {
     onSuccess(response, file, fileList) {
       this.$refs.crud.rowCellAdd({
         fileName: response.data.originalName,
-        url: response.data.link
+        url: response.data.link,
       });
       this.uploadCount++;
       if (this.uploadCount === fileList.length) {
@@ -463,26 +455,26 @@ export default {
       this.$confirm("确定将选择数据删除?", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning"
+        type: "warning",
       }).then(() => {
         console.log(row, 657);
         if (row.id) {
           if (this.typeUpload == "CK") {
-            updateListRemove(row.id, this.deleteUrl).then(res => {
+            updateListRemove(row.id, this.deleteUrl).then((res) => {
               if (res.data.success) {
                 this.$message.success("操作成功!");
                 this.data.splice(index, 1);
               }
             });
           } else if (this.typeUpload == "LT") {
-            LTfujianDelete({ ids: row.id }).then(res => {
+            LTfujianDelete({ ids: row.id }).then((res) => {
               if (res.data.success) {
                 this.$message.success("操作成功!");
                 this.data.splice(index, 1);
               }
             });
           } else {
-            sharedDeletion(this.deleteUrl, row.id).then(res => {
+            sharedDeletion(this.deleteUrl, row.id).then((res) => {
               if (res.data.success) {
                 this.$message.success("操作成功!");
                 this.data.splice(index, 1);
@@ -493,8 +485,8 @@ export default {
           this.data.splice(index, 1);
         }
       });
-    }
-  }
+    },
+  },
 };
 </script>
 

+ 14 - 0
src/router/views/index.js

@@ -495,5 +495,19 @@ export default [
             },
             component: () => import( /* webpackChunkName: "views" */ '@/views/warehouse/index.vue')
         }]
+    },
+    {
+        path: '/store/index',
+        component: Layout,
+        hidden: true,
+        children: [{
+            path: '/store/index',
+            name: '门店管理',
+            meta: {
+                i18n: '/store/index',
+                keepAlive: true,
+            },
+            component: () => import( /* webpackChunkName: "views" */ '@/views/store/index.vue')
+        }]
     }
 ];

+ 7 - 3
src/views/dealer/brand/detailsPage.vue

@@ -19,14 +19,14 @@
             <trade-card title="基础信息">
                 <avue-form :option="optionForm" v-model="form" ref="form"></avue-form>
             </trade-card>
-            <trade-card :title="titleType==1?'规格型号1附件信息':'花纹附件信息'">
+            <trade-card title="花纹附件信息">
                 <c-upload basic :data="form.brandFigureList" :disabled="disabled"
-                          deleteUrl="/api/blade-sales-part/brandfigure/remove" :enumerationValue="338" display/>
+                          deleteUrl="/api/blade-sales-part/brandfigure/remove" :HW="true" display/>
                 <!-- <span style="font-size: 12px;">(图片文件像素推荐700X750,有且只允许有一张主图,其余均为副图)</span> -->
             </trade-card>
             <trade-card title="附件信息">
                 <c-upload basic :data="form.brandFilesList" :disabled="disabled"
-                          deleteUrl="/api/blade-sales-part/brandfiles/remove" :enumerationValue="272.1" display/>
+                          deleteUrl="/api/blade-sales-part/brandfiles/remove" display/>
                 <!-- <span style="font-size: 12px;">(图片文件像素推荐700X750,有且只允许有一张主图,其余均为副图)</span> -->
             </trade-card>
         </div>
@@ -34,6 +34,7 @@
 </template>
 
 <script>
+// @ts-nocheck
 import {submit, getDetails, updateEnableOrNot} from "@/api/dealer/brand/brand";
 
 export default {
@@ -153,6 +154,9 @@ export default {
                 }
             }
             for (let item of this.form.brandFigureList) {
+                if(!item.figure){
+                     return this.$message.error('花纹附件信息的花纹不能为空!')
+                }
                 if (this.form.brandFigureList.filter(e => e.figure == item.figure).length > 1) {
                     return this.$message.error('花纹名称' + item.figure + '不能重复!')
                 }

+ 5 - 5
src/views/salesLead/index.vue

@@ -145,11 +145,11 @@ export default {
             width: 100,
             overHidden: true
           },
-          {
-            label: '索赔金额',
-            prop: 'claimAmount',
-            overHidden: true
-          },
+          // {
+          //   label: '索赔金额',
+          //   prop: 'claimAmount',
+          //   overHidden: true
+          // },
           {
             label: '线索状态',
             prop: 'status',

+ 31 - 25
src/views/store/detailsPage.vue

@@ -1,4 +1,3 @@
-
 <template>
   <div>
     <div class="borderless">
@@ -128,7 +127,12 @@
           @row-del="rowDelTwo"
         >
           <template slot="menuLeft">
-            <el-button type="primary" icon="el-icon-plus" size="small" @click.stop="$refs.crudTwo.rowAdd()" :disabled="option.disabled"
+            <el-button
+              type="primary"
+              icon="el-icon-plus"
+              size="small"
+              @click.stop="$refs.crudTwo.rowAdd()"
+              :disabled="option.disabled"
               >录入明细
             </el-button>
           </template>
@@ -501,6 +505,12 @@ export default {
             valueFormat: "yyyy-MM-01 00:00:00",
           },
           {
+            label: "备注",
+            prop: "remarks",
+            type: "textarea",
+            minRows: 2,
+          },
+          {
             label: "营业执照",
             prop: "businessLicenseUrl",
             type: "upload",
@@ -513,13 +523,6 @@ export default {
             action: "/api/blade-resource/oss/endpoint/put-file",
             headers: { "Blade-Auth": "Bearer " + getToken() },
           },
-          {
-            label: "备注",
-            prop: "remarks",
-            type: "textarea",
-            minRows: 2,
-            span: 24,
-          },
         ],
       },
       option2: {
@@ -746,7 +749,8 @@ export default {
         });
       }
       if (name == "审批") {
-        this.$confirm("是否撤销审批?", "提示", {
+        this.$confirm("是否通过审核?", "提示", {
+          distinguishCancelAndClose: true,
           confirmButtonText: "通过",
           cancelButtonText: "驳回",
           type: "warning",
@@ -761,15 +765,17 @@ export default {
               this.getDetail(this.form.id);
             });
           })
-          .catch(() => {
-            let obj = {
-              id: this.form.id,
-              type: 2,
-            };
-            review(obj).then((res) => {
-              this.$message.success("操作成功");
-              this.getDetail(this.form.id);
-            });
+          .catch((action) => {
+            if (action == "cancel") {
+              let obj = {
+                id: this.form.id,
+                type: 2,
+              };
+              review(obj).then((res) => {
+                this.$message.success("操作成功");
+                this.getDetail(this.form.id);
+              });
+            }
           });
       }
     },
@@ -802,8 +808,8 @@ export default {
     },
     // 启用或禁用
     editEnable() {
-      if(this.form.checkStatus != '审核通过'){
-        return  this.$message.error("审核通过以后可以启用");
+      if (this.form.checkStatus != "审核通过") {
+        return this.$message.error("审核通过以后可以启用");
       }
       let data = this.form;
       editenable({ id: data.id, enableOrNot: data.enableOrNot ? 0 : 1 }).then((res) => {
@@ -1001,16 +1007,16 @@ export default {
     creatingUsers(row) {
       console.log("row", row);
       if (!row.id) {
-        this.$message.error("请保存数据");
+        return this.$message.error("请保存数据");
       }
       if (!row.cname || !row.tel) {
-        this.$message.error("请完善联系人和电话");
+        return this.$message.error("请完善联系人和电话");
       }
       if (!row.id) {
-        this.$message.error("请保存数据");
+        return this.$message.error("请保存数据");
       }
       if (row.userId) {
-        this.$message.error("已创建,请勿重复操作");
+        return this.$message.error("已创建,请勿重复操作");
       }
       this.$confirm("是否创建用户?", "提示", {
         confirmButtonText: "确定",

+ 152 - 99
src/views/store/index.vue

@@ -3,10 +3,20 @@
     <basic-container v-show="show" class="page-crad">
       <el-row>
         <el-col :span="4">
-          <avue-tree :option="treeOption" :data="treeData" @node-click="nodeClick" style="height:73vh;" @save="corpTypeVisible = true">
+          <avue-tree
+            :option="treeOption"
+            :data="treeData"
+            @node-click="nodeClick"
+            style="height: 73vh"
+            @save="corpTypeVisible = true"
+          >
             <template slot="addBtn">
               <el-tooltip class="item" effect="dark" content="新建分类" placement="top">
-                <i class="el-icon-setting" style="font-size:18px;line-height: 30px;width: 20px;padding: 0 10px;" @click="corpTypeVisible = true"></i>
+                <i
+                  class="el-icon-setting"
+                  style="font-size: 18px; line-height: 30px; width: 20px; padding: 0 10px"
+                  @click="corpTypeVisible = true"
+                ></i>
               </el-tooltip>
             </template>
           </avue-tree>
@@ -28,7 +38,7 @@
             @search-criteria-switch="searchCriteriaSwitch"
           >
             <template slot="menuLeft">
-              <el-button type="primary" size="mini" @click.stop="newAdd()">新建客户 </el-button>
+              <el-button type="primary" size="mini"  icon="el-icon-plus" @click.stop="newAdd()">新建客户 </el-button>
               <!-- <el-button type="primary" size="mini" icon="el-icon-bottom" @click="excelBox = true">导入 </el-button>
               <el-button type="primary" size="mini" icon="el-icon-top" @click="outExport">导出 </el-button>
               <el-button type="primary" size="mini" icon="el-icon-download" @click="brandBox = true">
@@ -40,7 +50,7 @@
               <div v-else style="color: red">禁用</div>
             </template>
             <template slot-scope="{ row, index }" slot="cname">
-              <span style="color: #409EFF;cursor: pointer" @click.stop="editOpen(row, 2)">{{ row.cname }}</span>
+              <span style="color: #409eff; cursor: pointer" @click.stop="editOpen(row, 2)">{{ row.cname }}</span>
             </template>
             <template slot="dateSearch">
               <el-date-picker
@@ -70,7 +80,11 @@
                 @click.stop="passThrough(row, '驳回')"
                 >驳回
               </el-button> -->
-              <el-button :size="size" :type="type" :disabled="!(row.checkStatus == '录入' || row.checkStatus == '审核驳回')||row.enableOrNot==1" @click.stop="rowDel(row)"
+              <el-button
+                :size="size"
+                :type="type"
+                :disabled="row.enableOrNot == 1"
+                @click.stop="rowDel(row)"
                 >删除
               </el-button>
             </template>
@@ -96,26 +110,52 @@
         <el-button @click="addCorpType" type="primary" size="mini">确 定</el-button>
       </div>
     </el-dialog>
-    <el-dialog title="导入客户" append-to-body :visible.sync="excelBox" width="555px" :close-on-click-modal="false" v-dialog-drag>
-      <avue-form :option="excelOption" v-model="excelForm" table-loading="excelLoading" :upload-before="uploadBefore" :upload-after="uploadAfter">
+    <el-dialog
+      title="导入客户"
+      append-to-body
+      :visible.sync="excelBox"
+      width="555px"
+      :close-on-click-modal="false"
+      v-dialog-drag
+    >
+      <avue-form
+        :option="excelOption"
+        v-model="excelForm"
+        table-loading="excelLoading"
+        :upload-before="uploadBefore"
+        :upload-after="uploadAfter"
+      >
         <template slot="excelTemplate">
-          <el-button type="primary" @click="derivation"> 点击下载<i class="el-icon-download el-icon--right"></i> </el-button>
+          <el-button type="primary" @click="derivation">
+            点击下载<i class="el-icon-download el-icon--right"></i>
+          </el-button>
         </template>
       </avue-form>
-      <p style="text-align: center;color: #DC0505">
-        温馨提示 第一次导入时请先下载模板
-      </p>
+      <p style="text-align: center; color: #dc0505">温馨提示 第一次导入时请先下载模板</p>
     </el-dialog>
     <!--更新品牌按钮-->
-    <el-dialog title="更新品牌" append-to-body :visible.sync="brandBox" width="555px" :close-on-click-modal="false" v-dialog-drag>
-      <avue-form :option="brandExcel" v-model="brandExcelForm" table-loading="excelLoading" :upload-before="uploadBefore" :upload-after="brandAfter">
+    <el-dialog
+      title="更新品牌"
+      append-to-body
+      :visible.sync="brandBox"
+      width="555px"
+      :close-on-click-modal="false"
+      v-dialog-drag
+    >
+      <avue-form
+        :option="brandExcel"
+        v-model="brandExcelForm"
+        table-loading="excelLoading"
+        :upload-before="uploadBefore"
+        :upload-after="brandAfter"
+      >
         <template slot="brandTemplate">
-          <el-button type="primary" @click="brandDerive"> 点击下载<i class="el-icon-download el-icon--right"></i> </el-button>
+          <el-button type="primary" @click="brandDerive">
+            点击下载<i class="el-icon-download el-icon--right"></i>
+          </el-button>
         </template>
       </avue-form>
-      <p style="text-align: center;color: #DC0505">
-        温馨提示 第一次导入时请先下载模板
-      </p>
+      <p style="text-align: center; color: #dc0505">温馨提示 第一次导入时请先下载模板</p>
     </el-dialog>
   </div>
 </template>
@@ -143,7 +183,7 @@ export default {
             label: "模板下载",
             prop: "excelTemplate",
             formslot: true,
-            span: 24
+            span: 24,
           },
           {
             label: "导入客户",
@@ -154,12 +194,12 @@ export default {
             accept: ".xls,.xlsx",
             span: 24,
             propsHttp: {
-              res: "data"
+              res: "data",
             },
             tip: "请上传 .xls,.xlsx 标准格式文件",
-            action: "/api/gubersail-admin/corpsDesc/corpsImport"
-          }
-        ]
+            action: "/api/gubersail-admin/corpsDesc/corpsImport",
+          },
+        ],
       },
       brandExcel: {
         submitBtn: false,
@@ -169,7 +209,7 @@ export default {
             label: "模版下载",
             prop: "brandTemplate",
             formslot: true,
-            span: 24
+            span: 24,
           },
           {
             label: "导入品牌",
@@ -180,12 +220,12 @@ export default {
             accept: ".xls,.xlsx",
             span: 24,
             propsHttp: {
-              res: "data"
+              res: "data",
             },
             tip: "请上传 .xls,.xlsx 标准格式文件",
-            action: "/api/gubersail-admin/corpsDesc/importBrand"
-          }
-        ]
+            action: "/api/gubersail-admin/corpsDesc/importBrand",
+          },
+        ],
       },
       src: "",
       show: true,
@@ -200,14 +240,14 @@ export default {
         pageSize: 20,
         currentPage: 1,
         total: 0,
-        pageSizes: [10, 20, 30, 40, 50, 100, 200, 300, 400, 500]
+        pageSizes: [10, 20, 30, 40, 50, 100, 200, 300, 400, 500],
       },
       form: {
         debitAmount: 0,
         deliveringAmount: 0,
         advancePayment: 0,
         balanceAmount: 0,
-        settlmentAmount: 0
+        settlmentAmount: 0,
       },
       formSerach: {},
       pickerOptions: {
@@ -219,7 +259,7 @@ export default {
               const start = new Date(date.getFullYear(), date.getMonth(), date.getDate(), 0, 0, 0);
               const end = new Date(date.getFullYear(), date.getMonth(), date.getDate(), 23, 59, 59);
               picker.$emit("pick", [start, end]);
-            }
+            },
           },
           {
             text: "昨天",
@@ -228,7 +268,7 @@ export default {
               const start = new Date(date.getFullYear(), date.getMonth(), date.getDate() - 1, 0, 0, 0);
               const end = new Date(date.getFullYear(), date.getMonth(), date.getDate() - 1, 23, 59, 59);
               picker.$emit("pick", [start, end]);
-            }
+            },
           },
           {
             text: "当月",
@@ -237,7 +277,7 @@ export default {
               const start = new Date(date.getFullYear(), date.getMonth(), 1, 0, 0, 0);
               const end = new Date(date.getFullYear(), date.getMonth() + 1, 0, 23, 59, 59);
               picker.$emit("pick", [start, end]);
-            }
+            },
           },
           {
             text: "当季",
@@ -246,7 +286,7 @@ export default {
               const start = new Date(date.getFullYear(), parseInt(date.getMonth() / 3) * 3, 1, 0, 0, 0);
               const end = new Date(date.getFullYear(), parseInt(date.getMonth() / 3) * 3 + 3, 0, 23, 59, 59);
               picker.$emit("pick", [start, end]);
-            }
+            },
           },
           {
             text: "当年",
@@ -255,7 +295,7 @@ export default {
               const start = new Date(date.getFullYear(), date.getMonth(), 1, 0, 0, 0);
               const end = new Date(date.getFullYear() + 1, 0, 0, 23, 59, 59);
               picker.$emit("pick", [start, end]);
-            }
+            },
           },
           {
             text: "最近一周",
@@ -264,7 +304,7 @@ export default {
               const start = new Date(date.getFullYear(), date.getMonth(), date.getDate() - 7, 0, 0, 0);
               const end = new Date(date.getFullYear(), date.getMonth(), date.getDate(), 23, 59, 59);
               picker.$emit("pick", [start, end]);
-            }
+            },
           },
           {
             text: "最近二周",
@@ -273,7 +313,7 @@ export default {
               const start = new Date(date.getFullYear(), date.getMonth(), date.getDate() - 7 * 2, 0, 0, 0);
               const end = new Date(date.getFullYear(), date.getMonth(), date.getDate(), 23, 59, 59);
               picker.$emit("pick", [start, end]);
-            }
+            },
           },
           {
             text: "最近三周",
@@ -282,9 +322,9 @@ export default {
               const start = new Date(date.getFullYear(), date.getMonth(), date.getDate() - 7 * 3, 0, 0, 0);
               const end = new Date(date.getFullYear(), date.getMonth(), date.getDate(), 23, 59, 59);
               picker.$emit("pick", [start, end]);
-            }
-          }
-        ]
+            },
+          },
+        ],
       },
       treeOption: {
         addBtn: false,
@@ -293,8 +333,8 @@ export default {
         props: {
           labelText: "标题",
           label: "title",
-          value: "value"
-        }
+          value: "value",
+        },
       },
       treeData: [],
       form4: {},
@@ -309,10 +349,10 @@ export default {
               {
                 required: true,
                 message: "",
-                trigger: "blur"
-              }
+                trigger: "blur",
+              },
             ],
-            span: 24
+            span: 24,
           },
           {
             label: "上级类型",
@@ -322,11 +362,11 @@ export default {
             props: {
               label: "cname",
               value: "id",
-              res: "data.records"
+              res: "data.records",
             },
-            span: 24
-          }
-        ]
+            span: 24,
+          },
+        ],
       },
       hostUrl: "",
       option: {
@@ -355,35 +395,36 @@ export default {
             prop: "cname",
             overHidden: true,
             width: 140,
-            search: true
+            search: true,
           },
           {
             label: "电话",
             prop: "tel",
             overHidden: true,
-            search: true
+            search: true,
           },
           {
             label: "商城价格",
             prop: "priceSystem",
-            overHidden: true
+            overHidden: true,
           },
           {
             label: "客户分类",
             prop: "corpsTypeName",
-            overHidden: true
+            overHidden: true,
           },
           {
             label: "业务员",
-            prop: "salesmanId",
+            prop: "salesmanName",
             overHidden: true,
             type: "select",
             props: {
               label: "name",
-              value: "id"
+              value: "name",
             },
-            dicUrl: "/api/blade-user/factoryUserList",
-            search: true
+            dicUrl: "/api/blade-user/salerList",
+            filterable: true,
+            search: true,
           },
 
           {
@@ -396,13 +437,13 @@ export default {
             dicData: [
               {
                 label: "启用",
-                value: 1
+                value: 1,
               },
               {
                 label: "禁用",
-                value: 0
-              }
-            ]
+                value: 0,
+              },
+            ],
           },
           {
             label: "审核状态",
@@ -414,25 +455,37 @@ export default {
             type: "select",
             dicData: [
               {
+                label: "录入",
+                value: "录入",
+              },
+              {
                 label: "提交",
-                value: "提交"
+                value: "提交",
               },
               {
-                label: "通过",
-                value: "通过"
+                label: "审核通过",
+                value: "审核通过",
               },
               {
-                label: "驳回",
-                value: "驳回"
-              }
-            ]
+                label: "审核驳回",
+                value: "审核驳回",
+              },
+            ],
           },
           {
             label: "品牌",
             prop: "brandName",
             overHidden: true,
-            // hide: true,
-            search: true
+            type: "select",
+            dicUrl: "/api/gubersail-admin/brandDesc/list?type=PP&current=1&size=20&cname={{key}}",
+            props: {
+              label: "cname",
+              value: "cname",
+              res: "data.records",
+            },
+            filterable: true,
+            remote: true,
+            search: true,
           },
           {
             label: "创建人",
@@ -441,10 +494,10 @@ export default {
             type: "select",
             props: {
               label: "name",
-              value: "id"
+              value: "id",
             },
             dicUrl: "/api/blade-user/userListAll",
-            width: 100
+            width: 100,
           },
           {
             label: "创建时间",
@@ -458,42 +511,42 @@ export default {
             format: "yyyy-MM-dd",
             valueFormat: "yyyy-MM-dd HH:mm:ss",
             width: 100,
-            searchDefaultTime: ["00:00:00", "23:59:59"]
+            searchDefaultTime: ["00:00:00", "23:59:59"],
           },
           {
             label: "合同金额",
             prop: "debitAmount",
             overHidden: true,
             hide: true,
-            showColumn: false
+            showColumn: false,
           },
           {
             label: "已送货",
             prop: "deliveringAmount",
             overHidden: true,
             hide: true,
-            showColumn: false
+            showColumn: false,
           },
           {
             label: "预收款",
             prop: "advancePayment",
             overHidden: true,
             hide: true,
-            showColumn: false
+            showColumn: false,
           },
           {
             label: "未收款",
             prop: "balanceAmount",
             overHidden: true,
             hide: true,
-            showColumn: false
+            showColumn: false,
           },
           {
             label: "已收款",
             prop: "settlmentAmount",
             overHidden: true,
             hide: true,
-            showColumn: false
+            showColumn: false,
           },
           {
             label: "状态",
@@ -501,28 +554,28 @@ export default {
             type: "select",
             props: {
               label: "dictValue",
-              value: "dictKey"
+              value: "dictKey",
             },
             dicUrl: "/api/blade-system/dict-biz/dictionary?code=client_status",
             hide: true,
             showColumn: false,
-            overHidden: true
+            overHidden: true,
           },
           {
             label: "日期",
             prop: "date",
             hide: true,
             showColumn: false,
-            overHidden: true
-          }
-        ]
+            overHidden: true,
+          },
+        ],
       },
-      roleName: null
+      roleName: null,
     };
   },
   components: {
     detailsPage,
-    corpType
+    corpType,
   },
   activated() {
     setTimeout(() => {
@@ -573,8 +626,8 @@ export default {
         path: "/api/gubersail-admin/corpsDesc/pjCorpsExport", //跳转目标窗口的地址
         query: {
           ...config.params, //括号内是要传递给新窗口的参数
-          identification: this.url
-        }
+          identification: this.url,
+        },
       });
       window.open(routeData.href.slice(1, routeData.href.length) + "&" + `${this.website.tokenHeader}=${getToken()}`);
     },
@@ -614,10 +667,10 @@ export default {
       this.onLoad(this.page, this.search);
     },
     getAllWorkDicts() {
-      getCorpType({ corpType: "KH" }).then(res => {
+      getCorpType({ corpType: "KH" }).then((res) => {
         this.treeData = res.data.data;
       });
-      customerList({ corpType: "KH" }).then(res => {
+      customerList({ corpType: "KH" }).then((res) => {
         this.findObject(this.option4.column, "parentId").dicData = res.data.data.records;
       });
       this.$refs.crud.init();
@@ -657,9 +710,9 @@ export default {
         current: page.currentPage,
         size: page.pageSize,
         // ...page.pageSize,
-        ...data
+        ...data,
       })
-        .then(res => {
+        .then((res) => {
           this.dataList = res.data.data.records ? res.data.data.records : [];
           this.page.total = res.data.data.total;
         })
@@ -682,7 +735,7 @@ export default {
       this.showInfo = true;
       this.detailData = {
         id: row.id,
-        status: status
+        status: status,
       };
       this.show = false;
     },
@@ -698,13 +751,13 @@ export default {
       this.$confirm(`确定${type}数据?`, {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning"
+        type: "warning",
       }).then(() => {
         row.checkStatus = type;
-        submit(row).then(res => {
+        submit(row).then((res) => {
           this.$message({
             type: "success",
-            message: `${type}成功!`
+            message: `${type}成功!`,
           });
           this.onLoad(this.page, this.search);
         });
@@ -714,13 +767,13 @@ export default {
       this.$confirm("确定删除数据?", {
         confirmButtonText: "确定",
         cancelButtonText: "取消",
-        type: "warning"
+        type: "warning",
       }).then(() => {
-        remove({ id: row.id, corpType: "KH" }).then(res => {
+        remove({ id: row.id, corpType: "KH" }).then((res) => {
           if (res.data.code == 200) {
             this.$message({
               type: "success",
-              message: "删除成功!"
+              message: "删除成功!",
             });
             this.onLoad(this.page, this.search);
           }
@@ -737,8 +790,8 @@ export default {
         this.$refs.crud.doLayout();
         this.$refs.crud.refreshTable();
       });
-    }
-  }
+    },
+  },
 };
 </script>