Browse Source

供应商:
供应商分类弹窗,允许自由移动
切换标签,没有保留结果
电话没有保存
客户:
只需要弹出轮胎客户分类;统一图标
发货仓库增加跳转新增
列表显示
上架:
列表展示

cyang233 2 years ago
parent
commit
3382f0ab8c

+ 8 - 0
src/api/tirePartsMall/basicData/warehouse/index.js

@@ -1,5 +1,13 @@
 import request from '@/router/axios';
 
+//仓库列表全部查询
+export function customerListAll(data) {
+  return request({
+    url: '/api/blade-sales-part/storageDesc/listAll',
+    method: 'get',
+    params: data
+  })
+}
 //仓库列表查询
 export function customerList(data) {
   return request({

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

@@ -2445,5 +2445,18 @@ export default [{
     },
     component: () => import( /* webpackChunkName: "views" */ '@/views/productLaunch/index')
   }]
+}, {
+  path: '/tirePartsMall/basicData/supplier/index',
+  component: Layout,
+  hidden: true,
+  children: [{
+    path: '/tirePartsMall/basicData/supplier/index',
+    name: '产品上架',
+    meta: {
+      i18n: '/tirePartsMall/basicData/supplier/index',
+      keepAlive: true,
+    },
+    component: () => import( /* webpackChunkName: "views" */ '@/views/tirePartsMall/basicData/supplier/index')
+  }]
 }
 ]

+ 5 - 4
src/views/tirePartsMall/basicData/accountManagement/index.vue

@@ -137,7 +137,7 @@ export default {
         column: [{
           label: '账户名称',
           prop: "cname",
-          search: true,
+          search: false,
           overHidden: true,
         }, {
           label: '开户银行',
@@ -147,7 +147,7 @@ export default {
         }, {
           label: '开户人',
           prop: "accountHolder",
-          search: true,
+          search: false,
           overHidden: true,
         }, {
           label: '账户类型',
@@ -157,11 +157,12 @@ export default {
         }, {
           label: '账户余额',
           prop: "accountBalance",
-          search: true,
+          search: false,
           overHidden: true,
         }, {
           label: '状态',
-          prop: 'status'
+          prop: 'status',
+          search: true,
         }
           // , {
           //   label: "业务员",

+ 46 - 36
src/views/tirePartsMall/basicData/commodityInformation/js/optionList.js

@@ -21,6 +21,12 @@ export const option = {
       prop: "cname",
       search: true,
       overHidden: true,
+      type: 'select',
+      props: {
+        label: 'cname',
+        value: 'id'
+      },
+      dicUrl:'/api/blade-sales-part/goodsDesc/goodsListAll'
     },
     {
       label: "商品分类",
@@ -41,7 +47,7 @@ export const option = {
     },
     {
       label: "品牌",
-      prop: "brandId",
+      prop: "brandName",
       search: true,
       overHidden: true,
       type: 'select',
@@ -54,24 +60,24 @@ export const option = {
     {
       label: "采购价",
       prop: "brandId",
-      search: true,
+      search: false,
       overHidden: true,
     },
     {
       label: "销售价",
       prop: "brandId",
-      search: true,
+      search: false,
       overHidden: true,
     },{
       label: "库存预警",
       prop: "inventory_alert",
-      search: true,
+      search: false,
       overHidden: true,
       type: 'select',
     },{
       label: "商品描述",
       prop: "goods_description",
-      search: true,
+      search: false,
       overHidden: true,
     },
     {
@@ -87,37 +93,41 @@ export const option = {
         value:1
       }]
     },
-    // {
-    //   label: "是否管理批次号",
-    //   prop: "whether",
-    //   width:120,
-    //   search: true,
-    //   overHidden: true,
-    //   labelWidth:120,
-    //   searchLabelWidth:120,
-    //   type:'select',
-    //   dicData:[{
-    //     label:'否',
-    //     value:"0"
-    //   },{
-    //     label:'是',
-    //     value:"1"
-    //   }],
-    // },
-    // {
-    //   label: "防爆",
-    //   prop: "explosionProof",
-    //   search: true,
-    //   overHidden: true,
-    //   type:'select',
-    //   dicData:[{
-    //     label:'否',
-    //     value:0
-    //   },{
-    //     label:'是',
-    //     value:1
-    //   }],
-    // },
+    {
+      label: "是否管理批次号",
+      prop: "whether",
+      width:120,
+      search: true,
+      overHidden: true,
+      labelWidth:120,
+      searchLabelWidth:120,
+      hide:true,
+      showColumn:false,
+      type:'select',
+      dicData:[{
+        label:'否',
+        value:"0"
+      },{
+        label:'是',
+        value:"1"
+      }],
+    },
+    {
+      label: "是否防爆",
+      prop: "explosionProof",
+      search: true,
+      overHidden: true,
+      hide:true,
+      showColumn:false,
+      type:'select',
+      dicData:[{
+        label:'否',
+        value:0
+      },{
+        label:'是',
+        value:1
+      }],
+    },
   ]
 }
 export const optionList = {

+ 224 - 66
src/views/tirePartsMall/basicData/customerInformation/detailsPage.vue

@@ -4,7 +4,7 @@
       <div class="customer-head">
         <div class="customer-back">
           <el-button type="danger" style="border: none;background: none;color: red" icon="el-icon-arrow-left"
-                     @click="backToList">返回列表
+            @click="backToList">返回列表
           </el-button>
         </div>
         <div class="add-customer-btn">
@@ -17,78 +17,66 @@
         <avue-form ref="form" class="trading-form" v-model="form" :option="option">
           <template slot="corpsTypeId">
             <div style="display:flex;">
-              <avue-input-tree v-model="form.corpsTypeId" placeholder="请选择客户分类" :dic="corpTypeList"
-                               :props="props">
+              <avue-input-tree v-model="form.corpsTypeId" placeholder="请选择客户分类" :dic="corpTypeList" :props="props">
               </avue-input-tree>
-              <i class="el-icon-setting" style="font-size:18px;line-height: 32px;margin-left:4px"
-                 @click="corpTypeVisible = true"></i>
+              <i class="el-icon-circle-plus-outline" style="font-size:18px;line-height: 32px;margin-left:4px"
+                @click="corpTypeVisible = true"></i>
+            </div>
+          </template>
+          <template slot="deliveryWarehouseId">
+            <div style="display:flex;">
+              <avue-input-tree v-model="form.deliveryWarehouseId" placeholder="请选择发货仓库" :dic="corpTypeListCk"
+                :props="propsCk">
+              </avue-input-tree>
+              <i class="el-icon-circle-plus-outline" style="font-size:18px;line-height: 32px;margin-left:4px"
+                @click="dialogVisibleCK = true"></i>
             </div>
           </template>
         </avue-form>
       </trade-card>
       <trade-card title="客户联系人" v-loading="loadingBtn">
-        <avue-crud
-            ref="crudTwo"
-            :option="customerContact"
-            v-model="contactsForm"
-            :data="contactsData"
-            @saveColumn="saveColumnTwo"
-            @resetColumn="resetColumnTwo"
-            @row-save="rowSave"
-            @row-update="rowUpdate"
-            @row-del="rowDelTwo">
+        <avue-crud ref="crudTwo" :option="customerContact" v-model="contactsForm" :data="contactsData"
+          @saveColumn="saveColumnTwo" @resetColumn="resetColumnTwo" @row-save="rowSave" @row-update="rowUpdate"
+          @row-del="rowDelTwo">
           <template slot-scope="{ type, size, row, disabled,index}" slot="menu">
-            <el-button
-                :size="size" :disabled="disabled" :type="type"
-                :icon="row.$cellEdit?'el-icon-plus':'el-icon-edit'"
-                @click="$refs.crudTwo.rowEdit(row,index)"
-            >{{ row.$cellEdit ? '确认' : '修改' }}
+            <el-button :size="size" :disabled="disabled" :type="type"
+              :icon="row.$cellEdit ? 'el-icon-plus' : 'el-icon-edit'" @click="$refs.crudTwo.rowEdit(row, index)">{{
+                row.$cellEdit ? '确认' : '修改' }}
             </el-button>
             <el-button icon="el-icon-delete" :size="size" :disabled="disabled" :type="type"
-                       @click="rowDelTwo(row,index)">删除
+              @click="rowDelTwo(row, index)">删除
             </el-button>
             <el-button icon="el-icon-check" :size="size" :type="type" @click="creatingUsers(row)">创建用户</el-button>
           </template>
         </avue-crud>
       </trade-card>
       <trade-card title="地址信息" v-loading="loadingBtn">
-        <avue-crud :option="option2" ref="crud" :data="data"
-                   @row-save="rowSave"
-                   @row-update="rowUpdate"
-                   @saveColumn="saveColumn"
-                   @resetColumn="resetColumn">
+        <avue-crud :option="option2" ref="crud" :data="data" @row-save="rowSave" @row-update="rowUpdate"
+          @saveColumn="saveColumn" @resetColumn="resetColumn">
           <template slot="headerSerial">
             <el-button type="primary" icon="el-icon-plus" size="mini" @click.stop="addRow"
-                       :disabled="detailData.status == 1" circle></el-button>
+              :disabled="detailData.status == 1" circle></el-button>
           </template>
           <template slot-scope="{type,size,row,index,disabled}" slot="menu">
-            <el-button
-                :size="size" :disabled="disabled" :type="type"
-                :icon="row.$cellEdit?'el-icon-plus':'el-icon-edit'"
-                @click="$refs.crud.rowEdit(row,index)"
-            >{{ row.$cellEdit ? '确认' : '修改' }}
+            <el-button :size="size" :disabled="disabled" :type="type"
+              :icon="row.$cellEdit ? 'el-icon-plus' : 'el-icon-edit'" @click="$refs.crud.rowEdit(row, index)">{{
+                row.$cellEdit ? '确认' : '修改' }}
             </el-button>
-            <el-button icon="el-icon-delete" :size="size" :disabled="disabled" :type="type"
-                       @click="rowDel(row,index)">删除
+            <el-button icon="el-icon-delete" :size="size" :disabled="disabled" :type="type" @click="rowDel(row, index)">删除
             </el-button>
           </template>
           <template slot="defaultAddres" slot-scope="{row,index,disabled}">
-            <el-switch
-                active-value="1"
-                inactive-value="0"
-                :disabled="disabled"
-                v-model="row.defaultAddres"
-                @change="addressUnique(row,index)">
+            <el-switch active-value="1" inactive-value="0" :disabled="disabled" v-model="row.defaultAddres"
+              @change="addressUnique(row, index)">
             </el-switch>
           </template>
         </avue-crud>
       </trade-card>
       <containerTitle title="上传附件"></containerTitle>
-      <c-upload v-loading="loadingBtn" typeUpload="CD"
-                deleteUrl="/api/blade-client/corpsfiles/remove" :data="corpsFiles" display
-                :enumerationValue="35.1" :disabled="detailData.status == 1"></c-upload>
+      <c-upload v-loading="loadingBtn" typeUpload="CD" deleteUrl="/api/blade-client/corpsfiles/remove" :data="corpsFiles"
+        display :enumerationValue="35.1" :disabled="detailData.status == 1"></c-upload>
       <el-dialog title="设置客户分类" v-dialogDrag :visible.sync="corpTypeVisible" class="avue-dialog" width="80%"
-                 append-to-body @closed="corpTypeClosed">
+        append-to-body @closed="corpTypeClosed">
         <span>
           <corp-type></corp-type>
           <!-- <avue-form :key="reload" ref="corpType" v-model="form4" :option="option4" style="margin-top:20px">
@@ -109,11 +97,19 @@
         <el-button type="primary" @click="confirmSynchronizationTwo">确 定</el-button>
       </span>
     </el-dialog>
+    <el-dialog title="新增仓库" :visible.sync="dialogVisibleCK" append-to-body width="60%">
+      <avue-form v-if="dialogVisibleCK" ref="formDataThree" v-model="formDataThree" :option="optionDataCK">
+      </avue-form>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="dialogVisibleCK = false">取 消</el-button>
+        <el-button type="primary" @click="confirmSynchronizationThree">确 定</el-button>
+      </span>
+    </el-dialog>
   </div>
 </template>
 
 <script>
-import {option2, option3} from "./js/optionList";
+import { option2, option3 } from "./js/optionList";
 // import {getDetails, addCorpType, getCorpType, submit, customerList, itemDel} from "@/api/basicData/client";
 import {
   getDetails,
@@ -124,16 +120,24 @@ import {
   corpsattn
 } from "@/api/tirePartsMall/basicData/customerInformation"
 import corpType from '@/components/corpType/index'
-import {creatingUsersTwo} from "@/api/basicData/customerInformation";
-import {getRoleTree} from "@/api/system/role";
-import {getDeptTree} from "@/api/system/dept";
-import {getPostList} from "@/api/system/post";
+import { creatingUsersTwo } from "@/api/basicData/customerInformation";
+import { getRoleTree } from "@/api/system/role";
+import { getDeptTree } from "@/api/system/dept";
+import { getPostList } from "@/api/system/post";
 import website from "@/config/website";
+import {
+  typeSave,
+  customerListAll
+} from "@/api/tirePartsMall/basicData/warehouse";
 
 export default {
   name: "index",
   data() {
     return {
+      propsCk: {
+        label: 'cname',
+        value: 'id'
+      },
       props: {
         label: 'title',
         value: 'value'
@@ -200,12 +204,140 @@ export default {
           }
         ]
       },
+      optionDataCK: {
+        span: 8,
+        menuBtn: false,
+        column: [{
+          label: "仓库编码",
+          prop: "code",
+          search: true,
+          overHidden: true,
+          width: 120,
+          rules: [
+            {
+              required: true,
+              message: " ",
+              trigger: "blur"
+            }
+          ]
+        }, {
+          label: "仓库名称",
+          prop: "cname",
+          search: true,
+          overHidden: true,
+          width: 120,
+          rules: [
+            {
+              required: true,
+              message: " ",
+              trigger: "blur"
+            }
+          ]
+        }, {
+          label: "联系人",
+          prop: "contacts",
+          search: true,
+          overHidden: true,
+          width: 120,
+          rules: [
+            {
+              required: true,
+              message: " ",
+              trigger: "blur"
+            }
+          ]
+        }, {
+          label: "联系电话",
+          prop: "tel",
+          search: true,
+          overHidden: true,
+          width: 120,
+          rules: [
+            {
+              required: true,
+              message: " ",
+              trigger: "blur"
+            }
+          ]
+        }, {
+          label: "是否计费",
+          prop: "chargeOrNot",
+          search: true,
+          overHidden: true,
+          width: 120,
+          type: "select",
+          dicData: [{
+            label: "是",
+            value: "0"
+          }, {
+            label: "否",
+            value: "1"
+          }],
+          rules: [
+            {
+              required: true,
+              message: " ",
+              trigger: "blur"
+            }
+          ]
+        }, {
+          label: "库容",
+          prop: "storageCapacity",
+          search: true,
+          overHidden: true,
+          width: 120,
+          rules: [
+            {
+              required: true,
+              message: " ",
+              trigger: "blur"
+            }
+          ]
+        }, {
+          label: "所属公司",
+          prop: "artsVisionId",
+          search: true,
+          overHidden: true,
+          width: 120,
+          rules: [
+            {
+              required: true,
+              message: " ",
+              trigger: "blur"
+            }
+          ]
+        }, {
+          label: "共享公司",
+          prop: "sharedCompany",
+          search: true,
+          overHidden: true,
+          width: 120,
+          rules: [
+            {
+              required: true,
+              message: " ",
+              trigger: "blur"
+            }
+          ]
+        }, {
+          label: "备注",
+          prop: "remarks",
+          type: "textarea",
+          minRows: 3,
+          span: 24,
+          overHidden: true,
+          width: 200
+        }]
+      },
       dialogVisibleBt: false,
       formDataTwo: false,
+      dialogVisibleCK: false,
+      formDataThree: false,
       customerContact: {},
       contactsForm: {},
       contactsData: [],
       corpTypeList: [],
+      corpTypeListCk: [],
       corpTypeVisible: false,
       activeName: 'first',
       loadingBtn: false,
@@ -338,17 +470,17 @@ export default {
           ],
           span: 24,
         },
-          {
-            label: "上级类型",
-            prop: "parentId",
-            dicData: [],
-            type: "tree",
-            props: {
-              label: "cname",
-              value: "id"
-            },
-            span: 24,
-          }
+        {
+          label: "上级类型",
+          prop: "parentId",
+          dicData: [],
+          type: "tree",
+          props: {
+            label: "cname",
+            value: "id"
+          },
+          span: 24,
+        }
         ]
       },
       corpsFiles: [],
@@ -425,6 +557,7 @@ export default {
     }
     this.getCorpType()
     this.getAllWorkDicts()
+    this.getCorpTypeCk()
   },
   methods: {
     addressUnique(row, index) {
@@ -476,8 +609,26 @@ export default {
       });
     }
     ,
+    //确认创建仓库
+    confirmSynchronizationThree() {
+      this.$refs["formDataThree"].validate((valid, done) => {
+        done();
+        if (valid) {
+          typeSave({
+            ...this.formDataThree,
+          }).then(res => {
+            this.dialogVisibleCK = false;
+            this.formDataThree = {}
+            this.getCorpTypeCk()
+          });
+        } else {
+          return false;
+        }
+      });
+    }
+    ,
     getAllWorkDicts() {
-      customerList({corpType: "KH"}).then(res => {
+      customerList({ corpType: "KH" }).then(res => {
         this.findObject(this.option4.column, "parentId").dicData = res.data.data.records
       });
       this.getWorkDicts("abbreviation").then(res => {
@@ -501,7 +652,7 @@ export default {
     ,
     getDetail(id) {
       this.loadingBtn = true
-      getDetails({id: id})
+      getDetails({ id: id })
         .then(res => {
           this.form = res.data.data;
           this.data = res.data.data.corpsAddrList
@@ -518,7 +669,7 @@ export default {
     }
     ,
     addRow() {
-      this.data.push({$cellEdit: true})
+      this.data.push({ $cellEdit: true })
     }
     ,
     rowCell(row, index) {
@@ -554,7 +705,7 @@ export default {
     }
     ,
     addRow2() {
-      this.data2.push({$cellEdit: true, type: 1})
+      this.data2.push({ $cellEdit: true, type: 1 })
     }
     ,
     rowCell2(row, index) {
@@ -595,11 +746,18 @@ export default {
     }
     ,
     getCorpType() {
-      getCorpType({corpType: 'KH'}).then(res => {
+      getCorpType({ corpType: 'KH' }).then(res => {
         this.corpTypeList = res.data.data
       })
     }
     ,
+    getCorpTypeCk() {
+      customerListAll().then(res => {
+        this.corpTypeListCk = res.data.data
+        console.log("!111", this.corpTypeListCk)
+      })
+    }
+    ,
     addCorpType() {
       // this.$refs["corpType"].validate((valid, done) => {
       //   done();
@@ -796,7 +954,7 @@ export default {
     }
   }
 }
-;
+  ;
 </script>
 
 <style lang="scss" scoped>

+ 12 - 2
src/views/tirePartsMall/basicData/customerInformation/js/optionList.js

@@ -24,6 +24,12 @@ export const option = {
       search: true,
     },
     {
+      label: "电话",
+      prop: "tel",
+      overHidden: true,
+      search: false,
+    },
+    {
       label: "发货仓库",
       prop: "deliveryWarehouseName",
       overHidden: true,
@@ -36,7 +42,7 @@ export const option = {
     },
     {
       label: "客户分类",
-      prop: "corpType",
+      prop: "corpsTypeName",
       overHidden: true,
     },
     {
@@ -64,6 +70,8 @@ export const option = {
       label: "是否启用",
       prop: "enableOrNot",
       overHidden: true,
+      hide:true,
+      showColumn:false,
       type: 'select',
       dicData:[{
         label:'否',
@@ -128,7 +136,9 @@ export const option = {
       hide: true,
       showColumn: false,
       overHidden: true,
-    }
+    },
+
+
   ]
 }
 export const optionList = {

+ 80 - 10
src/views/tirePartsMall/basicData/listingManagement/index.vue

@@ -35,16 +35,17 @@
               <!--          <el-button icon="el-icon-view" :size="size" :type="type" @click="check(row)">-->
               <!--            {{ row.upperFrame == 0 ? '上架' : '下架' }}-->
               <!--          </el-button>-->
-              <el-tooltip :content="`${row.flag == 0?'上架':'下架'}`" placement="top">
+              <el-tooltip :content="`${row.upAndDownShelves == 0?'上架':'下架'}`" placement="top">
                 <el-switch
                     style="margin-left: 10px"
-                    v-model="row.flag"
+                    v-model="row.upAndDownShelves"
                     @change="check(row)"
                     active-value="1"
                     inactive-value="0">
                 </el-switch>
               </el-tooltip>
             </template>
+
             <template slot-scope="{type,size,row,$index}" slot="menuLeft">
               <el-button class="el-icon-document-copy" :disabled="selectionList.length === 0" type="primary"
                          size="small"
@@ -58,6 +59,13 @@
                 导入
               </el-button>
             </template>
+            <template slot="photoForm">
+              <c-upload :data="[]" display deleteUrl="/api/blade-client/goodsfiles/delete" :enumerationValue="160" />
+            </template>
+            <template slot="detailForm">
+              <avue-ueditor v-model="form.detail"
+              v-bind="options"></avue-ueditor>
+            </template>
           </avue-crud>
         </el-col>
       </el-row>
@@ -85,6 +93,20 @@ export default {
   name: "index",
   data() {
     return {
+      options: {
+        //普通上传地址
+        action: "/api/blade-resource/oss/endpoint/put-file",
+        headers: { "Blade-Auth": "Bearer " + getToken() },
+        propsHttp: {
+          home:'',
+          url:'url',
+          res: 'data'
+        },
+        props: {
+          res: "data",
+          url: 'link'
+        }
+      },
       excelForm: {},
       excelOption: {
         submitBtn: false,
@@ -185,7 +207,7 @@ export default {
           overHidden: true,
         }, {
           label: '产品状态',
-          prop: 'upperFrame',
+          prop: 'upAndDownShelves',
           filterable: true,
           display: false,
           search: true,
@@ -200,7 +222,55 @@ export default {
             label: "下架",
             value: 0
           }]
-        }]
+        },    {
+      label: "售价1",
+      prop: "price1",
+      hide: true,
+      showColumn: false,
+      overHidden: true,
+    },
+    {
+      label: "售价2",
+      prop: "price2",
+      hide: true,
+      showColumn: false,
+      overHidden: true,
+    },
+    {
+      label: "售价3",
+      prop: "price3",
+      hide: true,
+      showColumn: false,
+      overHidden: true,
+    },
+    {
+      label: "售价4",
+      prop: "price4",
+      hide: true,
+      showColumn: false,
+      overHidden: true,
+    },
+    {
+      label: "共享公司",
+      prop: "company",
+      hide: true,
+      showColumn: false,
+      overHidden: true,
+    },
+    {
+      label: "详情附件",
+      prop: "photo",
+      hide: true,
+      showColumn: false,
+      overHidden: true,
+      span:24,
+    },{
+      label: "商品详情",
+      prop: "deail",
+      hide: true,
+      showColumn: false,
+      overHidden: true,
+    }]
       }
     }
   },
@@ -264,9 +334,9 @@ export default {
       })
     },
     check(row) {
-      if (row.flag == 0) {
-        if (!Number(row.salesPrice)) return this.$message.error("上架失败,商城价格不能为0")
-      }
+      // if (row.flag == 0) {
+      //   if (!Number(row.salesPrice)) return this.$message.error("上架失败,商城价格不能为0")
+      // }
       submit({
         ...row
       }).then(res => {
@@ -279,9 +349,9 @@ export default {
         data.push(item.id)
       }
       if (type === "up") {
-        for (let item of this.selectionList) {
-          if (!Number(item.salesPrice)) return this.$message.error("上架失败,商城价格不能为0")
-        }
+        // for (let item of this.selectionList) {
+        //   if (!Number(item.salesPrice)) return this.$message.error("上架失败,商城价格不能为0")
+        // }
         this.$confirm('是否确认全部上架?', '提示', {
           confirmButtonText: '确定',
           cancelButtonText: '取消',

+ 11 - 9
src/views/tirePartsMall/basicData/supplier/detailsPage.vue

@@ -23,7 +23,7 @@
             <div style="display:flex;">
               <avue-input-tree v-model="form.corpsTypeId" placeholder="请选择供货商分类" :dic="corpTypeList" :props="props">
               </avue-input-tree>
-              <i class="el-icon-setting" style="font-size:18px;line-height: 32px;margin-left:4px"
+              <i class="el-icon-circle-plus-outline" style="font-size:18px;line-height: 32px;margin-left:4px"
                 @click="corpTypeVisible = true"></i>
             </div>
           </template>
@@ -35,8 +35,9 @@
           @resetColumn="resetColumnTwo('formContacts', 'optionContacts', 'optionContactsBack', 262.1)"
           @saveColumn="saveColumnTwo('formContacts', 'optionContacts', 'optionContactsBack', 262.1)">
           <template slot-scope="{type,size,row,index,disabled}" slot="menu">
-            <el-button :size="size" :disabled="disabled" :type="type" :icon="row.$cellEdit ? 'el-icon-plus' : 'el-icon-edit'"
-              @click="$refs.formContacts.rowCell(row, index)">{{ row.$cellEdit ? '确认' : '修改' }}
+            <el-button :size="size" :disabled="disabled" :type="type"
+              :icon="row.$cellEdit ? 'el-icon-plus' : 'el-icon-edit'" @click="$refs.formContacts.rowCell(row, index)">{{
+                row.$cellEdit ? '确认' : '修改' }}
             </el-button>
             <el-button icon="el-icon-delete" :size="size" :disabled="disabled" :type="type"
               @click="rowDelBox(row, index)">删除
@@ -50,8 +51,9 @@
           @resetColumn="resetColumnTwo('formContacts', 'optionAddress', 'optionAddressBack', 262.2)"
           @saveColumn="saveColumnTwo('formContacts', 'optionAddress', 'optionAddressBack', 262.2)">>
           <template slot-scope="{type,size,row,index,disabled}" slot="menu">
-            <el-button :size="size" :disabled="disabled" :type="type" :icon="row.$cellEdit ? 'el-icon-plus' : 'el-icon-edit'"
-              @click="$refs.formAddress.rowCell(row, index)">{{ row.$cellEdit ? '确认' : '修改' }}
+            <el-button :size="size" :disabled="disabled" :type="type"
+              :icon="row.$cellEdit ? 'el-icon-plus' : 'el-icon-edit'" @click="$refs.formAddress.rowCell(row, index)">{{
+                row.$cellEdit ? '确认' : '修改' }}
             </el-button>
             <el-button icon="el-icon-delete" :size="size" :disabled="disabled" :type="type"
               @click="rowDelBox(row, index)">删除
@@ -69,7 +71,7 @@
           deleteUrl="/api/blade-box-tube/shippingfile/remove" :enumerationValue="262.3" display />
       </trade-card>
     </div>
-    <el-dialog title="设置供应商分类" v-dialogDrag :visible.sync="corpTypeVisible" class="avue-dialog" width="80%" append-to-body
+    <el-dialog title="设置供应商分类" append-to-body v-dialog-drag :visible.sync="corpTypeVisible" class="avue-dialog" width="80%"
       @closed="corpTypeClosed">
       <span>
         <corp-type corpType="GYS"></corp-type>
@@ -88,7 +90,7 @@
 
 // import {detail, submit} from "@/api/basicData/shipManagement";
 import { getDetails, submit } from "@/api/tirePartsMall/basicData/customerInformation";
-import {getCorpType} from "@/api/tirePartsMall/basicData/customerInformation"
+import { getCorpType } from "@/api/tirePartsMall/basicData/customerInformation"
 import corpType from '@/components/corpType/index'
 export default {
   name: "detailsPage",
@@ -129,7 +131,7 @@ export default {
           }]
         }, {
           label: '电话',
-          prop: "let",
+          prop: "tel",
           span: 12,
         }, {
           label: "业务员",
@@ -265,7 +267,7 @@ export default {
       })
     },
     getCorpType() {
-      getCorpType({corpType: 'GYS'}).then(res => {
+      getCorpType({ corpType: 'GYS' }).then(res => {
         this.corpTypeList = res.data.data
       })
     }

+ 28 - 41
src/views/tirePartsMall/basicData/supplier/index.vue

@@ -4,39 +4,25 @@
       <el-row>
         <el-col :span="4">
           <avue-tree :option="treeOption" :data="treeData" @node-click="nodeClick" style="height:73vh;"
-                     @save="corpTypeVisible = true">
+            @save="corpTypeVisible = true">
             <template slot="addBtn">
               <i class="el-icon-setting" style="font-size:18px;line-height: 30px;width: 20px;padding: 0 10px;"
-                 @click="corpTypeVisible = true"></i>
+                @click="corpTypeVisible = true"></i>
             </template>
           </avue-tree>
         </el-col>
         <el-col :span="20">
-          <avue-crud
-              :option="option"
-              :search.sync="search"
-              v-model="form"
-              :table-loading="loading"
-              :data="dataList"
-              ref="crud"
-              :key="key"
-              @on-load="onLoad"
-              @search-change="searchChange"
-              @row-del="rowDel"
-              @refresh-change="refreshChange"
-              @resetColumn="resetColumnTwo('crud','option','optionList',262)"
-              @saveColumn="saveColumnTwo('crud','option','optionList',262)"
-              :page.sync="page">
+          <avue-crud :option="option" :search.sync="search" v-model="form" :table-loading="loading" :data="dataList"
+            ref="crud" :key="key" @on-load="onLoad" @search-change="searchChange" @row-del="rowDel"
+            @refresh-change="refreshChange" @resetColumn="resetColumnTwo('crud', 'option', 'optionList', 262)"
+            @saveColumn="saveColumnTwo('crud', 'option', 'optionList', 262)" :page.sync="page">
             <template slot-scope="{type,size,row,index}" slot="menu">
               <el-button icon="el-icon-view" :size="size" :type="type" @click="check(row)">查看</el-button>
-              <el-button icon="el-icon-delete" :size="size" :type="type" @click="$refs.crud.rowDel(row,index)">删除</el-button>
+              <el-button icon="el-icon-delete" :size="size" :type="type"
+                @click="$refs.crud.rowDel(row, index)">删除</el-button>
             </template>
             <template slot="enableOrNot" slot-scope="{row,index,disabled}">
-              <el-switch
-                  active-value="1"
-                  inactive-value="0"
-                  :disabled="disabled"
-                  v-model="row.enableOrNot">
+              <el-switch active-value="1" inactive-value="0" :disabled="disabled" v-model="row.enableOrNot">
               </el-switch>
             </template>
             <template slot="corpNameSearch">
@@ -57,9 +43,9 @@
       </el-row>
     </basic-container>
     <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">
+      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>
@@ -70,8 +56,8 @@
         温馨提示 第一次导入时请先下载模板
       </p>
     </el-dialog>
-    <el-dialog title="设置供应商分类" v-dialogDrag :visible.sync="corpTypeVisible" class="avue-dialog" width="80%"
-               append-to-body @closed="corpTypeClosed">
+    <el-dialog title="设置供应商分类" v-dialogDrag :visible.sync="corpTypeVisible" class="avue-dialog" width="80%" append-to-body
+      @closed="corpTypeClosed">
       <span>
         <corp-type corpType="GYS"></corp-type>
         <!-- <avue-form :key="reload" ref="corpType" v-model="form4" :option="option4" style="margin-top:20px">
@@ -89,8 +75,8 @@
 <script>
 // import {getList, remove} from "@/api/oceanShipping/maritimeExport/index.js";
 import detailsPage from "./detailsPage"
-import {getToken} from "@/util/auth";
-import {getCorpType,getList,remove} from "@/api/tirePartsMall/basicData/customerInformation";
+import { getToken } from "@/util/auth";
+import { getCorpType, getList, remove } from "@/api/tirePartsMall/basicData/customerInformation";
 import corpType from "./components/index";
 import { option } from "../commodityInformation/js/optionList";
 
@@ -102,8 +88,8 @@ export default {
   },
   data() {
     return {
-      treeData:[],
-      corpTypeVisible:false,
+      treeData: [],
+      corpTypeVisible: false,
       treeOption: {
         addBtn: false,
         menu: false,
@@ -114,7 +100,7 @@ export default {
           value: "value",
         }
       },
-      excelBox:false,
+      excelBox: false,
       excelForm: {},
       excelOption: {
         submitBtn: false,
@@ -178,14 +164,14 @@ export default {
           prop: "cname",
           search: true,
           overHidden: true,
-        },{
+        }, {
           label: '供应商分类',
           prop: "corpsTypeName",
           search: true,
           overHidden: true,
-        },  {
+        }, {
           label: '电话',
-          prop: "let",
+          prop: "tel",
           search: true,
           overHidden: true,
         }, {
@@ -205,7 +191,7 @@ export default {
           prop: "remarks",
           search: true,
           overHidden: true,
-        },{
+        }, {
           label: '是否启用',
           prop: 'enableOrNot'
         }]
@@ -215,7 +201,7 @@ export default {
   async created() {
     this.option = await this.getColumnData(this.getColumnName(262), this.optionList);
     this.key++
-    getCorpType({corpType: 'GYS'}).then(res => {
+    getCorpType({ corpType: 'GYS' }).then(res => {
       this.treeData = res.data.data
     });
     let i = 0;
@@ -228,6 +214,7 @@ export default {
       this.option.searchMenuPosition = "right";
     }
   },
+ 
   methods: {
     addCorpType() {
       // this.$refs["corpType"].validate((valid, done) => {
@@ -257,8 +244,8 @@ export default {
     },
     derivation() {
       window.open(
-          `/api/blade-client/corpsdesc/export-template?${this.website.tokenHeader
-          }=${getToken()}`
+        `/api/blade-client/corpsdesc/export-template?${this.website.tokenHeader
+        }=${getToken()}`
       );
     },
     uploadBefore(file, done, loading) {
@@ -294,7 +281,7 @@ export default {
         cancelButtonText: '取消',
         type: 'warning'
       }).then(() => {
-        remove(form.id).then(res => {
+        remove({id:form.id}).then(res => {
           this.$message({
             type: 'success',
             message: '删除成功!'

+ 1 - 1
vue.config.js

@@ -32,7 +32,7 @@ module.exports = {
       '/api': {
         //本地服务接口地址
         // target: 'http://192.168.3.64:1080',
-        target: 'http://192.168.8.113:1080',
+        target: 'http://192.168.8.105:1080',
         // 打包地址
         // target: 'http://121.37.83.47:10004',//服务器ip
         // target: 'http://trade.tubaosoft.com:10004',//服务器域名