Commit cd4fb867e6b21d67eec4119ea3023bed36b03dc7

Authored by taiyuan
2 parents 56fc8b31 c39a4157

Merge branch 'dev' of http://git.vipzhuang.cn/wxd/MShopWeApp into dev

... ... @@ -718,6 +718,12 @@ App({
718 718 resolve(user_info);
719 719 };
720 720 });
  721 +
  722 +
  723 +
  724 +
  725 +
  726 +
721 727 },
722 728  
723 729  
... ...
components/my_confirm/my_confirm.wxml
... ... @@ -6,8 +6,8 @@
6 6 <view class="shut" bindtap="close_yu_e">ⅹ</view>
7 7 <view class="fs32 xc-black3 flex jc-center ai-center" style="padding: 10rpx 20rpx;min-height:220rpx;"><text>{{title}}</text></view>
8 8 <view class="flex jc-center ai_center" style="width: 100%;height: 75rpx;">
9   - <view bindtap="go_sure" class="fs30 white flex jc-center ai-center ck_btn color color" style="margin-right: 20rpx;">{{s_text}}</view>
10   - <view bindtap='go_cancle' class="fs30 xc-ash flex jc-center ai-center ck_btn"style="background:#ececea;">{{c_text}}</view>
  9 + <view bindtap="go_sure" class="fs30 white flex jc-center ai-center ck_btn" style="margin-right: 20rpx;background:#ececea;">{{s_text}}</view>
  10 + <view bindtap='go_cancle' class="fs30 xc-ash flex jc-center ai-center ck_btn color" >{{c_text}}</view>
11 11 </view>
12 12 </view>
13 13 </view>
... ...
components/my_confirm/my_confirm.wxss
1   -
  1 +@import '../../app.wxss';
2 2 /* 弹窗样式 */
3 3 .xc-pop-up{
4 4 width: 100%;
... ... @@ -23,19 +23,19 @@
23 23  
24 24 .shut{
25 25 display: block;
26   - width: 54rpx;
27   - height: 54rpx;
28   - font-size: 50rpx;
29   - line-height:47rpx;
  26 + width: 45rpx;
  27 + height: 45rpx;
  28 + line-height:36rpx;
30 29 border-radius: 50%;
31 30 -moz-border-radius: 50%;
32 31 -webkit-border-radius: 50%;
  32 + font-size: 40rpx;
33 33 color: #fff;
34 34 text-align: center;
35 35 position: fixed;
36   - margin-top: -23rpx;
37 36 z-index: 66666;
38   - right: 60rpx;
  37 + right: 75rpx;
  38 + top: 465rpx;
39 39 background: #c8162c;
40 40 }
41 41 .xc-qr-frame{
... ... @@ -50,7 +50,7 @@
50 50 margin-left: -280rpx; border-radius:10rpx
51 51 }
52 52  
53   -.ck_btn{width:44%;height:52rpx;line-height:60rpx;background:#f35e73;border-radius:10rpx;}
  53 +.ck_btn{color: #000; width:44%;height:52rpx;line-height:60rpx;background:#f35e73;border-radius:10rpx;}
54 54  
55 55 .fs36{ font-size: 36rpx; }
56 56 .fs30{ font-size: 30rpx; }
... ...
components/qr_code/qr_code.wxml
... ... @@ -24,7 +24,7 @@
24 24 </view>
25 25  
26 26 </view>
27   - <view class="shut" bindtap="close"></view>
  27 + <view class="shut" bindtap="close"><text class="iconfont icon-close"></text></view>
28 28 </view>
29 29 <!-- </scroll-view> -->
30 30 </view>
31 31 \ No newline at end of file
... ...
components/qr_code/qr_code.wxss
  1 +@import '../../app.wxss';
  2 +
1 3 .xc-pop-up{
2 4 width: 100%;
3 5 height: 100%;
... ... @@ -90,36 +92,39 @@ top: 5rpx;
90 92 .qrcode{
91 93 width:520rpx;
92 94 height:520rpx;
93   - margin-top:-27rpx
  95 + margin-top:-18rpx
94 96  
95 97  
96 98 }
97 99 .r-code{
98 100 font-size:28rpx;
99   - padding-left: 25rpx;
100   -margin-top: -5.5rpx;
  101 + margin-top: -5.5rpx;
  102 + text-align: center;
101 103  
102 104 }
103 105  
104 106 .shut{
105   - display: block;
  107 + /* display: block;
106 108 width: 54rpx;
107 109 height: 54rpx;
108 110 border: 2rpx solid #fff;
109 111 font-size: 50rpx;
110   - z-index:55;
111   - line-height:47rpx;
  112 + line-height:54rpx;
112 113 margin-top: 45rpx;
113 114 border-radius: 50%;
114 115 -moz-border-radius: 50%;
115   - -webkit-border-radius: 50%;
  116 + -webkit-border-radius: 50%; */
  117 + z-index:55;
116 118 color: #fff;
117 119 text-align: center;
118 120 position: fixed;
119 121 top:940rpx;
120   - left:345rpx;
121   -
122   -
  122 + left:50%;
  123 + transform: translateX(-50%);
  124 +}
  125 +.icon-close:before {
  126 + content: "\e62e";
  127 + font-size: 50rpx;
123 128 }
124 129  
125 130 .mt{ margin-top:130rpx}
... ...
packageA/pages/myGift/myGift.js
... ... @@ -144,8 +144,9 @@ Page({
144 144 isShowLoading: true,
145 145 })
146 146 .then(function(res) {
  147 + console.log(res);
147 148 if(res.data.code == 0) {
148   -
  149 +
149 150 self.setData({
150 151 isLoading: false
151 152 });
... ... @@ -154,10 +155,12 @@ Page({
154 155 self.setData({
155 156 list: res.data.data
156 157 });
  158 + // console.log(this.data.list);
157 159 } else {
158 160 self.setData({
159 161 'list.pageData': self.data.list.pageData.concat(res.data.data.pageData)
160 162 });
  163 +
161 164 };
162 165  
163 166 if((res.data.data.pageData.length == 0) || (res.data.data.pageSize * res.data.data.page >= res.data.data.total)) {
... ... @@ -312,5 +315,19 @@ Page({
312 315  
313 316 })
314 317 },
  318 +
  319 +
  320 + show_remark:function(e){
  321 + var index=e.currentTarget.dataset.index;
  322 + var item=this.data.list.pageData[index];
  323 + this.setData({
  324 + show_rem_pop:1,
  325 + pop_remark_text:item.lbintro
  326 + })
  327 + },
  328 +
  329 + close_remark:function(){
  330 + this.setData({show_rem_pop:0,})
  331 + }
315 332  
316 333 })
317 334 \ No newline at end of file
... ...
packageA/pages/myGift/myGift.wxml
... ... @@ -8,7 +8,10 @@
8 8 <view class="tab-item" wx:for="{{list.pageData}}">
9 9 <view bindtap="goto" data-url="{{'/packageA/pages/myGiftDetails/myGiftDetails?index=0&id=' + item.id}}">
10 10 <!-- 图片 -->
11   - <view class="img-container"><image src="{{imghost + (item.lburl ? item.lburl:'miniapp/images/default_g_img.gif')}}" class="img" mode="widthFix"/></view>
  11 + <view class="img-container rel">
  12 + <image src="{{imghost + (item.lburl ? item.lburl:'miniapp/images/default_g_img.gif')}}" class="img" mode="widthFix"/>
  13 + <view catchtap="show_remark" data-index="{{index}}" class="lb_remark ellipsis-1" wx:if="{{item.lbintro}}">活动说明:{{item.lbintro}}</view>
  14 + </view>
12 15 <view class="desc-container">
13 16 <!-- 标题 -->
14 17 <view class="mgb10 ellipsis-2 lh taj">{{item.lbtitle}}</view>
... ... @@ -33,7 +36,7 @@
33 36 <view class="fs24 c-a4">已售{{item.salenum}}件</view>
34 37 </view>
35 38 <!-- 时间 -->
36   - <view class="date">活动截止日期 {{filter.format_time(item.expdate)}}</view>
  39 + <view class="date">活动结束日期 {{filter.format_time(item.endtime)}}</view>
37 40 <!-- 按钮 -->
38 41 </view>
39 42 </view>
... ... @@ -52,10 +55,11 @@
52 55 <!-- 标题 -->
53 56 <view class="mgb10 ellipsis-2 lh taj">{{item.lbtitle}}</view>
54 57 <!-- 时间 -->
55   - <view class="date pdb20">活动截止日期 {{filter.format_time(item.endtime)}}</view>
  58 + <view class="date pdb20">兑换截止日期 {{filter.format_time(item.expdate,1)}}</view>
  59 + <view catchtap="show_remark" data-index="{{index}}" wx:if="{{item.lbintro}}" class="date pdb20">活动说明</view>
56 60 </view>
57 61 <!-- 说明 -->
58   - <view class="c-red fs24">*请到线下门店兑换</view>
  62 + <view wx:if="{{item.lbtype==1}}" class="c-red fs24">注:请到线下门店兑换</view>
59 63 </view>
60 64 </view>
61 65 </block>
... ... @@ -68,3 +72,13 @@
68 72 <!-- 引入提示组件 -->
69 73 <warn id="warn"></warn>
70 74 <my_confirm id="my_confirm"></my_confirm>
  75 +<view wx:if="{{show_rem_pop}}">
  76 + <view class="cover-layer" bindtap="close_remark"></view>
  77 + <view class="rem_pop;">
  78 + <view style="text-align: right;"bindtap="close_remark"><text class="iconfont icon-close" style="font-size: 40rpx;"></text></view>
  79 + <view style="padding: 0 16rpx;">
  80 + <view class="fs32">活动说明:</view>
  81 + <view class="fs30">{{pop_remark_text}}</view>
  82 + </view>
  83 + </view>
  84 +</view>
71 85 \ No newline at end of file
... ...
packageA/pages/myGift/myGift.wxss
... ... @@ -164,4 +164,28 @@ page {
164 164 color: #bbb;
165 165 text-align: center;
166 166 font-size: 22rpx;
167   -}
168 167 \ No newline at end of file
  168 +}
  169 +.lb_remark{
  170 + position: absolute;
  171 + bottom: 0;
  172 + left: 0;
  173 + width: 100%;
  174 + height: 50rpx;
  175 + line-height: 50rpx;
  176 + font-size: 30rpx;
  177 + color: #333;
  178 + padding-left: 10rpx;
  179 + background-color: rgba(250,250,250,0.5);
  180 +}
  181 +
  182 +.rem_pop{
  183 + position: fixed;
  184 + top: 30%;
  185 + left: 6%;
  186 + width: 88%;
  187 + margin: 0 auto;
  188 + height: 460rpx;
  189 + background-color: #fff;
  190 + z-index: 100; border-radius: 10rpx;
  191 + padding: 10rpx;
  192 +}
... ...
packageA/pages/myGiftDetails/myGiftDetails.js
... ... @@ -11,7 +11,7 @@ Page({
11 11 data: {
12 12 qr_code_object: {
13 13 val: "12121",
14   - content: "请将二维码展示给核销员,服务更快捷!"
  14 + content: "当前核销码仅限当面使用!"
15 15 },
16 16 },
17 17  
... ... @@ -72,7 +72,7 @@ Page({
72 72 if(res.data.code==0 && res.data.data && res.data.data.pageData && res.data.data.pageData.length>0){
73 73 var da= res.data.data.pageData[0]
74 74 self.setData({ details:da, });
75   -
  75 + console.log(da);
76 76 //礼包有俩种类型
77 77 if(da.lbtype==1){
78 78 app.request.promiseGet('/api/weshop/libao/libaoList/page', {
... ... @@ -94,6 +94,7 @@ Page({
94 94 },
95 95 isShowLoading: true,
96 96 }).then(function(res) {
  97 + console.log(res);
97 98 if(res.data.code==0){
98 99 self.setData({
99 100 list: res.data.data,
... ... @@ -150,6 +151,7 @@ Page({
150 151 },
151 152 isShowLoading: true,
152 153 }).then(function(res) {
  154 + console.log(res);
153 155 // console.log('res4-->', res);
154 156 if(res.data.code==0 && res.data.data) {
155 157 self.setData({
... ... @@ -290,6 +292,7 @@ Page({
290 292 getApp().request.get("/api/weshop/libao/libaoListvip/getLibaoCode",{
291 293 data:data,
292 294 success:function (res){
  295 + console.log(res);
293 296 if(res.data.code==0){
294 297 th.data.qr_code_object.val=res.data.data;
295 298 var qc_com = th.selectComponent("#qrcode"); //组件的id
... ...
packageA/pages/myGiftDetails/myGiftDetails.wxml
... ... @@ -3,7 +3,17 @@
3 3 <!-- 图片 -->
4 4 <view><image src="{{imghost + (details.lburl ? details.lburl:'miniapp/images/default_g_img.gif')}}" class="img" mode="widthFix"/></view>
5 5  
6   - <view wx:if="{{index==1}}" class="fs26 exp_title">兑换结束时间:{{filter.format_time(details.expdate,1)}}</view>
  6 + <!-- 未买 -->
  7 + <block wx:if="{{index==0}}">
  8 + <view class="fs26 exp_title">活动结束时间:{{filter.format_time(details.endtime,1)}}</view>
  9 + </block>
  10 + <!-- 已买 -->
  11 + <block wx:else>
  12 + <view wx:if="{{details.lbtype==1}}"class="fs26 exp_title">兑换结束时间:{{filter.format_time(details.expdate,1)}}</view>
  13 + </block>
  14 +
  15 +
  16 +
7 17 <!-- 描述-->
8 18 <view class="desc-container">
9 19 <!-- 标题 -->
... ... @@ -30,7 +40,7 @@
30 40 <view class="fs24 c-a4">已售{{details.salenum}}件</view>
31 41 </view>
32 42 <!-- 时间 -->
33   - <view class="date">活动截止日期 {{details.expdate ? filter.format_time(details.expdate):filter.format_time(details.endtime)}}</view>
  43 + <!-- <view class="date">活动结束日期 {{filter.format_time(details.endtime)}}</view> -->
34 44 </view>
35 45  
36 46  
... ... @@ -71,16 +81,40 @@
71 81 </view>
72 82  
73 83 <view wx:if="{{details.lbtype==2}}" class="flex" style="flex-wrap: wrap;">
74   - <block wx:for="{{list}}">
  84 + <block wx:for="{{list}}" wx:for-index="f_idx">
75 85 <block wx:for="{{item.goods_num-0}}" wx:for-item="nitem" wx:for-index="idx">
76 86 <view class="lb_quan" style="background-image: url({{imghost}}/miniapp/images/yhq_{{index%2+1}}.png)">
77 87 <view class="flex fs28 fir_view">
78   - <view>满1000.00使用</view>
79   - <view class="fs38" style="text-align: right">¥1000</view>
  88 + <view>满{{item.condition}}使用</view>
  89 + <view class="fs8" style="text-align: right">¥{{item.money}}</view>
80 90 </view>
81   - <view style="font-size: 16rpx; text-align: center">活动结束日期: 2022-06-02 00:00:00 </view>
  91 +
  92 +
  93 + <view style="font-size: 16rpx; text-align: center"> {{index==0?'活动结束日期':'截至时间'}}:
  94 +
  95 + <block wx:if="{{item.endtype<1}}">
  96 + <block wx:if="{{item.use_end_time}}">
  97 + {{filter.format_time(item.use_end_time,1)}}
  98 + </block>
  99 + <block wx:else>
  100 + 不限
  101 + </block>
  102 + </block>
  103 +
  104 + <block wx:else>
  105 + <block wx:if="{{item.days>0}}">
  106 + 有效期{{item.days}}天
  107 + </block>
  108 + <block wx:else>
  109 + 不限
  110 + </block>
  111 +
  112 + </block>
  113 + </view>
  114 +
  115 +
82 116 </view>
83   - </block>
  117 + </block>
84 118 </block>
85 119 </view>
86 120  
... ... @@ -106,7 +140,7 @@
106 140 <view wx:if="{{details.lbprice>0}}" bindtap="GetBuyPrice" class="btn pink">立即购买</view>
107 141 </block>
108 142 <block wx:else>
109   - <view wx:if="{{details.isget}}" data-type="1" class="btn" style="background-color:#aaa;color: #fff">已领</view>
  143 + <view wx:if="{{details.isget}}" data-type="1" class="btn" style="background-color:#aaa;color: #fff">已领</view>
110 144 <view wx:else bindtap="show_get_quan" data-type="1" class="btn red">一键领取优惠券→</view>
111 145 </block>
112 146 </view>
... ...
pages/index/index/index.js
... ... @@ -978,15 +978,27 @@ Page({
978 978 var giftBagId = res.data.data.gifBagId; //礼包id
979 979 var nav_url = "/pages/giftpack/festival/festival?actId=" + actid + '&' + 'actType=' + 3 + '&' + 'giftBagId=' + giftBagId;
980 980 var swiperimage = th.data.swiperimage;
981   - var actBoundImg = res.data.data.actBoundImg;
  981 + var actBoundImg = res.data.data.actBoundImg?res.data.data.actBoundImg:'/miniapp/images/default_g_img.gif';
982 982  
983 983 th.data.holiday_image= res.data.data.actImg;
984 984 th.data.holiday_url=nav_url;
985 985  
986 986 var img = {
987 987 image: actBoundImg,
988   - nav_url: nav_url
  988 + nav_url: nav_url,
  989 + id:res.data.data.id,
  990 + type:'festival'
989 991 }
  992 +
  993 + for(var i in swiperimage){
  994 + var item=swiperimage[i];
  995 + if(item.id ==img.id && type==img.type){
  996 + return false;
  997 + }
  998 + }
  999 +
  1000 +
  1001 +
990 1002 swiperimage.unshift(img);
991 1003 th.setData({
992 1004 swiperimage: swiperimage,
... ...
pages/index/index/index.wxml
... ... @@ -9,7 +9,7 @@
9 9 <!--普通界面-->
10 10 <wxs module="filter" src="../../../utils/filter.wxs"></wxs>
11 11  
12   -<view class="container rel" wx:if="{{ishow}}">
  12 +<view class="container rel nor" wx:if="{{ishow}}">
13 13 <block wx:if="{{banner}}">
14 14 <image class="xc-top-img abs" src="{{url}}/miniapp/images/top-img.png"></image>
15 15 </block>
... ...
pages/index/index/index.wxss
... ... @@ -9,7 +9,6 @@
9 9 z-index: 99;
10 10 }
11 11  
12   -
13 12 .search-box {
14 13 /* position: fixed;
15 14 top: 0;
... ... @@ -976,6 +975,10 @@ page {
976 975  
977 976 .container {
978 977 overflow: hidden;
  978 + /* padding-top: 140rpx; */
  979 +}
  980 +
  981 +.container.nor{
979 982 padding-top: 140rpx;
980 983 }
981 984  
... ...
project.config.json
... ... @@ -21,6 +21,7 @@
21 21 "checkSiteMap": true,
22 22 "uploadWithSourceMap": true,
23 23 "compileHotReLoad": false,
  24 + "lazyloadPlaceholderEnable": false,
24 25 "useMultiFrameRuntime": true,
25 26 "useApiHook": true,
26 27 "useApiHostProcess": false,
... ... @@ -30,12 +31,11 @@
30 31 "outputPath": ""
31 32 },
32 33 "useIsolateContext": true,
33   - "useCompilerModule": false,
34   - "userConfirmedUseCompilerModuleSwitch": false,
35 34 "userConfirmedBundleSwitch": false,
36 35 "packNpmManually": false,
37 36 "packNpmRelationList": [],
38   - "minifyWXSS": true
  37 + "minifyWXSS": true,
  38 + "showES6CompileOption": false
39 39 },
40 40 "compileType": "miniprogram",
41 41 "libVersion": "2.16.0",
... ...