Przeglądaj źródła

经销商拜访

zhujindu 9 miesięcy temu
rodzic
commit
c1f563567a
3 zmienionych plików z 22 dodań i 25 usunięć
  1. 1 1
      src/store/getters.js
  2. 6 6
      src/store/modules/user.js
  3. 15 18
      src/views/home/index.vue

+ 1 - 1
src/store/getters.js

@@ -1,7 +1,7 @@
 const getters = {
   userInfo: (state) => state.user.userInfo,
   refreshClewPage: (state) => state.isRefreshPage.refreshClewPage,
-  storeType: (state) => state.user.storeType,
+  chainsType: (state) => state.user.chainsType,
   shotsNum: (state) => state.otheStore.shotsNum,
   deviceOutsidePage: (state) => state.isRefreshPage.deviceOutsidePage,
   activaCreateTypeStore: (state) => state.user.activaCreateTypeStore,

+ 6 - 6
src/store/modules/user.js

@@ -5,7 +5,7 @@ const user = {
     userInfo: null,
     activaTypeStore: null, //未拜访门店
     activaCreateTypeStore: null, //建店未完工、未结案门店
-    storeType: [],
+    chainsType: [], //经销商类型
   },
 
   mutations: {
@@ -18,8 +18,8 @@ const user = {
     SET_ASSIGN_FLAG: (state, value) => {
       state.isAssignFlag = value;
     },
-    SET_STORE_TYPE: (state, value) => {
-      state.storeType = value;
+    SET_CHAINS_TYPE: (state, value) => {
+      state.chainsType = value;
     },
     SET_ACTIVA_CREATE_TYPE_STORE: (state, value) => {
       state.activaCreateTypeStore = value;
@@ -40,9 +40,9 @@ const user = {
             localStorage.setItem('userId', res.data.userId);
             localStorage.setItem('deptIds', JSON.stringify(res.data.deptIds));
             localStorage.setItem('chainUser', res.data.chainUser); //是否经销商用户 true
-            // 门店类型
-            getDictOption({}, 'sfa_store_type').then((res) => {
-              commit('SET_STORE_TYPE', res.data);
+            // 经销商类型
+            getDictOption({}, 'sfa_chains_type').then((res) => {
+              commit('SET_CHAINS_TYPE', res.data);
               resolve();
             });
           })

+ 15 - 18
src/views/home/index.vue

@@ -1,6 +1,6 @@
 <template>
-  <div class="bgcolor deviceOutside">
-    <div class="navBarTOP">
+  <div class="bgcolor home">
+    <div class="header">
       <van-nav-bar class="navBar" :title="$route.meta.title">
         <template #right>
           <span @click="searchFn">筛选<van-icon name="arrow-down" /></span>
@@ -23,7 +23,7 @@
         <van-tab title="我的" name="1" :disabled="disabled"></van-tab>
       </van-tabs>
     </div>
-    <div class="content" id="content" style="margin-top: 144px" @touchmove="handleTouch">
+    <div class="content" id="content" @touchmove="handleTouch">
       <van-pull-refresh v-model="isLoading" @refresh="onRefresh">
         <van-list
           class="myList"
@@ -353,7 +353,7 @@ export default {
   mounted() {
     localStorage.setItem('tabVal', '1');
     // 上拉边界下拉出现白色空白
-    let node = document.getElementsByClassName('deviceOutside')[0];
+    let node = document.getElementsByClassName('home')[0];
     node.addEventListener(
       'touchmove',
       (e) => {
@@ -530,10 +530,10 @@ export default {
         this.list = [];
         this.refreshing = false;
       }
-      getUserOutPlaList({
-        lat: this.lat,
-        lon: this.lon,
-        chainCode: this.chainCode ? this.chainCode : '',
+      queryMyChainsGroupList({
+        // lat: this.lat,
+        // lon: this.lon,
+        // chainCode: this.chainCode ? this.chainCode : '',
         pageNum: this.pageNum,
         typeCodeList: this.storeCategoryList,
         pageSize: this.pageSize,
@@ -992,12 +992,6 @@ export default {
   border-top: 1px solid #eee;
   margin: 0 10px;
 }
-.navBarTOP {
-  position: fixed;
-  width: 100%;
-  z-index: 2;
-  top: 0;
-}
 .statstext {
   background-color: #0057ba;
   position: absolute;
@@ -1014,7 +1008,7 @@ export default {
 .statstext .van-icon__image {
   height: 0.7em;
 }
-.deviceOutside {
+.home {
   height: 100%;
   width: 100%;
   display: flex;
@@ -1022,10 +1016,13 @@ export default {
   overflow: hidden;
   .content {
     flex: 1;
-    overflow-y: auto;
-    padding-bottom: 50px;
+    overflow: hidden;
+    padding: 10px 0;
     .van-pull-refresh {
       height: 100%;
+      overflow-y: auto;
+      .van-pull-refresh__track {
+      }
     }
   }
 }
@@ -1116,7 +1113,7 @@ export default {
     margin-bottom: 50px;
   }
 }
-.deviceOutside {
+.home {
   .TCFXListItem {
     display: inline-block;
     border: 1px solid #ccc;