Browse Source

Merge remote-tracking branch 'origin/feature/interaceAdjust-1114' into feature/yc-isSellOut-1103

# Conflicts:
#	components/search/GoodList.vue
#	components/store/CommodityList.vue
yangc 8 years ago
parent
commit
667767db65

+ 1 - 1
components/common/buyOrCar/buyComponent.vue

@@ -13,7 +13,7 @@
         if (!this.$store.state.option.user.logged) {
           this.$http.get('/login/page', {params: {returnUrl: window.location.href}}).then(response => {
             if (response.data) {
-              this.$router.push('/auth/login')
+              window.location.href = response.data.content + '&baseUrl=' + encodeURIComponent(window.location.protocol + '//' + window.location.host + response.data.baseUrl)
             }
           })
         } else {

+ 6 - 6
components/default/Footer.vue

@@ -71,17 +71,17 @@
           url: 'http://www.usoftchina.com/usoft',
           title: '深圳市优软科技'
         }, {
-          url: 'http://www.fantem.com',
-          title: '丰唐物联技术(深圳)'
+          url: 'http://www.51cube.com',
+          title: '酷比魔方'
         }, {
-          url: 'http://www.hiways.com',
-          title: '深圳市海威思科技'
+          url: 'http://www.szsoling.com/home',
+          title: 'SOLING 索菱'
         }, {
           url: 'http://www.huashangweitai.com',
           title: '深圳市华商维泰显示科技'
         }, {
-          url: 'http://www.ufct.com.cn',
-          title: '联合创泰科技'
+          url: 'http://www.szmadigi.com',
+          title: '迈迪杰科技'
         }]
       }
     }

+ 6 - 4
components/default/Header.vue

@@ -77,13 +77,16 @@
     },
     methods: {
       logout () {
-        this.$router.push('/auth/logout')
+        this.$http.get('/logout/crossBefore').then(response => {
+          if (response.data) {
+            window.location.href = response.data.logoutUrl + encodeURIComponent(window.location.protocol + '//' + window.location.host + response.data.baseUrl)
+          }
+        })
       },
       onLoginClick () {
         this.$http.get('/login/page', {params: {returnUrl: window.location.href}}).then(response => {
           if (response.data) {
-            this.$router.push('/auth/login')
-//            window.location.href = response.data.content
+            window.location.href = response.data.content + '&baseUrl=' + encodeURIComponent(window.location.protocol + '//' + window.location.host + response.data.baseUrl)
           }
         })
         // TODO 待Account Center改版
@@ -91,7 +94,6 @@
       onRegisterClick () {
         this.$http.get('/register/page').then(response => {
           if (response.data) {
-        //    this.$router.push('/auth/login')
             window.location.href = response.data.content
           }
         })

+ 1 - 1
components/default/RightBar.vue

@@ -148,7 +148,7 @@
       goLogin: function () {
         this.$http.get('/login/page', {params: {returnUrl: window.location.href}}).then(response => {
           if (response.data) {
-            this.$router.push('/auth/login')
+            window.location.href = response.data.content + '&baseUrl=' + encodeURIComponent(window.location.protocol + '//' + window.location.host + response.data.baseUrl)
           }
         })
       },

+ 2 - 2
components/product/component/ComponentDetail.vue

@@ -111,7 +111,7 @@
         } else {
           this.$http.get('/login/page', {params: {returnUrl: window.location.href}}).then(response => {
             if (response.data) {
-              this.$router.push('/auth/login')
+              window.location.href = response.data.content + '&baseUrl=' + encodeURIComponent(window.location.protocol + '//' + window.location.host + response.data.baseUrl)
             }
           })
         }
@@ -120,7 +120,7 @@
         if (url === '1') {
           this.$http.get('/login/page', {params: {returnUrl: window.location.href}}).then(response => {
             if (response.data) {
-              this.$router.push('/auth/login')
+              window.location.href = response.data.content + '&baseUrl=' + encodeURIComponent(window.location.protocol + '//' + window.location.host + response.data.baseUrl)
             }
           })
         } else {

+ 7 - 10
components/product/component/StoreInfo.vue

@@ -34,9 +34,9 @@
       <table class="table">
         <thead>
           <tr class="height54">
-            <th class="text-center" width="100">制造商型号</th>
-            <th class="text-center" width="120">生产日期</th>
+            <th class="text-center" width="100">型号</th>
             <th class="text-center" width="80">包装方式</th>
+            <th class="text-center" width="120">生产日期</th>
             <th class="text-center" width="150">库存</th>
             <th class="text-center" width="80">数量</th>
             <th class="text-center" width="100">香港交货<span style="font-size: 12px;">($)</span></th>
@@ -51,14 +51,14 @@
               <a v-if="list.code">{{list.code}}</a>
               <a v-if="!list.code">—</a>
             </td>
-            <td>
-              <a v-if="list.produceDate">{{list.produceDate}}</a>
-              <a v-if="!list.produceDate">—</a>
-            </td>
             <td>
               <a v-if="list.packaging">{{list.packaging}}</a>
               <a v-if="!list.packaging">—</a>
             </td>
+            <td>
+              <a v-if="list.produceDate">{{list.produceDate}}</a>
+              <a v-if="!list.produceDate">—</a>
+            </td>
             <td style="text-align: left;padding-left: 25px;">
               <a>
                 <div v-if="list.reserve">
@@ -385,10 +385,7 @@
     margin-left: 10%;
   }
   .storeInfo .table tbody tr:hover{
-    background: #f5f5f5;
-  }
-  .storeInfo .table tbody tr:hover{
-    background: #f5f5f5;
+    background: #ecf2fd;
   }
   .storeInfo .goodsList .can-div-sell {
     text-align: left;

+ 1 - 1
components/provider/NewStore.vue

@@ -57,7 +57,7 @@ export default {
       if (!this.user.logged) {
         this.$http.get('/login/page', {params: {returnUrl: window.location.href}}).then(response => {
           if (response.data) {
-            this.$router.push('/auth/login')
+            window.location.href = response.data.content + '&baseUrl=' + encodeURIComponent(window.location.protocol + '//' + window.location.host + response.data.baseUrl)
           }
         })
       } else {

+ 22 - 14
components/search/GoodList.vue

@@ -40,27 +40,28 @@
         <table class="product-list" >
           <thead>
           <tr style="height: 40px;">
-            <th width="80"></th>
+            <!--<th width="80"></th>-->
             <th width="160">品牌/型号/类目</th>
-            <th width="100">装/生产日期</th>
-            <th width="110">店铺名称</th>
+            <th width="100">装/生产日期</th>
+            <th width="110">商家名称</th>
             <th width="110">库存</th>
-            <th width="90">阶梯</th>
-            <th width="90" v-if="!crname_click_flag.rmb_click_flag">香港交货</th>
-            <th width="110" v-if="!crname_click_flag.usd_click_flag">大陆交货<span style="font-size: 12px;">(含税)</span></th>
+            <th width="90">数量</th>
+            <th width="90" v-if="!crname_click_flag.rmb_click_flag">香港交货<span style="font-size: 12px;">($)</span></th>
+            <th width="110" v-if="!crname_click_flag.usd_click_flag">大陆交货<span style="font-size: 12px;">()</span></th>
             <th width="110">交期<span style="font-size: 12px;">(天)</span></th>
+            <th width="100">规格书</th>
             <th width="100">操作</th>
           </tr>
           </thead>
           <tbody id="productList-content">
           <tr v-for="item in good_list.components">
-            <td>
-              <nuxt-link class="component-img-box" :to="item.batchCode?`/store/${item.storeId}/${item.batchCode}`:`/product/component/${item.uuid}`">
-      <!--          <img :src="item.img?item.img:item.brand&&item.brand.logoUrl?item.brand.logoUrl:'/images/component/default.png'">-->
-                <img class="component-img" :src="item.batchCode?item.img?item.img:'/images/component/default.png':item.brand&&item.brand.logoUrl?item.brand.logoUrl:'/images/component/default.png'">
-                <img v-if="item.status === 602" class="sellout-flag" src="/images/search/sellout-search.png" alt="">
-              </nuxt-link>
-            </td>
+            <!--<td>-->
+            <!--<nuxt-link class="component-img-box" :to="item.batchCode?`/store/${item.storeId}/${item.batchCode}`:`/product/component/${item.uuid}`">-->
+              <!--&lt;!&ndash;          <img :src="item.img?item.img:item.brand&&item.brand.logoUrl?item.brand.logoUrl:'/images/component/default.png'">&ndash;&gt;-->
+              <!--<img class="component-img" :src="item.batchCode?item.img?item.img:'/images/component/default.png':item.brand&&item.brand.logoUrl?item.brand.logoUrl:'/images/component/default.png'">-->
+              <!--<img v-if="item.status === 602" class="sellout-flag" src="/images/search/sellout-search.png" alt="">-->
+            <!--</nuxt-link>-->
+          <!--</td>-->
             <td class="brand-code">
               <div class="brand" v-if="item.brand.nameEn"><nuxt-link :to="`/product/brand/${item.brand.uuid}`" class="text-num" v-text="item.brand.nameEn"></nuxt-link></div>
               <div class="brand" v-if="!item.brand.nameEn">—</div>
@@ -128,6 +129,10 @@
                 <span v-if="item.b2cMinDelivery == item.b2cMaxDelivery" v-text="item.b2cMinDelivery"></span>
               </div>
             </td>
+            <td>
+              <span v-if="item.attach && item.attach !==1"><a :href="item.attach" target="_blank"><img src="/images/store/common/pdf.png" alt=""/></a></span>
+              <span v-show="!item.attach">—</span>
+            </td>
             <td>
               <div v-show="!item.reserve">
                 <span>—</span>
@@ -420,8 +425,11 @@
 
   .product-list tbody>tr {
     border: 1px solid #e8e8e8;
+    cursor: pointer ;
   }
-
+  .product-list tbody>tr:hover{
+   background: #ecf2fd;
+ }
   .product-list tbody>tr .component-img-box {
     width: 80px;
     height: 80px;

+ 7 - 7
components/searchStore/SearchTitle.vue

@@ -24,13 +24,13 @@
         </div>
         <!--<div class=""><a >所在地</a></div>-->
     </div>
-      <div class="off">
-        <a @click="showClick">
-          <span v-text="show?'收起':'展开'" style="margin-right: 10px;"></span>
-          <i v-show="!show" class="fa fa-angle-down"></i>
-          <i v-show="show" class="fa fa-angle-up"></i>
-        </a>
-      </div>
+      <!--<div class="off">-->
+        <!--<a @click="showClick">-->
+          <!--<span v-text="show?'收起':'展开'" style="margin-right: 10px;"></span>-->
+          <!--<i v-show="!show" class="fa fa-angle-down"></i>-->
+          <!--<i v-show="show" class="fa fa-angle-up"></i>-->
+        <!--</a>-->
+      <!--</div>-->
   </div>
   </div>
 </template>

+ 7 - 3
components/searchStore/StoreContent.vue

@@ -21,7 +21,7 @@
           <span>库存量:<span v-text="store.totalReserve"></span></span>
         </div>
         <div class="btn-content">
-          <a class="focus-store store-btn" @click="focusStore(store, index)" v-text="focusData[index] === 'true'?'已关注':'关注店铺'"></a>
+          <a class="focus-store store-btn" @click="focusStore(store, index)" v-text="focusData[index] === 'true'?'已关注':'关注店铺'" :class="{'is-focus': focusData[index] === 'true'}"></a>
           <a :href="'/store/' + store.uuid" target="_blank" class="enter-store store-btn">进入店铺</a>
         </div>
       </div>
@@ -97,7 +97,7 @@
         if (!this.user.logged) {
           this.$http.get('/login/page').then(response => {
             if (response.data) {
-              this.$router.push('/auth/login')
+              window.location.href = response.data.content + '&baseUrl=' + encodeURIComponent(window.location.protocol + '//' + window.location.host + response.data.baseUrl)
             }
           })
         } else {
@@ -124,7 +124,7 @@
         this.$emit('pageAction', page)
       },
       goStore: function (index, compIndex) {
-        window.open('/product/component/' + this.componentData[index].content[compIndex].uuid)
+        window.open('/store/' + this.componentData[index].content[compIndex].storeid + '/' + this.componentData[index].content[compIndex].batchCode)
       }
     }
   }
@@ -245,6 +245,10 @@
     background: #5078cb;
     border: 1px solid #5078cb;
   }
+  .btn-content .is-focus {
+    background: #999;
+    border: 1px solid #999;
+  }
   .btn-content .enter-store {
     background: #ff8522;
     border: 1px solid #ff8522;

+ 1 - 1
components/store/CommodityInfo.vue

@@ -313,7 +313,7 @@ export default {
       if (!this.$store.state.option.user.logged) {
         this.$http.get('/login/page', {params: {returnUrl: window.location.href}}).then(response => {
           if (response.data) {
-            this.$router.push('/auth/login')
+            window.location.href = response.data.content + '&baseUrl=' + encodeURIComponent(window.location.protocol + '//' + window.location.host + response.data.baseUrl)
           }
         })
       } else {

+ 37 - 20
components/store/CommodityList.vue

@@ -30,25 +30,27 @@
         <table class="goodslist" style="width: 970px">
           <thead>
           <tr style="height: 40px;">
-            <th width="90"></th>
+            <!--<th width="90"></th>-->
             <th width="150">品牌/型号</th>
             <th width="100">包装/生产日期</th>
             <th width="90">库存</th>
             <th width="90">数量</th>
-            <th width="90">香港交货<span style="font-size: 12px;">($)</span></th>
-            <th width="100">大陆交货<span style="font-size: 12px;">(¥)</span></th>
+            <!--<th width="90">香港交货<span style="font-size: 12px;">($)</span></th>-->
+            <!--<th width="100">大陆交货<span style="font-size: 12px;">(¥)</span></th>-->
+            <th width="100">单价</th>
             <th width="100">交期(天)</th>
+            <th width="100">规格书</th>
             <th width="100">操作</th>
           </tr>
           </thead>
           <tbody id="goodslist-content">
           <tr v-for="commodity in commodities.content">
-            <td class="commodity-icon">
-              <a :href="'/store/' + commodity.storeid + '/' + commodity.batchCode" target="_blank">
-                <div class="img"><img :src="commodity.img || '/images/store/common/default.png'"/></div>
-                <img class="sellout-store-commodity" v-if="commodity.status === 602" src="/images/search/sellout-search.png" alt="">
-              </a>
-            </td>
+            <!--<td class="commodity-icon">-->
+              <!--<a :href="'/store/' + commodity.storeid + '/' + commodity.batchCode" target="_blank">-->
+                <!--<div class="img"><img :src="commodity.img || '/images/store/common/default.png'"/></div>-->
+                <!--<img class="sellout-store-commodity" v-if="commodity.status === 602" src="/images/search/sellout-search.png" alt="">-->
+              <!--</a>-->
+            <!--</td>-->
             <td class="brand-code">
               <div class="brand" v-if="commodity.brandNameEn" v-text="commodity.brandNameEn"></div>
               <div class="brand" v-if="!commodity.brandNameEn">—</div>
@@ -76,17 +78,21 @@
             <td>
               <div v-for="price in commodity.prices" v-text="price.start + '+'"></div>
             </td>
+            <!--<td>-->
+              <!--<div v-show="commodity.currencyName.indexOf('USD')==-1 || !commodity.prices">-->
+                <!--<span>—</span>-->
+              <!--</div>-->
+              <!--<div v-for="price in commodity.prices">{{price.uSDPrice | currency}}</div>-->
+            <!--</td>-->
+            <!--<td>-->
+              <!--<div v-show="commodity.currencyName.indexOf('RMB')==-1 || !commodity.prices">-->
+                <!--<span>—</span>-->
+              <!--</div>-->
+              <!--<div v-for="price in commodity.prices" >{{price.rMBPrice | currency}}</div>-->
+            <!--</td>-->
             <td>
-              <div v-show="commodity.currencyName.indexOf('USD')==-1 || !commodity.prices">
-                <span>—</span>
-              </div>
-              <div v-for="price in commodity.prices">{{price.uSDPrice | currency}}</div>
-            </td>
-            <td>
-              <div v-show="commodity.currencyName.indexOf('RMB')==-1 || !commodity.prices">
-                <span>—</span>
-              </div>
-              <div v-for="price in commodity.prices" >{{price.rMBPrice | currency}}</div>
+              <div v-for="price in commodity.prices">{{commodity.currencyName.indexOf('USD')!=-1?'$':'¥'}}{{commodity.currencyName.indexOf('USD')!=-1?price.uSDPrice:price.rMBPrice | currency}}</div>
+              <div v-if="commodity.currencyName.indexOf('RMB')==-1 || !commodity.prices && commodity.currencyName.indexOf('USD')==-1 || !commodity.prices"></div>
             </td>
             <td>
               <div v-if="commodity.b2cMinDelivery">交期:
@@ -96,6 +102,12 @@
               </div>
               <div v-if="!commodity.b2cMinDelivery"><span>—</span></div>
             </td>
+            <td>
+              <div v-if="commodity.attach">
+                <a :href="commodity.attach && commodity.attach !== 1" target="_blank"><img src="/images/store/common/pdf.png" alt=""/></a>
+              </div>
+              <div v-show="!commodity.attach">—</div>
+            </td>
             <td>
               <buy :item="commodity" :disabledFlag="commodity.status === 602"></buy>
             </td>
@@ -429,7 +441,11 @@ export default {
 
 	#goods-list-fragment .goodslist tbody>tr {
 		border: 1px solid #e8e8e8;
+    cursor: pointer;
 	}
+#goods-list-fragment .goodslist tbody>tr:hover{
+  background: #ecf2fd;
+}
   #goods-list-fragment .goodslist tbody>tr td.commodity-icon {
     position: relative;
   }
@@ -462,6 +478,7 @@ export default {
 
 	/* 物品列表按钮 */
 	#goods-list-fragment .btn-buy-now {
+    margin: 5px 0;
 		background-color: #5078CB;
 		color: #fff;
 		width: 80px;
@@ -471,7 +488,7 @@ export default {
 	}
 
 	#goods-list-fragment .btn-add-cart {
-		margin-top: 10px;
+    margin: 10px 0 5px 0;
 		color: #214797;
 		width: 80px;
 		height: 30px;

+ 15 - 2
components/store/ComponentInfo.vue

@@ -11,8 +11,9 @@
           </div>
           <div class="property-value" v-text="property.value"></div>
         </li>
-        <li v-if="!component.properties || component.properties.length === 0" class="text-center">
-          <i class="fa fa-smile-o fa-lg"></i> 暂无参数信息
+        <li v-if="!component.properties || component.properties.length === 0" class="text-info">
+          <!--<i class="fa fa-smile-o fa-lg"></i> 暂无参数信息-->
+          <span class="info">卖家上传的产品暂无参数,请 <a href="">联系卖家</a> 了解具体详情</span>
         </li>
       </ul>
     </div>
@@ -52,6 +53,18 @@ export default {
 		line-height: 30px;
 	}
 
+  .component-info ul li.text-info span.info{
+    padding-left: 270px;
+    font-size: 14px;
+    color: #333;
+  }
+  .component-info ul li.text-info span.info a{
+    font-size: 14px;
+    color: #5078cb;
+  }
+  .component-info ul li.text-info span.info a:hover{
+    text-decoration: underline!important ;
+  }
 	.component-info .head {
 		font-size: 14px;
 		font-weight: 600;

+ 1 - 1
components/store/RecommendProduct.vue

@@ -77,7 +77,7 @@
         if (!this.$store.state.option.user.logged) {
           this.$http.get('/login/page', {params: {returnUrl: window.location.href}}).then(response => {
             if (response.data) {
-              this.$router.push('/auth/login')
+              window.location.href = response.data.content + '&baseUrl=' + encodeURIComponent(window.location.protocol + '//' + window.location.host + response.data.baseUrl)
             }
           })
         } else {

+ 1 - 1
components/store/common/StoreHeader.vue

@@ -100,7 +100,7 @@ export default {
       if (!this.user.logged) {
         this.$http.get('/login/page', {params: {returnUrl: window.location.href}}).then(response => {
           if (response.data) {
-            this.$router.push('/auth/login')
+            window.location.href = response.data.content + '&baseUrl=' + encodeURIComponent(window.location.protocol + '//' + window.location.host + response.data.baseUrl)
           }
         })
       } else {

+ 29 - 22
layouts/error.vue

@@ -1,13 +1,12 @@
 <template>
   <div class="error">
-    <div class="error-content">
-      <h1 class="error-code">{{ error.statusCode }}</h1>
-      <div class="error-wrapper-message">
-        <h2 class="error-message">找不到页面</h2>
+    <div class="section">
+      <div class="container">
+        <div class="btn-click">
+          <a href="/"><i class="fa fa-home" style="margin-right:5px;"></i>返回首页</a>
+          <a href="javascript:history.go(-1)"><i class="fa fa-reply" style="margin-right:5px;"></i>返回上一页</a>
+        </div>
       </div>
-      <p>
-        <nuxt-link class="error-link" to="/">返回首页</nuxt-link>
-      </p>
     </div>
   </div>
 </template>
@@ -18,21 +17,29 @@
   }
 </script>
 
-<style lang="scss">
-  @import '~assets/scss/mixins';
-  @import '~assets/scss/variables';
-  .error {
-    position: relative;
-    background-color: $module-bg;
-    min-height: 10em;
-    width: 100%;
-    overflow: hidden;
+<style scoped lang="scss">
+  .section{
+    background: #ebfdff url('/images/404.png')no-repeat center center;
+    height:900px;
+    position:relative;
+  }
+  .section .btn-click{
+    position:absolute;
+    top:54%;
+    left:50%;
+    margin-left:-150px;
+  }
+  .section .btn-click a{
+    display:inline-block;
+    width:130px;
+    height:33px;
+    font-size: 16px;
+    line-height: 33px;
+    color:#fff;
+    background: #f87c29;
     text-align: center;
-    padding: 2em 0;
-    .error-content {
-      .error-code {
-        font-size: 6rem;
-      }
-    }
+    margin:0 10px;
+    border-radius: 2px;
+    text-decoration: none;
   }
 </style>

+ 0 - 10
layouts/main.vue

@@ -20,15 +20,5 @@
       MainHeader,
       MainNav
     }
-//    data () {
-//      return {
-//        url: window.location.href
-//      }
-//    },
-//    watch: {
-//      url: function (val, oldVal) {
-//        console.log(val)
-//      }
-//    }
   }
 </script>

+ 5 - 1
middleware/authenticated.js

@@ -4,6 +4,10 @@ export default function ({ isServer, store, req, redirect }) {
   if (isServer && !req) return
 
   if (!store.state.option.user.logged) {
-    redirect('/auth/login')
+    this.$http.get('/logout/crossBefore').then(response => {
+      if (response.data) {
+        window.location.href = response.data.logoutUrl + encodeURIComponent(window.location.protocol + '//' + window.location.host + response.data.baseUrl)
+      }
+    })
   }
 }

+ 1 - 1
nuxt.config.js

@@ -107,5 +107,5 @@ module.exports = {
     ssr: false
   }],
   /* TODO 暂时代理到商城测试版,之后再做出调整 */
-  proxyTable: ['/api/**', '/search/**', '/user/**', '/login/**', '/register/**', '/logout/**', '/static/**', '/vendor**', '/user**', '/trade/**', '/recommendation/**', '/store-service/**', '/basic/**', '/logout**', '/operation/**', '/help**', '/product**', '/store**', '/order/proxy**', '/report/**', '/store/**#/**', '/kdn/**', '/product/**Submit', '/admin**', '/product/**Submit/**', '/release/**', '/auth/store/**', '/produce/**', '/file**']
+  proxyTable: ['/api/**', '/search/**', '/user/**', '/login/**', '/register/**', '/logout/**', '/static/**', '/vendor**', '/user**', '/trade/**', '/recommendation/**', '/store-service/**', '/basic/**', '/logout**', '/operation/**', '/help**', '/product**', '/store**', '/order/proxy**', '/report/**', '/store/**#/**', '/kdn/**', '/product/**Submit', '/admin**', '/product/**Submit/**', '/release/**', '/auth/store/**', '/produce/**', '/file**', '/rate/**', '/log/**', '/help-service/**']
 }

+ 0 - 55
pages/auth/login.vue

@@ -1,55 +0,0 @@
-<template>
-  <!-- Login 代理页面 -->
-  <div>
-  </div>
-</template>
-<script>
-
-export default {
-  layout: 'login',
-  mounted () {
-    this.crossBefore()
-  },
-  methods: {
-    async crossBefore () {
-      try {
-        let { data } = await this.$http.get('/login/crossBefore')
-        const params = data || {}
-        this.proxyLogin(params.askUrl, params.askData, params.loginUrl)
-      } catch (err) {
-        this.$router.replace('/')
-        console.log(err)
-      }
-    },
-    proxyLogin (askUrl, askData, loginUrl) {
-      const crossAfter = this.crossAfter
-      this.$jsonp(`${askUrl}?askData=${askData}`, function (err, data) {
-        if (err) throw err
-
-        // 判断是否已经登录
-        if (data.error) {
-          // 如果未登录,跳转登录界面
-          window.location.href = loginUrl
-        } else {
-          crossAfter(data.content)
-        }
-      })
-    },
-    async crossAfter (content) {
-      if (!content || content === '') {
-        this.$router.replace('/')
-      }
-
-      try {
-        let { data } = await this.$http.post('/login/crossAfter', {}, { params: { replyTxt: content } })
-
-        this.$store.dispatch('loadUserInfo', data)
-        window.location.href = data.returnUrl || '/'
-      } catch (err) {
-        this.$router.replace('/')
-        console.log(err)
-      }
-    }
-  }
-}
-</script>

+ 0 - 35
pages/auth/logout.vue

@@ -1,35 +0,0 @@
-<template>
-  <!-- Login 代理页面 -->
-  <div>
-  </div>
-</template>
-<script>
-export default {
-  layout: 'login',
-  mounted () {
-    this.crossBefore()
-  },
-  methods: {
-    async crossBefore () {
-      try {
-        let { data } = await this.$http.get('/logout/crossBefore')
-        const params = data || {}
-        this.proxyLogout(params.askUrl, params.returnUrl, params.logoutUrl)
-      } catch (err) {
-        this.$router.replace('/')
-        console.log(err)
-      }
-    },
-    proxyLogout (askUrl, returnUrl, logoutUrl) {
-      this.$jsonp(`${askUrl}`, function (err, data) {
-        if (err) throw err
-        if (data.error) {
-          window.location.href = logoutUrl
-        } else {
-          window.location.href = returnUrl && returnUrl !== 'null' ? returnUrl : '/'
-        }
-      })
-    }
-  }
-}
-</script>

+ 1 - 2
pages/index.vue

@@ -20,8 +20,7 @@
         store.dispatch('loadFloors'),
         store.dispatch('loadBanners', {type: 'home'}),
         store.dispatch('loadProductKinds', { id: 0 }),
-        store.dispatch('loadNewsSnapshot', { page: 1, pageSize: 10 }),
-        store.dispatch('loadProductCounts', { _status: 'actived' })
+        store.dispatch('loadNewsSnapshot', { page: 1, pageSize: 10 })
       ])
     },
     components: {

+ 0 - 56
pages/platform-b2c/login/proxy.vue

@@ -1,56 +0,0 @@
-<template>
-  <!-- Login 代理页面 -->
-  <div>
-  </div>
-</template>
-<script>
-
-export default {
-  layout: 'login',
-  mounted () {
-    this.crossBefore()
-  },
-  methods: {
-    async crossBefore () {
-      try {
-        let { data } = await this.$http.get('/login/crossBefore')
-        const params = data || {}
-        this.proxyLogin(params.askUrl, params.askData, params.loginUrl)
-      } catch (err) {
-        this.$router.replace('/')
-        console.log(err)
-      }
-    },
-    proxyLogin (askUrl, askData, loginUrl) {
-      const crossAfter = this.crossAfter
-      this.$jsonp(`${askUrl}?askData=${askData}`, function (err, data) {
-        if (err) throw err
-
-        // 判断是否已经登录
-        if (data.error) {
-          // 如果未登录,跳转登录界面
-          window.location.href = loginUrl
-        } else {
-          crossAfter(data.content)
-        }
-      })
-    },
-    async crossAfter (content) {
-      if (!content && content === '') {
-        this.$router.replace('/')
-      }
-
-      try {
-        let { data } = await this.$http.post('/login/crossAfter', {}, { params: { replyTxt: content } })
-
-        this.$store.dispatch('loadUserInfo', data)
-
-        window.location.href = data.returnUrl || '/'
-      } catch (err) {
-        this.$router.replace('/')
-        console.log(err)
-      }
-    }
-  }
-}
-</script>

+ 0 - 34
pages/platform-b2c/logout/proxy.vue

@@ -1,34 +0,0 @@
-<template>
-  <!-- Login 代理页面 -->
-  <div>
-  </div>
-</template>
-<script>
-
-export default {
-  layout: 'login',
-  mounted () {
-    this.crossBefore()
-  },
-  methods: {
-    async crossBefore () {
-      try {
-        let { data } = await this.$http.get('/logout/crossBefore')
-        const params = data || {}
-        this.proxyLogout(params.askUrl, params.returnUrl)
-      } catch (err) {
-        this.$router.replace('/')
-        console.log(err)
-      }
-    },
-    proxyLogout (askUrl, returnUrl) {
-      this.$jsonp(`${askUrl}`, function (err, data) {
-        if (err) throw err
-        console.log(data)
-
-        window.location.href = returnUrl && returnUrl !== 'null' ? returnUrl : '/'
-      })
-    }
-  }
-}
-</script>

+ 1 - 1
pages/product/kind/_id.vue

@@ -1,7 +1,7 @@
 <template>
   <div class="container">
     <categroy-nav></categroy-nav>
-    <category-property  @loadCmpGoodsByBrandEvent="listemBrandFilter" @loadCmpGoodsByTypeEvent="listemProTypeFilter"></category-property>
+    <!--<category-property  @loadCmpGoodsByBrandEvent="listemBrandFilter" @loadCmpGoodsByTypeEvent="listemProTypeFilter"></category-property>-->
     <component-goods :brandid="brandid" :propertyJSON="propertyJSON"></component-goods>
   </div>
 </template>

BIN
static/images/404.png


BIN
static/images/store/common/pdf.png


+ 2 - 1
store/index.js

@@ -41,7 +41,8 @@ export const actions = {
     }
     return Promise.all([
       // 全局数据
-      store.dispatch('loadUserInfo')
+      store.dispatch('loadUserInfo'),
+      store.dispatch('loadProductCounts', { _status: 'actived' })
     ])
   },
   // 获取用户信息