Commit 35da1d29c4f1a56565f21349b7330b575fa6ef98
1 parent
00ddf4f0
拼团参团优化 隐私安全的优化
Showing
6 changed files
with
120 additions
and
23 deletions
packageA/pages/serviceCard_pd/team_show/team_show.js
| ... | ... | @@ -140,7 +140,13 @@ Page({ |
| 140 | 140 | |
| 141 | 141 | //显示加载 |
| 142 | 142 | onShow:function(){ |
| 143 | - getApp().check_can_share(); | |
| 143 | + //-- 看一下隐私政策要不要显示 -- | |
| 144 | + var privacy_pop = this.selectComponent("#privacy_pop"); //组件的id | |
| 145 | + if (privacy_pop) { | |
| 146 | + privacy_pop.check_pri_show(); | |
| 147 | + } | |
| 148 | + | |
| 149 | + getApp().check_can_share(); | |
| 144 | 150 | var tg_id = this.data.tg_id,th=this; |
| 145 | 151 | this.init(tg_id); |
| 146 | 152 | }, |
| ... | ... | @@ -1615,7 +1621,46 @@ Page({ |
| 1615 | 1621 | go_to:function (e) { |
| 1616 | 1622 | var url=e.currentTarget.dataset.url; |
| 1617 | 1623 | getApp().goto(url); |
| 1618 | - } | |
| 1624 | + }, | |
| 1625 | + | |
| 1626 | + //-- 弹出框的同意的优化,重新获取定位 --- | |
| 1627 | + agree_pri:function (){ | |
| 1628 | + var th=this; | |
| 1629 | + var bconfig = th.data.bconfig; | |
| 1630 | + if (bconfig && bconfig.is_sort_storage) { | |
| 1631 | + wx.getLocation({ | |
| 1632 | + type: 'gcj02', | |
| 1633 | + success: function (res) { | |
| 1634 | + th.data.lat = res.latitude; | |
| 1635 | + th.data.lon = res.longitude; | |
| 1636 | + th.data.is_get_local_ok = 1; | |
| 1637 | + th.setData({ | |
| 1638 | + is_gps: 1 | |
| 1639 | + }); | |
| 1640 | + //th.onShow(); | |
| 1641 | + th.get_sto(); | |
| 1642 | + }, | |
| 1643 | + fail: function (res) { | |
| 1644 | + //th.onShow(); | |
| 1645 | + th.data.is_get_local_ok = 1; | |
| 1646 | + th.get_sto(); | |
| 1647 | + if (res.errCode == 2) { | |
| 1648 | + th.setData({ | |
| 1649 | + is_gps: 0 | |
| 1650 | + }); | |
| 1651 | + if (th.data.is_gps == 0) { | |
| 1652 | + getApp().confirmBox("请开启GPS定位", null, 25000, !1); | |
| 1653 | + } | |
| 1654 | + } else { | |
| 1655 | + th.setData({ | |
| 1656 | + is_gps: "3" | |
| 1657 | + }); | |
| 1658 | + } | |
| 1659 | + | |
| 1660 | + } | |
| 1661 | + }) | |
| 1662 | + } | |
| 1663 | + }, | |
| 1619 | 1664 | |
| 1620 | 1665 | |
| 1621 | 1666 | ... | ... |
packageA/pages/serviceCard_pd/team_show/team_show.json
packageA/pages/serviceCard_pd/team_show/team_show.wxml
| 1 | +<!-- 判断隐私是不是显示 --> | |
| 2 | +<privacy_pop id="privacy_pop" bind:agree_pri="agree_pri"></privacy_pop> | |
| 3 | + | |
| 1 | 4 | <wxs module="filters" src="../../../../utils/filter.wxs"></wxs> |
| 2 | 5 | <!---- //文字"--> |
| 3 | 6 | <view wx:if="{{is_show}}"> |
| ... | ... | @@ -11,13 +14,13 @@ |
| 11 | 14 | <view class='cenrt'> |
| 12 | 15 | |
| 13 | 16 | <view class='xc-goods-details ellipsis-2 fs28'> |
| 14 | - <span>{{goods.serviceName}}</span> | |
| 17 | + <text>{{goods.serviceName}}</text> | |
| 15 | 18 | </view> |
| 16 | 19 | </view> |
| 17 | 20 | <view class='cenrcen flex-vertical-between'> |
| 18 | 21 | <view> |
| 19 | 22 | <view class="fs40 xc-wc" style='font-size:40rpx'> |
| 20 | - <span class="fs28" style="font-weight:500;">¥</span>{{teamlist.price}}</view> | |
| 23 | + <text class="fs28" style="font-weight:500;">¥</text>{{teamlist.price}}</view> | |
| 21 | 24 | <view class="fs22 word-line xc-wc"> |
| 22 | 25 | 零售价¥{{goods.show_price}} |
| 23 | 26 | </view> |
| ... | ... | @@ -62,7 +65,7 @@ |
| 62 | 65 | <view class='bodyimg flex-level' wx:for="{{ordertx2}}" wx:key> |
| 63 | 66 | <view class='d'> |
| 64 | 67 | <image src='{{item.head_pic}}'></image> |
| 65 | - <span wx:if="{{item.is_pt_tz==1}}">团长</span> | |
| 68 | + <text wx:if="{{item.is_pt_tz==1}}">团长</text> | |
| 66 | 69 | </view> |
| 67 | 70 | </view> |
| 68 | 71 | <view class='d' wx:for="{{sf_arr}}"> |
| ... | ... | @@ -84,10 +87,10 @@ |
| 84 | 87 | <!--许程 <view class='bodytimecen' wx:if='{{obj}}'> --> |
| 85 | 88 | <view class='bodytimecen'> |
| 86 | 89 | 剩余 |
| 87 | - <span wx:if="{{obj.day!=0}}"> {{obj.day}} </span>: | |
| 88 | - <span> {{obj.hou}} </span>: | |
| 89 | - <span> {{obj.min}} </span>: | |
| 90 | - <span> {{obj.sec}} </span>结束 | |
| 90 | + <text wx:if="{{obj.day!=0}}"> {{obj.day}} </text>: | |
| 91 | + <text> {{obj.hou}} </text>: | |
| 92 | + <text> {{obj.min}} </text>: | |
| 93 | + <text> {{obj.sec}} </text>结束 | |
| 91 | 94 | </view> |
| 92 | 95 | |
| 93 | 96 | |
| ... | ... | @@ -131,21 +134,21 @@ |
| 131 | 134 | <view class='mck'> |
| 132 | 135 | <view class='bodyfoot'> |
| 133 | 136 | <view class='bodyselect' wx:if="{{zk}}" bindtap='czk'> |
| 134 | - <span>展开拼团列表 | |
| 137 | + <text>展开拼团列表 | |
| 135 | 138 | <view class='down-arrow'></view> |
| 136 | - </span> | |
| 139 | + </text> | |
| 137 | 140 | </view> |
| 138 | 141 | <!----收起拼团列表----> |
| 139 | 142 | <view class='zhangxi' wx:if="{{hiddenName}}"> |
| 140 | 143 | |
| 141 | - <view class='zspan' bindtap='click'>收起拼团列表 | |
| 144 | + <view class='ztext' bindtap='click'>收起拼团列表 | |
| 142 | 145 | <view class='down-arrow1'></view> |
| 143 | 146 | </view> |
| 144 | 147 | |
| 145 | 148 | <view class="ia" wx:for="{{ordertx}}" wx:for-index="ky"> |
| 146 | 149 | <view class='img'> |
| 147 | 150 | <image src='{{item.head_pic}}'></image> |
| 148 | - <span>{{item.nickname}}</span> | |
| 151 | + <text>{{item.nickname}}</text> | |
| 149 | 152 | </view> |
| 150 | 153 | <view class='zssj' wx:if="{{ky==0}}">{{item.add_time_date}} 开团</view> |
| 151 | 154 | <view class='zssj' wx:else>{{item.add_time_date}} 参团</view> |
| ... | ... | @@ -157,7 +160,7 @@ |
| 157 | 160 | <!--大家都在团--> |
| 158 | 161 | <view class='goodslist'> |
| 159 | 162 | <view class='goodslisttop'> |
| 160 | - <span class='goodslistspan'>大家都在团</span> | |
| 163 | + <text class='goodslisttext'>大家都在团</text> | |
| 161 | 164 | <view class='goodslisttopright'></view> |
| 162 | 165 | </view> |
| 163 | 166 | <view class="changxin"> |
| ... | ... | @@ -171,7 +174,7 @@ |
| 171 | 174 | <view class='price'> |
| 172 | 175 | <view class='jgleft'>¥{{item.price}}</view> |
| 173 | 176 | <view class='jgright'>{{item.ct_num}}人 |
| 174 | - <span>参团</span> | |
| 177 | + <text>参团</text> | |
| 175 | 178 | </view> |
| 176 | 179 | </view> |
| 177 | 180 | </view> |
| ... | ... | @@ -194,7 +197,7 @@ |
| 194 | 197 | <view class="spec-goods-name ellipsis-1">{{goods.serviceName}}</view> |
| 195 | 198 | <view class="flex ai_end xc-val-money"> |
| 196 | 199 | <view class="spec-goods-price"> |
| 197 | - <span class='t1'>¥</span><text class='t2'>{{teamlist.kttype==3?teamlist.yf_price:teamlist.price}}</text> | |
| 200 | + <text class='t1'>¥</text><text class='t2'>{{teamlist.kttype==3?teamlist.yf_price:teamlist.price}}</text> | |
| 198 | 201 | </view> |
| 199 | 202 | </view> |
| 200 | 203 | <view class="flex"> |
| ... | ... | @@ -300,7 +303,7 @@ |
| 300 | 303 | </view> |
| 301 | 304 | </view> |
| 302 | 305 | <view> |
| 303 | - <view class="distance fs24 address-val"wx:if="{{item.distance!=null}}"> | |
| 306 | + <view class="distance fs24 address-val" wx:if="{{item.distance!=null}}"> | |
| 304 | 307 | 距离:{{item.distance>1000?filters.toFix(item.distance/1000,2)+'km':filters.toFix(item.distance,0)+"m"}}</view> |
| 305 | 308 | </view> |
| 306 | 309 | </view> |
| ... | ... | @@ -360,7 +363,7 @@ |
| 360 | 363 | </view> |
| 361 | 364 | </view> |
| 362 | 365 | <view> |
| 363 | - <view class="distance fs24 address-val"wx:if="{{item.distance!=null}}"> | |
| 366 | + <view class="distance fs24 address-val" wx:if="{{item.distance!=null}}"> | |
| 364 | 367 | 距离:{{item.distance>1000?filters.toFix(item.distance/1000,2)+"km":filters.toFix(item.distance,0)+"m"}}</view> |
| 365 | 368 | </view> |
| 366 | 369 | </view> |
| ... | ... | @@ -377,7 +380,7 @@ |
| 377 | 380 | <view class="store-bottom flex-vertical-between"> |
| 378 | 381 | <view class="determine red-b fs28 white t-c" bindtap="sure_pick" |
| 379 | 382 | data-openindstore="{{open_ind_store}}">确定</view> |
| 380 | - <view class="default t-c fs28" bindtap="set_def_pick"data-openindstore="{{open_ind_store}}">设为默认</view> | |
| 383 | + <view class="default t-c fs28" bindtap="set_def_pick" data-openindstore="{{open_ind_store}}">设为默认</view> | |
| 381 | 384 | </view> |
| 382 | 385 | </view> |
| 383 | 386 | ... | ... |
pages/team/team_show/team_show.js
| ... | ... | @@ -144,7 +144,13 @@ Page({ |
| 144 | 144 | |
| 145 | 145 | //显示加载 |
| 146 | 146 | onShow:function(){ |
| 147 | - getApp().check_can_share(); | |
| 147 | + //-- 看一下隐私政策要不要显示 -- | |
| 148 | + var privacy_pop = this.selectComponent("#privacy_pop"); //组件的id | |
| 149 | + if (privacy_pop) { | |
| 150 | + privacy_pop.check_pri_show(); | |
| 151 | + } | |
| 152 | + | |
| 153 | + getApp().check_can_share(); | |
| 148 | 154 | var tg_id = this.data.tg_id,th=this; |
| 149 | 155 | this.init(tg_id); |
| 150 | 156 | }, |
| ... | ... | @@ -1633,7 +1639,45 @@ Page({ |
| 1633 | 1639 | }) |
| 1634 | 1640 | |
| 1635 | 1641 | }, |
| 1636 | - | |
| 1642 | + | |
| 1643 | + //-- 弹出框的同意的优化,重新获取定位 --- | |
| 1644 | + agree_pri:function (){ | |
| 1645 | + var th=this; | |
| 1646 | + var bconfig = th.data.bconfig; | |
| 1647 | + if (bconfig && bconfig.is_sort_storage) { | |
| 1648 | + wx.getLocation({ | |
| 1649 | + type: 'gcj02', | |
| 1650 | + success: function (res) { | |
| 1651 | + th.data.lat = res.latitude; | |
| 1652 | + th.data.lon = res.longitude; | |
| 1653 | + th.data.is_get_local_ok = 1; | |
| 1654 | + th.setData({ | |
| 1655 | + is_gps: 1 | |
| 1656 | + }); | |
| 1657 | + //th.onShow(); | |
| 1658 | + th.get_sto(); | |
| 1659 | + }, | |
| 1660 | + fail: function (res) { | |
| 1661 | + //th.onShow(); | |
| 1662 | + th.data.is_get_local_ok = 1; | |
| 1663 | + th.get_sto(); | |
| 1664 | + if (res.errCode == 2) { | |
| 1665 | + th.setData({ | |
| 1666 | + is_gps: 0 | |
| 1667 | + }); | |
| 1668 | + if (th.data.is_gps == 0) { | |
| 1669 | + getApp().confirmBox("请开启GPS定位", null, 25000, !1); | |
| 1670 | + } | |
| 1671 | + } else { | |
| 1672 | + th.setData({ | |
| 1673 | + is_gps: "3" | |
| 1674 | + }); | |
| 1675 | + } | |
| 1676 | + | |
| 1677 | + } | |
| 1678 | + }) | |
| 1679 | + } | |
| 1680 | + }, | |
| 1637 | 1681 | |
| 1638 | 1682 | |
| 1639 | 1683 | ... | ... |
pages/team/team_show/team_show.json