Ver código fonte

Merge remote-tracking branch 'remotes/origin/developerC' into developerB

# Conflicts:
#	src/main/resources/static/js/flea-market/form.js
zhengjinyi 4 anos atrás
pai
commit
d1ada64dc4

+ 1 - 0
src/main/resources/static/css/product/instruement-list.css

@@ -150,6 +150,7 @@
     .productItem .price .price_text_tag .listTag{margin: 0;float: left}
     .productItem .price .main_price_unde { width: 100%;height: 31px;line-height: 31px;font-size: 14px;color: #4a4f58;text-align: left;float: left;}
     .productItem .price .main_price_show { width: 100%;height: 30px;line-height: 30px;font-size: 14px;color: #f94b4b;text-align: left;float: left;}
+    .productItem .price .main_price_show.none { color: #999999; text-decoration: line-through;}
     .productItem .name .tag{width: 44px;height: 18px;line-height: 18px;font-size: 12px;display: inline-block;margin-right: 5px;text-align: center;color: #FFFFFF !important;background-image: linear-gradient(270deg, #f9c023 0%, #f83600 100%);border-radius: 0px 10px 0px 0px;}
 
 }

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

@@ -634,6 +634,7 @@ function setProductPrice(productList, productIds, userId, callback){
                         product.shopId = item.shopId;
                         product.userIdentity = item.userIdentity;
                         product.price = item.price;
+                        product.originalPrice = item.originalPrice;
                         product.priceLoaded = true;
                         product.ladderPriceFlag = item.ladderPriceFlag;
                         product.actStatus =item.actStatus;

+ 3 - 2
src/main/resources/static/js/common/serviceapi/supplier.service.js

@@ -208,10 +208,11 @@ var SupplierApi = {
         },
         SupplierViewShopInfo: function (params, callback) {//获取登录供应商信息
             Http.AjaxService({
-                url:'/supplier/shopInfo',
+                url:'/user/shop/info',
                 type:'get',
                 data:params,
-                json:false
+                json:false,
+                isHost:true
             })
             .then(function(res){
                 callback(res);

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

@@ -224,7 +224,7 @@ var homeData = new Vue({
                         // priceFlag: 0公开价格 1不公开价格 2仅对会员机构公开
                         var parent = $(".main_price_text.product_"+ price.productId);
                         var priceFlag = parent.find(".main_price_login").attr('data-id')*1;
-                        if (userIdentity===2 || (priceFlag === 0 && userIdentity===4 ) || (userIdentity===3 && shopId === price.shopId*1)) {
+                        if (priceFlag===3 || userIdentity===2 || (priceFlag === 0 && userIdentity===4 ) || (userIdentity===3 && shopId === price.shopId*1)) {
                             parent.find(".price_o_num").text(Number(price.originalPrice).toFixed(2));
                             parent.find(".price_num").text(Number(price.price).toFixed(2));
                             if(price.promotions && price.promotions.type*1===1 && price.promotions.mode*1===1){
@@ -238,11 +238,6 @@ var homeData = new Vue({
                             parent.find(".main_price_show").hide();
                             parent.find(".price_grade_shop").show();
                         }
-                        // 二手商品供应商显示等级
-                        // if (priceFlag === 3 && userIdentity===3) {
-                        //     parent.find(".main_price_show").hide();
-                        //     parent.find(".price_grade_shop").show();
-                        // }
                     });
                 }
             });

+ 10 - 0
src/main/resources/static/js/product/produce-list.js

@@ -132,6 +132,16 @@ var productList = new Vue({
             }
 
         },
+        PromotionsFormat:function(promo){//促销活动类型数据处理
+            if(promo!=null){
+                if(promo.type == 1 && promo.mode == 1){
+                    return true
+                }else{
+                    return false
+                }
+            }
+            return false
+        },
         checkedClasslyFn:function(item,index){
             this.params.pageNum = 1;
             this.params.idType = index;

+ 2 - 2
src/main/resources/static/js/supplier-center/shop/release.js

@@ -34,7 +34,7 @@ var releaseContainer = new Vue({
             productType:'',//商品类型,
             machineType:'',//医疗器械类型
             searchKey:'',//搜索关键词
-            qualificationImg:"https://img.caimei365.com/group1/M00/03/E6/Cmis21_8EgmAPFAcAAFgNbV6g2U552.jpg",//器械资质
+            qualificationImg:"",//器械资质
             normalPrice:'',//市场价
             price:'',//售价
             costPrice:'',//结算价
@@ -99,7 +99,7 @@ var releaseContainer = new Vue({
         ],
         productDetailInfoId:null,
         ProvinceList:[],
-        GoodsImagesList:['https://img.caimei365.com/group1/M00/03/E6/Cmis21_8EgmAPFAcAAFgNbV6g2U552.jpg','https://img.caimei365.com/group1/M00/03/E6/Cmis21_8EgmAPFAcAAFgNbV6g2U552.jpg'],
+        GoodsImagesList:[],
         isProvince:false,
         provinceIns:0,
         oldNum:0,

+ 1 - 4
src/main/resources/templates/flea-market/detail.html

@@ -36,8 +36,6 @@
                         </ul>
                         <div class="swiper-pagination mfc"></div>
                   </div>
-
-
                 <div class="preview-box" id="mag" v-if="isPC">
                     <div class="bigitem">
                         <img id="magnifierImg" :src="previewBigimage"/>
@@ -61,8 +59,7 @@
                             <span v-if="detail.detailTalkFlag==2&&userID==0" class="fave-text">价格详聊</span></span>
                             <span v-else-if="userID==0"><a class="member-detail toLogin loginWithParam" >登录查看价格></a></span>
                             <span v-else-if="userID!=0&&detail.detailTalkFlag==2" class="fave-text">价格详聊</span></span>
-                            <span v-else class="fave-text">¥<span class="big">{{detail.price1Str}}</span></span>
-
+                            <span v-else class="fave-text">¥<span class="big">{{detail.price}}</span></span>
                         </p>
                         <div class="tag">
                            <span class="infotag news" v-if="detail.sold==0&&detail.newAdded==1">最新</span>

+ 1 - 1
src/main/resources/templates/flea-market/list.html

@@ -72,7 +72,7 @@
                             <span v-if="item.detailTalkFlag ==2 && userID==null">价格详聊</span>
                             <span v-else-if="userID==null" class="priceparam" @click="toLogin">登录查看价格></span>
                             <span v-else-if="userID!=null && item.detailTalkFlag==2">价格详聊</span>
-                            <span v-else>¥{{item.price1Str}}</span>
+                            <span v-else>¥{{item.price}}</span>
                         </div>
                         <div class="shijian">
                             <div>

+ 1 - 3
src/main/resources/templates/index.html

@@ -150,7 +150,7 @@
                                                                     <template th:text="*{promotions.name}"></template>
                                                                     <th:block th:if="*{promotions.type}==1 and *{promotions.mode}==1">
                                                                         <!--单品优惠:优惠价-->
-                                                                        <span class="price_num"></span>
+                                                                        :¥<span class="price_num"></span>
                                                                     </th:block>
                                                                 </p>
                                                             </div>
@@ -180,8 +180,6 @@
                                                                 <div class="price_text_tag"></div>
                                                                 <div th:if="*{detailTalkFlag}==2" class="main_price_show">¥价格祥聊</div>
                                                                 <div th:if="*{detailTalkFlag}!=2" class="main_price_show">¥<span class="price_num"></span></div>
-                                                                <!--供应商显示价格等级-->
-                                                                <em class="price_grade_shop"><span class="bold">¥</span><i th:attr="class=*{'icon mIcon price_grade_'+priceGrade}"></i></em>
                                                             </div>
                                                         </th:block>
                                                     </div>

+ 4 - 2
src/main/resources/templates/product/instruelist.html

@@ -97,10 +97,12 @@
                                            <div class="price_text_tag">
                                                 <p class="listTag" v-if="p.actStatus==1">
                                                     {{p.promotions.name}}
-                                                    <span v-if="p.priceFlag != 1">:¥{{p.promotions.retailPrice | NumFormat}}</span>
+                                                    <span v-if="p.priceFlag != 1 && PromotionsFormat(p.promotions)">:¥{{p.price | NumFormat}}</span>
                                                 </p>
                                             </div>
-                                            <div class="main_price_show" v-text="'¥'+parseFloat(p.price).toFixed(2)"></div>
+                                            <div class="main_price_show" :class="PromotionsFormat(p.promotions) ? 'none' : ''">
+                                                ¥{{ (PromotionsFormat(p.promotions) ? p.originalPrice : p.price ) | NumFormat }}
+                                            </div>
                                         </template>
                                         <template v-else-if="p.priceFlag==2 && p.userIdentity==4">
                                              <div class="price_text_tag">

+ 1 - 3
src/main/resources/templates/supplier-center/shop/preview.html

@@ -53,8 +53,7 @@
                     <div class="info price">
                         <span class="label">价&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;格:</span>
                         <p>
-                            <span class="fave-tag">优惠价</span>
-                            <span class="fave-text">¥<span class="big">{{toFixedFn(shopInfo.price1)}}</span></span>
+                            <span class="fave-text">¥<span class="big">{{toFixedFn(shopInfo.price)}}</span></span>
                             <span class="fave-text-none">¥{{toFixedFn(shopInfo.normalPrice)}}</span>
                         </p>
                     </div>
@@ -173,7 +172,6 @@
         </div>
     </div>
 </div>
-
 <!-- 引入底部 -->
 <template th:replace="components/footer"></template>
 <template th:replace="components/foot-link"></template>

BIN
target/www-0.0.1-SNAPSHOT.jar