Browse Source

修改卖家中心

q867427795 7 years ago
parent
commit
2d48ca4c90
5 changed files with 148 additions and 15 deletions
  1. 3 3
      components/default/Header.vue
  2. 40 6
      components/main/Search.vue
  3. 2 2
      components/main/index.js
  4. 1 1
      nuxt.config.js
  5. 102 3
      pages/vendor/index.vue

+ 3 - 3
components/default/Header.vue

@@ -159,8 +159,8 @@
           window.location.href = '/personalMaterial'
           window.location.href = '/personalMaterial'
         } else {
         } else {
           if (tempEnterprise.isVendor === 313) {
           if (tempEnterprise.isVendor === 313) {
-            // window.location.href = '/vendor'
-            window.location.href = '/vendor#/index'
+            window.location.href = '/vendor'
+            // window.location.href = '/vendor#/index'
           } else {
           } else {
             window.location.href = '/register-saler'
             window.location.href = '/register-saler'
           }
           }
@@ -226,7 +226,7 @@
   @import '~assets/scss/mixins';
   @import '~assets/scss/mixins';
   @import '~assets/scss/variables';
   @import '~assets/scss/variables';
 
 
-  $nav-height: 36px;
+  $nav-height: 38px;
 
 
   .header {
   .header {
     height: $nav-height;
     height: $nav-height;

+ 40 - 6
components/main/Search.vue

@@ -1,7 +1,7 @@
 <template>
 <template>
-  <div class="search-box">
+  <div class="search-box" :class="{'search-box2': !SelectItem}">
     <div class="input-group">
     <div class="input-group">
-      <select @change="onSelectTypeChange" class="form-control select-type select-adder">
+      <select @change="onSelectTypeChange" class="form-control select-type select-adder" v-if="SelectItem">
         <option value="">产品</option>
         <option value="">产品</option>
         <option value="">店铺</option>
         <option value="">店铺</option>
       </select>
       </select>
@@ -12,11 +12,11 @@
              @keyup.40="onSelectChange(1)"
              @keyup.40="onSelectChange(1)"
              @keyup.38="onSelectChange(-1)"
              @keyup.38="onSelectChange(-1)"
              @keyup.13="onSearch()"/>
              @keyup.13="onSearch()"/>
-      <span class="input-group-btn" @click="onSearch()">
-        <button class="btn btn-primary search-btn" type="button">搜&nbsp;索</button>
+      <span class="input-group-btn" @click="onSearch()" style="z-index: 10">
+        <button class="btn btn-primary search-btn" type="button" :class="{'Isblue':!SelectItem}">搜&nbsp;索</button>
       </span>
       </span>
     </div>
     </div>
-    <ul class="association" v-show="showAssociate && searchType == 'product'"
+    <ul class="association" :class="{'association2': !SelectItem}" v-show="showAssociate && searchType == 'product'"
         @mouseenter="associate.focus=true" @mouseleave="associate.focus=false">
         @mouseenter="associate.focus=true" @mouseleave="associate.focus=false">
       <li v-if="similarKeywords.data.component && similarKeywords.data.component.length > 0" class="similar-title">型号:</li>
       <li v-if="similarKeywords.data.component && similarKeywords.data.component.length > 0" class="similar-title">型号:</li>
       <li v-for="(k, index) in similarKeywords.data.component" class="item"
       <li v-for="(k, index) in similarKeywords.data.component" class="item"
@@ -34,7 +34,7 @@
           @click.stop.prevent="onAssociateClick(k.nameCn)">{{ k.nameCn }}
           @click.stop.prevent="onAssociateClick(k.nameCn)">{{ k.nameCn }}
       </li>
       </li>
     </ul>
     </ul>
-    <div class="search-hot">
+    <div class="search-hot" v-if="SelectItem">
       <ul class="list-untyled">
       <ul class="list-untyled">
         <li class="item item-first">热门搜索</li>
         <li class="item item-first">热门搜索</li>
         <li class="item" v-for="w in hotBrand" v-if="ifFloorsHotSearchInValid">
         <li class="item" v-for="w in hotBrand" v-if="ifFloorsHotSearchInValid">
@@ -53,6 +53,12 @@
 <script>
 <script>
   export default {
   export default {
     name: 'search-box',
     name: 'search-box',
+    props: {
+      SelectItem: {
+        type: Boolean,
+        default: true
+      }
+    },
     data () {
     data () {
       return {
       return {
         keyword: '',
         keyword: '',
@@ -227,6 +233,26 @@
       width: 79px;
       width: 79px;
       border-radius: 0;
       border-radius: 0;
     }
     }
+
+    .Isblue{
+      vertical-align: middle;
+      display: inline-block;
+      text-align: center;
+      width: 72px;
+      border-left: 0;
+      background: #d3e1fc;
+      color: #5078cb;
+      text-align: center;
+      font-size: 14px;
+      position: absolute;
+      right: 0;
+      top: 0;
+      &:hover {
+        background: #d2272d;
+        color: #fff;
+        transition: all .3s;
+      }
+    }
     .search-hot ul{
     .search-hot ul{
       line-height: 12px;
       line-height: 12px;
     }
     }
@@ -286,5 +312,13 @@
         cursor: default;
         cursor: default;
       }
       }
     }
     }
+    .association2 {
+      left: 2px;
+      right: 71px
+    }
+  }
+
+  .search-box2 {
+    width: 442px;
   }
   }
 </style>
 </style>

+ 2 - 2
components/main/index.js

@@ -1,4 +1,4 @@
 import MainHeader from './Header.vue'
 import MainHeader from './Header.vue'
 import MainNav from './Nav.vue'
 import MainNav from './Nav.vue'
-
-export { MainHeader, MainNav }
+import VendorHeader from './vendorHeader.vue'
+export { MainHeader, MainNav, VendorHeader }

+ 1 - 1
nuxt.config.js

@@ -122,7 +122,7 @@ module.exports = {
     '/register/**': baseUrl,
     '/register/**': baseUrl,
     '/logout/**': baseUrl,
     '/logout/**': baseUrl,
     '/static/**': baseUrl,
     '/static/**': baseUrl,
-    '/vendor**': baseUrl,
+    // '/vendor**': baseUrl,
     '/trade/**': baseUrl,
     '/trade/**': baseUrl,
     '/recommendation/**': baseUrl,
     '/recommendation/**': baseUrl,
     '/store-service/**': baseUrl,
     '/store-service/**': baseUrl,

+ 102 - 3
pages/vendor/index.vue

@@ -1,13 +1,112 @@
 <template>
 <template>
-  <div class="container" style="height: 300px;line-height: 300px;text-align: center;font-size: 24px;">
+  <!-- <div class="container" style="height: 300px;line-height: 300px;text-align: center;font-size: 24px;"> -->
     
     
     <!-- 暂未开放卖家中心SSR版 -->
     <!-- 暂未开放卖家中心SSR版 -->
+  <!-- </div> -->
+  <div class="container">
+    <div class="vendor-index clear">
+      <left-toul></left-toul>
+      <div class="vendor-content">
+        <div class="vendor-topinfo clear">
+          <div class="vendor-user">
+            <img src="/images/vendor/user_photo.png"/>
+          </div>
+          <div class="vendor-user-name">杨超|优软测试二123</div>
+          <a href="#/accountManager/">账户设置&nbsp;》</a>
+        </div>
+
+        <div class="vendor-list-item clear">
+          <span>收货信息</span>
+          <a href="#"><img src="/images/vendor/edit.png"/></a>
+        </div>
+
+        <div class="vendor-list-item clear">
+          <span class="nobold">云南省,丽江市,古城区123  123 123333333</span>
+        </div>
+
+        <div class="vendor-list-item clear">
+          <span>开票信息</span>
+          <a href="#"><img src="/images/vendor/edit.png"/></a>
+        </div>
+
+        <div class="vendor-list-item clear">
+          <span class="nobold">目前暂无发票信息</span>
+        </div>
+      </div>
+    </div>
   </div>
   </div>
 </template>
 </template>
 <script>
 <script>
+import { toul } from '~components/vendor'
 
 
 export default {
 export default {
-  layout: 'main',
-  middleware: 'authenticated'
+  layout: 'uservendor',
+  middleware: 'authenticated',
+  components: {
+    leftToul: toul
+  }
 }
 }
 </script>
 </script>
+
+<style lang="scss" scoped>
+.clear {
+  &::after {
+    content: ' ';
+    clear: both;
+    display: block;
+    visibility: hidden;
+  }
+}
+.vendor-index {
+  margin-top: 16px;
+  .vendor-content {
+    margin-left: 18px;
+    float: left;
+    width: 734px;
+    .vendor-topinfo {
+      background: #ecf2fd;
+      padding: 14px;
+      border: 1px solid #ddd;
+      .vendor-user {
+        float: left;
+      }
+      .vendor-user-name {
+        color: #323232;
+        font-size: 14px;
+        float: left;
+        margin-left: 24px;
+        margin-top: 8px;
+      }
+      a {
+        float: right;
+        color: #666;
+        margin-top: 20px;
+        &:hover {
+          color: #5078cb;
+        }
+      }
+    }
+    .vendor-list-item {
+      padding: 12px;
+      background: #fff;
+      border: 1px solid #ddd;
+      border-bottom: 1px dashed #ddd;
+      border-top: 0px;
+      span {
+        font-weight: bold;
+        color: #323232;
+        float: left;
+        &.nobold {
+          font-weight: 500;
+        }
+      }
+      a {
+        float: right;
+      }
+      &:nth-child(3) {
+        border-bottom: 1px solid #ddd;
+      }
+    }
+  }
+}
+</style>