Authored by lea guo

yohood原价购 分享

@@ -94,7 +94,7 @@ Component({ @@ -94,7 +94,7 @@ Component({
94 }); 94 });
95 this.setData({ 95 this.setData({
96 remainingTime: fomartTimes.join(':') || '00:00:00', 96 remainingTime: fomartTimes.join(':') || '00:00:00',
97 - isStart: fomartTimes.length === 0 && this.properties.status === 1, 97 + isStart: fomartTimes.join('') === "000000" && this.properties.status === 1,
98 }); 98 });
99 }, 1000); 99 }, 1000);
100 }, 100 },
@@ -14,7 +14,7 @@ @@ -14,7 +14,7 @@
14 </form> 14 </form>
15 </block> 15 </block>
16 <block wx:elif="{{status === 3}}"> 16 <block wx:elif="{{status === 3}}">
17 - <view class="action-item ok" bindtap="goShare">邀请好友参加,增加中奖率</view> 17 + <button class="action-item ok" bindtap="goShare" open-type="share">邀请好友参加,增加中奖率</button>
18 </block> 18 </block>
19 <block wx:elif="{{status >= 3}}"> 19 <block wx:elif="{{status >= 3}}">
20 <view class="action-item over">已结束</view> 20 <view class="action-item over">已结束</view>
@@ -42,7 +42,7 @@ @@ -42,7 +42,7 @@
42 <view class="code">{{code}}</view> 42 <view class="code">{{code}}</view>
43 </view> 43 </view>
44 <form bindsubmit='submitFormId' report-submit='true'> 44 <form bindsubmit='submitFormId' report-submit='true'>
45 - <button class="share" form-type="submit" bindtap="hadJoinToShare">分享一下,中奖概率立马double</button> 45 + <button open-type="share" class="share" form-type="submit" bindtap="hadJoinToShare">分享一下,中奖概率立马double</button>
46 </form> 46 </form>
47 <view class="share-desc">1个好友参加=1个抽奖码=中奖几率UP!</view> 47 <view class="share-desc">1个好友参加=1个抽奖码=中奖几率UP!</view>
48 </view> 48 </view>
@@ -43,7 +43,7 @@ Component({ @@ -43,7 +43,7 @@ Component({
43 const formatTimeList = this.formatCountDown(); 43 const formatTimeList = this.formatCountDown();
44 this.setData({ 44 this.setData({
45 formatTimeList: formatTimeList, 45 formatTimeList: formatTimeList,
46 - isEnd: formatTimeList.length === 0 && this.properties.product.status === 2, 46 + isEnd: formatTimeList.join('') === "000000" && this.properties.product.status === 2,
47 }); 47 });
48 }, 1000); 48 }, 1000);
49 }, 49 },
@@ -7,7 +7,7 @@ import { @@ -7,7 +7,7 @@ import {
7 openAuthorizeSettings, 7 openAuthorizeSettings,
8 } from '../../utils/login'; 8 } from '../../utils/login';
9 import { getQRCodeSource } from '../../libs/miniQRCodeRoute'; 9 import { getQRCodeSource } from '../../libs/miniQRCodeRoute';
10 -import { Actionsheet, Toast } from '../../vendors/zanui/index'; 10 +import { Toast } from '../../vendors/zanui/index';
11 import router from './router/router'; 11 import router from './router/router';
12 import { wrapperName } from './helper'; 12 import { wrapperName } from './helper';
13 import { formatImageUrl } from '../../utils/util'; 13 import { formatImageUrl } from '../../utils/util';
@@ -73,30 +73,6 @@ Page( @@ -73,30 +73,6 @@ Page(
73 loading: false, 73 loading: false,
74 page: 1, 74 page: 1,
75 codeList: [], 75 codeList: [],
76 - actionsheet: {  
77 - componentId: 'shareActionSheet',  
78 - show: false,  
79 - closeOnClickOverlay: true,  
80 - cancelText: '取消',  
81 - isNewShareStyle: true,  
82 - // unionUserImageUrl: 'http://img12.static.yhbimg.com/sns/2018/08/02/15/029b6acc4f8bc0620ecd7ec2133fcf900c.png',  
83 - unionUserImageUrl: './images/share_tip@2x.png',  
84 - actions: [  
85 - {  
86 - name: '分享给好友',  
87 - className: 'action-class',  
88 - loading: false,  
89 - openType: 'share',  
90 - image_src: '../../images/share_wechat@2x.png',  
91 - },  
92 - {  
93 - name: '生成海报分享',  
94 - className: 'action-class',  
95 - loading: false,  
96 - image_src: '../../images/share_wxpeng@2x.png',  
97 - },  
98 - ],  
99 - },  
100 animation: null, 76 animation: null,
101 shareFlag: false, 77 shareFlag: false,
102 notice: {}, 78 notice: {},
@@ -337,19 +313,10 @@ Page( @@ -337,19 +313,10 @@ Page(
337 313
338 this._getMineCode(product.id); 314 this._getMineCode(product.id);
339 315
340 - let snapData = {  
341 - product_name: product.name,  
342 - default_image: product.cover_img,  
343 - product_price: product.price,  
344 - product_qrCode: qrcode,  
345 - };  
346 -  
347 this.setData({ 316 this.setData({
348 product: product, 317 product: product,
349 actPrizeId: this.data.actPrizeId || product.id || '', 318 actPrizeId: this.data.actPrizeId || product.id || '',
350 -  
351 myPrizeCount: r1.code === 200 ? r1.data.myCodeNum : 0, 319 myPrizeCount: r1.code === 200 ? r1.data.myCodeNum : 0,
352 - snapData,  
353 notice: JSON.parse(product.notice || '{}'), 320 notice: JSON.parse(product.notice || '{}'),
354 lottery: JSON.parse(product.lottery_info || '{}'), 321 lottery: JSON.parse(product.lottery_info || '{}'),
355 }); 322 });
@@ -675,7 +642,6 @@ Page( @@ -675,7 +642,6 @@ Page(
675 } 642 }
676 }, 643 },
677 }, 644 },
678 - Actionsheet,  
679 Toast, 645 Toast,
680 ), 646 ),
681 ); 647 );
@@ -43,8 +43,6 @@ @@ -43,8 +43,6 @@
43 <action-bar activity-status="{{product.status}}" start-time="{{product.start_time}}" is-login="{{isLogin}}" status="{{actionStatus}}" num="{{myPrizeCount}}" share-uid="{{shareUid}}" act-id="{{actPrizeId}}" bindchangeStatus="changeActionStatus" bindshare="share" copyText="{{lottery.miniappCopy}}" text="{{lottery.miniappTip}}" bindgaincodesuccess="reportSuccess" type="{{lottery.miniappType}}"></action-bar> 43 <action-bar activity-status="{{product.status}}" start-time="{{product.start_time}}" is-login="{{isLogin}}" status="{{actionStatus}}" num="{{myPrizeCount}}" share-uid="{{shareUid}}" act-id="{{actPrizeId}}" bindchangeStatus="changeActionStatus" bindshare="share" copyText="{{lottery.miniappCopy}}" text="{{lottery.miniappTip}}" bindgaincodesuccess="reportSuccess" type="{{lottery.miniappType}}"></action-bar>
44 </view> 44 </view>
45 <view class="foot"></view> 45 <view class="foot"></view>
46 -<import src="../../vendors/zanui/actionsheet/index.wxml" />  
47 -<template is="zan-actionsheet" data="{{...actionsheet}}" />  
48 <import src="../../vendors/zanui/toast/index.wxml" /> 46 <import src="../../vendors/zanui/toast/index.wxml" />
49 <template is="zan-toast" data="{{zanToast}}" /> 47 <template is="zan-toast" data="{{zanToast}}" />
50 <import src="../../vendors/toast/wetoast.wxml" /> 48 <import src="../../vendors/toast/wetoast.wxml" />