[更新]
This commit is contained in:
@@ -77,13 +77,26 @@ Page({
|
||||
* 处理未登录时的转跳
|
||||
*/
|
||||
userNav(e){
|
||||
let id = e.currentTarget.dataset.id
|
||||
let newid = e.currentTarget.dataset.id,
|
||||
canFrom = e.currentTarget.dataset.from
|
||||
wx.getStorage({
|
||||
key : 'token',
|
||||
success:res=>{
|
||||
wx.navigateTo({
|
||||
url: '/pages/rights/rights?rightsId=' + id
|
||||
})
|
||||
if(canFrom == 'washcar') {
|
||||
wx.$api.index.washcarUrl('', newid).then(res=>{
|
||||
const newUrl = res.data
|
||||
let url= encodeURIComponent(newUrl)
|
||||
wx.redirectTo({
|
||||
// 跳转到webview页面
|
||||
url: `/pages/washcar/washcar?url=${url}`
|
||||
});
|
||||
})
|
||||
} else {
|
||||
// 跳转权益详情页
|
||||
wx.navigateTo({
|
||||
url: '/pages/rights/rights?rightsId=' + newid
|
||||
})
|
||||
}
|
||||
},
|
||||
fail: (err) => {
|
||||
wx.navigateTo({
|
||||
|
||||
@@ -30,7 +30,7 @@
|
||||
<view class="special-list">
|
||||
<block wx:if="{{infoItems.length > 0}}">
|
||||
<view bindtap="userNav" class="special-label" wx:for="{{infoItems}}" wx:key="infoItems"
|
||||
data-id="{{item.right_config_id}}">
|
||||
data-id="{{item.right_config_id}}" data-from="{{item.from}}">
|
||||
<view class="special-rebate" wx:if="{{item.label != ''}}">{{item.label}}</view>
|
||||
<scroll-view scroll-x class="welfareCont-top" scroll-with-animation>
|
||||
<view class="welfareCont-list-img" wx:for="{{item.logos}}" wx:key="logos" wx:for-item="items">
|
||||
|
||||
Reference in New Issue
Block a user