浏览代码

首页加链接

zhengjinyi 4 年之前
父节点
当前提交
a61897eedf

+ 12 - 11
src/main/resources/static/css/base/base.pc.css

@@ -170,27 +170,28 @@ iframe{width:320px !important;height: 280px !important}
 .classifyBox .clsTab a:hover,.classifyBox .clsTab a.on{color:#E15616;border-color:#E15616}
 .classifyBox .clsCon{padding:20px 0;box-sizing: border-box;}
 .classifyBox .tabItem_lift{width: 127px;float: left;border-right: 1px solid #FFE6DC;}
-.classifyBox .tabItem_lift a{display:inline-block;width:100%;line-height:40px;box-sizing:border-box;color: #627386;padding:10px 0 10px 20px;float: left;transform: translateX(-3px);}
-.classifyBox .tabItem_lift .tabItem_lift_icon{width: 20px;height: 20px;display: block;float: left;margin-top: 10px;}
+.classifyBox .tabItem_lift a{display:inline-block;width:100%;line-height:40px;box-sizing:border-box;color: #627386;padding:10px 0 10px 15px;float: left;transform: translateX(-3px);}
+.classifyBox .tabItem_lift .tabItem_lift_icon{width: 20px;height: 20px;display: block;float: left;margin-top: 10px;margin-right: 5px;}
 .classifyBox .tabItem_lift .tabItem_lift_p{float: left;margin-left: 8px;line-height: 20px;}
 .classifyBox .tabItem_lift a.on{background: #fef6f3;color: #E15616;border-color: #ffffff;transform: translateX(0);transition: all 0.8s;}
 .classifyBox .tabItem_right{float: left;box-sizing: border-box;min-width: 280px;}
 .classifyBox .tabItem_right .tabItem_right_content {display: none;}
 .classifyBox .tabItem_right .tabItem_right_content.on{display: block;}
-.classifyBox .tabItem_right .line{position:relative;line-height:40px;height: 40px;}
-.classifyBox .tabItem_right .lft{float: left;color:#000;line-height:40px;height: 40px;width: 150px;box-sizing: border-box;padding: 0 16px;font-weight: bold;}
-.classifyBox .tabItem_right .lft.none{width: 100px;font-weight: normal;}
+.classifyBox .tabItem_right .line{position:relative;line-height:60px;height: 60px;}
+.classifyBox .tabItem_right .lft{float: left;color:#000;line-height:60px;height: 60px;box-sizing: border-box;padding: 0 0 0 16px;font-weight: bold;}
+.classifyBox .tabItem_right .lft.none{}
 .classifyBox .tabItem_right .lft.none a{color: #627386;position: relative;}
 .classifyBox .tabItem_right .lft.none a:before{content: '';width:40px;height: 2px;position: absolute;left: 50%;bottom: 5px;margin-left: -20px;background-color: #E15616;display: none;border-radius: 1px;}
 .classifyBox .tabItem_right .lft.none:hover a{color: #E15616;}
 .classifyBox .tabItem_right .lft.none a:hover:before{animation: showBorder ease-in 0.3s;display: block;left: 50%;}
 @keyframes showBorder {0% {width:0px;display:none;}100% {width:40px;display: block;} }
-.classifyBox .tabItem_right .lft.none a span{text-align: center;display: inline-block;width: 100%;}
-.classifyBox .tabItem_right .lft a{display:inline-block;width:100%;line-height:40px;box-sizing:border-box;color: #627386;}
-.classifyBox .tabItem_right .lft a p{text-align: left;float: left;}
+.classifyBox .tabItem_right .lft.none a span{text-align: center;display: inline-block;}
+.classifyBox .tabItem_right .lft a{display:inline-block;width:100%;line-height:60px;box-sizing:border-box;color: #627386;}
+.classifyBox .tabItem_right .lft a p{text-align: right;float: right;}
 .classifyBox .tabItem_right .lft a span{text-align: right;float: right;display: inline-block;}
-.classifyBox .tabItem_right .rgt{color:#666;position:relative;box-sizing: border-box;padding: 0 10px;height: 100%;line-height: 40px;float: left;}
-.classifyBox .tabItem_right .rgt a{display:inline-block;height:44px;line-height:44px;padding:0 10px;cursor:pointer;color: #627386;box-sizing: border-box;position: relative;}
+.classifyBox .tabItem_right .rgt{color:#666;position:relative;box-sizing: border-box;padding: 0 10px;height: 100%;line-height: 60px;float: left;}
+.classifyBox .tabItem_right .rgt a{display:inline-block;height:60px;line-height:60px;padding:0 10px;cursor:pointer;color: #627386;box-sizing: border-box;position: relative;}
+.classifyBox .tabItem_right .rgt a.none{padding: 0;}
 .classifyBox .tabItem_right .rgt a:before{content: '';width:40px;height: 2px;position: absolute;left: 50%;bottom: 5px;margin-left: -20px;background-color: #E15616;display: none;border-radius: 1px;}
 .classifyBox .tabItem_right .rgt a:hover:before{animation: showBorder ease-in 0.3s;display: block;left: 50%;}
 .classifyBox .tabItem_right .rgt a.on,.classifyBox .clsCon .rgt a:hover{color:#e15616;}
@@ -304,7 +305,7 @@ iframe{width:320px !important;height: 280px !important}
 .loginAlert span:first-child:after{content: ',';}
 .loginAlert:after{content:'';display:block;width:125px;height:125px;background:url(/img/account/to_login.png) no-repeat left top;background-size:100% 100%;margin:10px 0 0 15px;}
 /* 咨询,回到顶部 */
-#scrollTop{display:none;position:fixed;right:50%;margin-right:-700px;width:88px;z-index:9999;bottom:120px;}
+#scrollTop{display:none;position:fixed;right:0;margin-right:0;width:88px;z-index:9999;bottom:120px;}
 #scrollTop .item{width:100%;background-color:#fff;box-sizing:border-box;text-align:center;box-shadow:0 2px 4px rgb(254,246,243);border-radius:2px;margin-bottom:10px;font-size:12px;position:relative}
 #scrollTop .item>span{display:block;width:94px;box-sizing:border-box;position:relative;cursor:pointer;white-space:pre-wrap;word-break:break-all;}
 #scrollTop .item>span:hover{color:#E15616;}

+ 8 - 3
src/main/resources/static/css/index/index_new.pc.css

@@ -89,7 +89,7 @@ li{list-style:none;}
 }
 .section_page  .page_main_item.ad_04:hover{
     transform:translateY(-5px);
-    box-shadow:0 12px 12px rgba(102,102,102,0.1),0 14px 14px rgba(102,102,102,0.1),0 16px 16px rgba(102,102,102,0.1);
+    box-shadow:0 8px 8px rgba(102,102,102,0.05),0 10px 10px rgba(102,102,102,0.05),0 12px 12px rgba(102,102,102,0.05);
 }
 .section_page .page_main_item.ad_01{
     width: 884px;
@@ -198,8 +198,12 @@ li{list-style:none;}
 .section_page .page_main_price .main_price_none{
     width: 100%;
     height: 54px;
-    padding: 16px 0;
     box-sizing: border-box;
+    float: left;
+    margin-top: 2px;
+}
+.section_page .page_main_price .main_price_none.sec{
+    margin-top: 20px;
 }
 .section_page .page_main_price .main_price_none .listTag{
     margin:0;
@@ -239,6 +243,7 @@ li{list-style:none;}
 .section_page .section_page_more{
     width: 100%;
     height: 32px;
+    margin-top: 16px;
     float: left;
 }
 .section_page .section_page_more .more{
@@ -481,7 +486,7 @@ footer{
 
 
 /* 首页右侧导航 */
-#sideNav{display:none;position:fixed;right:50%;margin-right:-700px;width:88px;z-index:9999;bottom:220px;}
+#sideNav{display:none;position:fixed;right:0;margin-right:0;width:88px;z-index:9999;bottom:220px;}
 #sideNav .item{width:100%;background-color:#fff;box-sizing:border-box;text-align:center;box-shadow:0 2px 4px rgb(254,246,243);border-radius:2px;margin-bottom:10px;font-size:12px;position:relative}
 #sideNav .item>a{display:block;width:100%;box-sizing:border-box;padding:14px 6px;line-height:14px;position:relative;font-size: 13px;}
 #sideNav .item>a:before{content:'';position:absolute;width:70px;left:9px;top:0;border-top:1px solid #FEF6F3}

+ 1 - 0
src/main/resources/static/js/base.js

@@ -173,6 +173,7 @@ var globalHead = new Vue({
             }
         },
         hideGlobalMenu: function(){
+            console.log('222222222222222')
             if(!isPC){
                 $("#mGlobalMenu").hide().find(".cShow").hide();
             }

+ 6 - 5
src/main/resources/static/js/index.js

@@ -228,13 +228,14 @@ var homeData = new Vue({
                 $('#advertising').hide();
             }
         });
-        // 置顶
-        $('#sideNav').on("click", '.toTop',function () {
-            $("html,body").animate({scrollTop:0},500);
-        });
         // 侧边导航
-        $('#sideNav').on("click", 'a[data-id]',function () {
+        $('#sideNav .item-a').each(function(){
+            alert($(this).text())
+        });
+        $('#sideNav .item-a').on("click", '.item-a',function () {
+            console.log('2222222222222222222');
             var id = $(this).attr('data-id');
+            console.log(id);
             var floorScroll = $('.section_page_title [data-id='+id+']').offset().top;
             $('html,body').animate({scrollTop: floorScroll},600);
         });

+ 4 - 3
src/main/resources/templates/components/header.html

@@ -153,8 +153,8 @@
                                 <div class="line"  v-if="nav.smalltypeList.length>0" v-for="small in nav.smalltypeList">
                                     <div class="lft">
                                         <a :href="'/product/list.html?category='+nav.bigTypeID+'-'+small.smallTypeID+'-0'" target="_blank">
+                                            <span v-if="isPC"> > </span>
                                             <p>{{ small.name }}</p>
-                                             <span v-if="isPC"> > </span>
                                         </a>
                                     </div>
                                     <div class="rgt mfw" >
@@ -165,8 +165,8 @@
                                             </a>
                                         </template>
                                         <template v-if="!small.tinytypeList">
-                                            <a  :href="'/product/list.html?category='+nav.bigTypeID+'-'+small.smallTypeID+'-0'" target="_blank">
-                                                <img v-if="!isPC" :src="small.crmIcon" alt="全部商品">
+                                            <a class="none" :href="'/product/list.html?category='+nav.bigTypeID+'-'+small.smallTypeID+'-0'" target="_blank">
+                                                <img v-if="!isPC" :src="tiny.icon" alt="全部商品">
                                                 <p>全部商品</p>
                                             </a>
                                         </template>
@@ -176,6 +176,7 @@
                                 <div class="line">
                                     <div class="lft none">
                                         <a :href="'/product/list.html?category='+nav.bigTypeID+'-0'" target="_blank">
+                                            <span v-if="isPC"> > </span>
                                             <p>{{ nav.name }}</p>
                                         </a>
                                     </div>

+ 30 - 9
src/main/resources/templates/index.html

@@ -100,7 +100,7 @@
                 <div class="section_left ">
                     <div class="section_page" v-for="(page,index) in pageList">
                         <div class="section_page_title">
-                            <h1 :data-id="index+1" v-text="page.title"></h1>
+                            <h1 v-text="page.title" :data-id="index+1"></h1>
                             <p v-text="page.detail"></p>
                         </div>
                         <template v-if="page.floorContent.templateType == '1'">
@@ -156,13 +156,16 @@
                                         </template>
                                         <template v-else>
                                             <template v-if="pros.product.productCategory == 1">
+                                                <div class="price_text_tag">
+                                                    <p class="listTag" v-if="pros.product.actStatus==1">{{pros.product.promotions.name}}</p>
+                                                </div>
                                                 <div class="main_price_none">
                                                     <em class="price_grade"><span class="bold">¥</span><i :class="'icon mIcon price_grade_'+pros.product.price1Grade"></i></em>
                                                     <p class="listTag" v-if="pros.actStatus==1">{{pros.product.promotions.name}}</p>
                                                 </div>
                                             </template>
                                             <template v-else>
-                                                <div class="main_price_none">
+                                                <div class="main_price_none sec">
                                                     <em class="price_grade"><span>¥</span>登录可见</em>
                                                 </div>
                                             </template>
@@ -228,13 +231,16 @@
                                         </template>
                                         <template v-else>
                                             <template v-if="pros.product.productCategory == 1">
+                                                <div class="price_text_tag">
+                                                    <p class="listTag" v-if="pros.product.actStatus==1">{{pros.product.promotions.name}}</p>
+                                                </div>
                                                 <div class="main_price_none">
                                                     <em class="price_grade"><span class="bold">¥</span><i :class="'icon mIcon price_grade_'+pros.product.price1Grade"></i></em>
                                                     <p class="listTag" v-if="pros.actStatus==1">{{pros.product.promotions.name}}</p>
                                                 </div>
                                             </template>
                                             <template v-else>
-                                                <div class="main_price_none">
+                                                <div class="main_price_none sec">
                                                     <em class="price_grade"><span>¥</span>登录可见</em>
                                                 </div>
                                             </template>
@@ -300,13 +306,16 @@
                                         </template>
                                         <template v-else>
                                             <template v-if="pros.product.productCategory == 1">
+                                                <div class="price_text_tag">
+                                                    <p class="listTag" v-if="pros.product.actStatus==1">{{pros.product.promotions.name}}</p>
+                                                </div>
                                                 <div class="main_price_none">
                                                     <em class="price_grade"><span class="bold">¥</span><i :class="'icon mIcon price_grade_'+pros.product.price1Grade"></i></em>
                                                     <p class="listTag" v-if="pros.actStatus==1">{{pros.product.promotions.name}}</p>
                                                 </div>
                                             </template>
                                             <template v-else>
-                                                <div class="main_price_none">
+                                                <div class="main_price_none sec">
                                                     <em class="price_grade"><span>¥</span>登录可见</em>
                                                 </div>
                                             </template>
@@ -373,13 +382,16 @@
                                         </template>
                                         <template v-else>
                                             <template v-if="pros.product.productCategory == 1">
+                                                <div class="price_text_tag">
+                                                    <p class="listTag" v-if="pros.product.actStatus==1">{{pros.product.promotions.name}}</p>
+                                                </div>
                                                 <div class="main_price_none">
                                                     <em class="price_grade"><span class="bold">¥</span><i :class="'icon mIcon price_grade_'+pros.product.price1Grade"></i></em>
                                                     <p class="listTag" v-if="pros.actStatus==1">{{pros.product.promotions.name}}</p>
                                                 </div>
                                             </template>
                                             <template v-else>
-                                                <div class="main_price_none">
+                                                <div class="main_price_none sec">
                                                     <em class="price_grade"><span>¥</span>登录可见</em>
                                                 </div>
                                             </template>
@@ -444,13 +456,16 @@
                                         </template>
                                         <template v-else>
                                             <template v-if="pros.product.productCategory == 1">
+                                                <div class="price_text_tag">
+                                                    <p class="listTag" v-if="pros.product.actStatus==1">{{pros.product.promotions.name}}</p>
+                                                </div>
                                                 <div class="main_price_none">
                                                     <em class="price_grade"><span class="bold">¥</span><i :class="'icon mIcon price_grade_'+pros.product.price1Grade"></i></em>
                                                     <p class="listTag" v-if="pros.actStatus==1">{{pros.product.promotions.name}}</p>
                                                 </div>
                                             </template>
                                             <template v-else>
-                                                <div class="main_price_none">
+                                                <div class="main_price_none sec">
                                                     <em class="price_grade"><span>¥</span>登录可见</em>
                                                 </div>
                                             </template>
@@ -514,13 +529,16 @@
                                         </template>
                                         <template v-else>
                                             <template v-if="pros.product.productCategory == 1">
+                                                <div class="price_text_tag">
+                                                    <p class="listTag" v-if="pros.product.actStatus==1">{{pros.product.promotions.name}}</p>
+                                                </div>
                                                 <div class="main_price_none">
                                                     <em class="price_grade"><span class="bold">¥</span><i :class="'icon mIcon price_grade_'+pros.product.price1Grade"></i></em>
                                                     <p class="listTag" v-if="pros.actStatus==1">{{pros.product.promotions.name}}</p>
                                                 </div>
                                             </template>
                                             <template v-else>
-                                                <div class="main_price_none">
+                                                <div class="main_price_none sec">
                                                     <em class="price_grade"><span>¥</span>登录可见</em>
                                                 </div>
                                             </template>
@@ -582,13 +600,16 @@
                                         </template>
                                         <template v-else>
                                             <template v-if="pros.product.productCategory == 1">
+                                                <div class="price_text_tag">
+                                                    <p class="listTag" v-if="pros.product.actStatus==1">{{pros.product.promotions.name}}</p>
+                                                </div>
                                                 <div class="main_price_none">
                                                     <em class="price_grade"><span class="bold">¥</span><i :class="'icon mIcon price_grade_'+pros.product.price1Grade"></i></em>
                                                     <p class="listTag" v-if="pros.actStatus==1">{{pros.product.promotions.name}}</p>
                                                 </div>
                                             </template>
                                             <template v-else>
-                                                <div class="main_price_none">
+                                                <div class="main_price_none sec">
                                                     <em class="price_grade"><span>¥</span>登录可见</em>
                                                 </div>
                                             </template>
@@ -617,7 +638,7 @@
         <!--右侧边栏导航-->
         <div id="sideNav" v-if="isPC">
             <div class="item">
-                <a v-for="nav in asideNav" :data-id="nav.id" v-text="nav.value" href="javascript:void(0);"></a>
+                <a class="item-a" v-for="nav in asideNav" :data-id="nav.id" v-text="nav.value" href="javascript:void(0);"></a>
             </div>
         </div>
     </template>