chenrui 2 роки тому
батько
коміт
9eda175855

+ 1 - 1
src/api/bizuser.js

@@ -208,7 +208,7 @@ export const saveSupplierList = params => {
 }
 export const deleteSupplier = params => {
   return axios({
-    url: `/bizuser/detail/deleteSupplier/${params.id}`,
+    url: `/bizuser/scope/detail/deleteSupplier/${params.id}`,
     data: {},
     method: 'get'
   })

+ 1 - 1
src/views/dealerManagement/businessOwnerSettings/addModal.vue

@@ -49,7 +49,7 @@
           </a-radio-group>
         </a-form-model-item>
         <!-- 供应商 -->
-        <a-form-model-item label="供应商" prop="allSupplierFlag">
+        <a-form-model-item label="供应商" prop="allSupplierFlag" v-if="form.bizUserType == 'cg'">
           <a-radio-group v-model="form.allSupplierFlag">
             <a-radio value="1">
               全部供应商

+ 11 - 33
src/views/dealerManagement/businessOwnerSettings/chooseSupplier.vue

@@ -6,10 +6,10 @@
         <a-row :gutter="15">
           <a-col :md="8" :sm="24">
             <a-form-item label="供应商名称">
-              <a-input id="chooseSupplier-nameLike" v-model.trim="queryParam.name" allowClear placeholder="请输入供应商名称"/>
+              <a-input id="chooseSupplier-nameLike" v-model.trim="queryParam.supplier.supplierName" allowClear placeholder="请输入供应商名称"/>
             </a-form-item>
           </a-col>
-          <a-col :md="pageType!='viewDealers'?8:6" :sm="24" style="margin-bottom: 10px;">
+          <a-col :md="8" :sm="24" style="margin-bottom: 10px;">
             <a-button type="primary" @click="searchForm(true)" :disabled="disabled" id="chooseSupplier-refresh">查询</a-button>
             <a-button style="margin-left: 5px" @click="resetSearchForm" :disabled="disabled" id="chooseSupplier-reset">重置</a-button>
           </a-col>
@@ -33,24 +33,10 @@
       @rowSelection="rowSelectionFun"
       :columns="columns"
       :data="loadData"
-      :style="{ height:pageType=='viewDealers'? tableHeight+84.5+'px':tableHeight-15+'px' }"
-      :scroll="{ y: pageType=='viewDealers'?tableHeight:tableHeight+80 }"
+      :style="{ height:tableHeight-15+'px' }"
+      :scroll="{ y:tableHeight+80 }"
       :defaultLoadData="false"
       bordered>
-      <template slot="areas" slot-scope="text, record">
-        <span v-if="record.subareaArea">{{ record.subareaArea.subareaName }}>{{ record.subareaArea.subareaAreaName }}</span>
-        <span v-else>--</span>
-      </template>
-      <template slot="action" slot-scope="text, record">
-        <a-button
-          size="small"
-          type="link"
-          class="button-error"
-          @click="handleAdd(record)"
-          v-if="record.subareaAreaSn != parentData.subareaAreaSn"
-          id="marketingDivisionSetNew-del-btn">添加</a-button>
-        <span style="color:#666" v-else>已添加</span>
-      </template>
     </s-table>
   </a-spin>
 </template>
@@ -65,23 +51,13 @@ export default {
   name: 'ChooseSupplier',
   mixins: [commonMixin],
   components: { STable, VSelect, subarea, AreaList },
-  props: {
-    pageType: {
-      type: String,
-      default: ''
-    },
-    parentData: {
-      type: Object,
-      default: function () {
-        return null
-      }
-    }
-  },
   data () {
     return {
       spinning: false,
       queryParam: { //  查询条件
-        supplierName: ''
+        supplier: {
+          supplierName: ''
+        }
       },
       userSn: '',
       pageFlag: false,
@@ -158,7 +134,9 @@ export default {
     //  重置
     resetSearchForm () {
       this.queryParam = {
-        supplierName: ''
+        supplier: {
+          supplierName: ''
+        }
       }
       this.$refs.table.clearSelected()
       this.$refs.table.refresh(true)
@@ -207,7 +185,7 @@ export default {
     },
     setTableH () {
       const tableSearchH = this.$refs.tableSearch.offsetHeight
-      this.tableHeight = window.innerHeight - tableSearchH - 285
+      this.tableHeight = window.innerHeight - tableSearchH - 300
     }
   },
   watch: {

+ 2 - 3
src/views/dealerManagement/businessOwnerSettings/supplierSet.vue

@@ -32,7 +32,7 @@
               :columns="columns"
               :data="loadData"
               :defaultLoadData="false"
-              :style="{ height: 1000+'px' }"
+              :style="{ height: tableHeight+'px' }"
               :scroll="{ y: tableHeight-180 }"
               bordered>
               <!-- 操作 -->
@@ -203,8 +203,7 @@ export default {
       this.$refs.table.refresh()
     },
     setTableH () {
-      const addBtnHeight = this.$refs.categorySetAddBtn.offsetHeight
-      this.tableHeight = window.innerHeight - addBtnHeight - 385
+      this.tableHeight = window.innerHeight - 385
     }
   },
   watch: {