Commit 09e0fd4a9fb7095fd349163f5c1b7e02f9ab6ee1

Authored by yvan.ni
1 parent cb36fbf0

1.自定义模板 导航要显示背景颜色,显示字体颜色

2.自定义模板  拼团,秒杀要显示活动的名称
components/diy_nav/diy_nav.wxss
... ... @@ -134,7 +134,7 @@
134 134 .big_two {
135 135 display: inline-block;
136 136 width: 100%;
137   - min-height: 280rpx;
  137 + /* min-height: 280rpx; */
138 138 /* 先设置最小容器单位,min-height:280rpx;然后再设置auto */
139 139 height: auto;
140 140 }
... ... @@ -163,7 +163,7 @@ image {
163 163 /* 文字1 */
164 164  
165 165 .test {
166   - width: 60rpx;
  166 + /* width: 60rpx; */
167 167 height: 40rpx;
168 168 margin-left: 30rpx;
169 169 font-size: 30rpx;
... ...
components/diy_nav/diy_nav_part1.wxml
1   - <view style='width:{{100/nav_list.length}}%'
  1 + <view style='width:{{100/nav_list.length}}%;background-color: {{item.bgcolor}};'
2 2 class="{{object.seticon==1?'big_view_one':object.seticon==2?'big_view_two':'bicder_picture'}}">
3 3 <block wx:if="{{item.navicon==null}}">
4 4 <image style='width:{{object.sliderExample*2}}rpx;height:{{object.sliderExample*2}}rpx;'
5 5 class="{{object.seticon==1?'print_one':object.seticon==2?'print_two':'image_none'}}"
6 6 src="{{imghost}}/miniapp/images/nav-icon.png"></image>
7   - <view class="{{object.seticon==1?'font_one':object.seticon==2?'font_bicder_two':'font_three'}}">
  7 + <view class="{{object.seticon==1?'font_one':object.seticon==2?'font_bicder_two':'font_three'}}" style="color:{{item.txtcolor}};">
8 8 {{item.title}}
9 9 </view>
10 10 </block>
... ... @@ -12,7 +12,7 @@
12 12 <image style='width:{{object.sliderExample*2}}rpx;height:{{object.sliderExample*2}}rpx;'
13 13 class="{{object.seticon==1?'print_one':object.seticon==2?'print_two':'image_none'}}"
14 14 src="{{item.navicon}}"></image>
15   - <view class="{{object.seticon==1?'font_one':object.seticon==2?'font_bicder_two':'font_three'}}">
  15 + <view class="{{object.seticon==1?'font_one':object.seticon==2?'font_bicder_two':'font_three'}}" style="color:{{item.txtcolor}};">
16 16 {{item.title}}
17 17 </view>
18 18 </block>
... ...
components/diy_nav/diy_nav_part2.wxml
1   - <view class="one_div">
  1 + <view class="one_div" style='background-color: {{item.bgcolor}};padding:10rpx 0rpx;border-radius: 5rpx; '>
2 2 <view class="picture_one">
3 3 <block wx:if="{{item.navicon!=null}}">
4   - <image style='width:{{object.sliderExample*2}}rpx;height:{{object.sliderExample*2}}rpx;'
  4 + <image style='width:{{object.sliderExample*2}}rpx;height:{{object.sliderExample*2}}rpx;margin-top: 10rpx;'
5 5 src="{{item.navicon}}">
6 6 </image>
7 7 </block>
8 8  
9 9 <block wx:if="{{item.navicon==null}}">
10   - <image style='width:{{object.sliderExample*2}}rpx;height:{{object.sliderExample*2}}rpx;'
  10 + <image style='width:{{object.sliderExample*2}}rpx;height:{{object.sliderExample*2}}rpx;margin-top: 10rpx;'
11 11 src="{{imghost}}/miniapp/images/nav-icon.png">
12 12 </image>
13 13 </block>
14 14  
15 15 </view>
16   - <view class="test">{{item.title}}</view>
  16 + <view class="test" style="color:{{item.txtcolor}};">{{item.title}}</view>
17 17 </view>
... ...
components/diy_pingd_buy/diy_pingd_buy.wxml
... ... @@ -45,7 +45,7 @@
45 45 </view>
46 46  
47 47 <view class='sp_wz_p'>
48   - <view class='sp_wzi_p'>{{aitem.goods_name}}</view>
  48 + <view class='sp_wzi_p'>{{aitem.title}}</view>
49 49 <view class='sp_jg_p'>¥{{aitem.price}}</view>
50 50 <!--<view class='sp_jgx_p'>¥{{aitem.market_price}}</view>-->
51 51  
... ...
components/diy_seckill/diy_seckill.wxml
... ... @@ -52,7 +52,7 @@
52 52 </view>
53 53  
54 54 <view class='sp_wz'>
55   - <view class='sp_wzi'>{{aitem.goods_name}}</view>
  55 + <view class='sp_wzi'>{{aitem.title}}</view>
56 56 <view class='sp_jg'>¥{{aitem.price}}</view>
57 57 <view class='sp_jgx'>¥{{aitem.market_price}}</view>
58 58 </view>
... ... @@ -75,7 +75,7 @@
75 75 </view>
76 76  
77 77 <view class="o1_right">
78   - <view class="sp_wzi">{{aitem.goods_name}}</view>
  78 + <view class="sp_wzi">{{aitem.title}}</view>
79 79 <view class="o1_sj_kill">
80 80 <text>{{aitem.djs.day}}</text> 天
81 81 <text>{{aitem.djs.hou}}</text> :
... ...
components/diy_shopname/diy_shopname.js
... ... @@ -65,7 +65,15 @@ Component({
65 65 go_new_wares:function () {
66 66 var url="/pages/goods/goodsList/goodsList?is_new=1";
67 67 getApp().goto(url);
68   - }
  68 + },
  69 + //主图的图片显示
  70 + berror:function(e){
  71 + var err=e.currentTarget.dataset.err;
  72 + var url=this.data.imghost+'/public/static/images/model/bg.jpg';
  73 + var ob={};
  74 + ob[err]=url;
  75 + this.setData(ob);
  76 + }
69 77  
70 78 }
71 79 })
72 80 \ No newline at end of file
... ...
components/diy_shopname/diy_shopname.wxml
... ... @@ -3,7 +3,7 @@
3 3 <view class="big">
4 4  
5 5 <view class="big_picture_border">
6   - <image class="big_picture" src='{{object.srcimg}}'></image>
  6 + <image class="big_picture" src='{{object.srcimg}}' binderror="berror" data-err="object.srcimg"></image>
7 7 </view>
8 8 <block wx:if="{{object.style==1}}">
9 9  
... ...