7.10 增加登录页面,事件详情接口对接,我的点赞,关注收藏页面搭建,接口对接
This commit is contained in:
@@ -1,18 +1,39 @@
|
||||
"use strict";
|
||||
const common_vendor = require("../../../common/vendor.js");
|
||||
const request_api = require("../../../request/api.js");
|
||||
const common_assets = require("../../../common/assets.js");
|
||||
const _sfc_main = {
|
||||
data() {
|
||||
return {
|
||||
navH: common_vendor.inject("navHeight"),
|
||||
memberInfo: null,
|
||||
//会员信息
|
||||
privilegeList: ["高效选股工具", "股票基金明星榜单", "定期专属晨报、股票动态", "独家产业研报", "个股产业分析", "股票、基金基础指标", "7x24 财经直播"]
|
||||
};
|
||||
},
|
||||
onLoad() {
|
||||
this.getMemberStatus();
|
||||
},
|
||||
methods: {
|
||||
/**
|
||||
* 点击加入vip
|
||||
*/
|
||||
clickJoinVip() {
|
||||
},
|
||||
/**
|
||||
* 获取会员状态
|
||||
*/
|
||||
getMemberStatus() {
|
||||
request_api.membershipStatus().then((res) => {
|
||||
if (res.code == 200) {
|
||||
this.memberInfo = res.data;
|
||||
} else
|
||||
common_vendor.index.showToast({
|
||||
title: res.message,
|
||||
icon: "none"
|
||||
});
|
||||
}).catch((error) => {
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
@@ -25,20 +46,41 @@ if (!Math) {
|
||||
_easycom_navBar();
|
||||
}
|
||||
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
||||
return {
|
||||
return common_vendor.e({
|
||||
a: common_vendor.p({
|
||||
leftText: "会员中心"
|
||||
}),
|
||||
b: common_assets._imports_0,
|
||||
c: common_assets._imports_1$4,
|
||||
d: common_assets._imports_2$6,
|
||||
e: common_assets._imports_3$4,
|
||||
f: common_vendor.f($data.privilegeList, (item, index, i0) => {
|
||||
c: $data.memberInfo
|
||||
}, $data.memberInfo ? common_vendor.e({
|
||||
d: $data.memberInfo.is_member
|
||||
}, $data.memberInfo.is_member ? {
|
||||
e: common_assets._imports_1$5
|
||||
} : {
|
||||
f: common_assets._imports_2$7
|
||||
}, {
|
||||
g: $data.memberInfo.is_member
|
||||
}, $data.memberInfo.is_member ? {
|
||||
h: common_vendor.t($data.memberInfo.member_expire_date)
|
||||
} : {}, {
|
||||
i: $data.memberInfo.is_member
|
||||
}, $data.memberInfo.is_member ? {
|
||||
j: common_assets._imports_3$4
|
||||
} : {
|
||||
k: common_assets._imports_4$2
|
||||
}, {
|
||||
l: $data.memberInfo.is_member
|
||||
}, $data.memberInfo.is_member ? {
|
||||
m: common_assets._imports_5$1
|
||||
} : {
|
||||
n: common_assets._imports_6
|
||||
}, {
|
||||
o: common_vendor.f($data.privilegeList, (item, index, i0) => {
|
||||
return common_vendor.e({
|
||||
a: common_vendor.t(item),
|
||||
b: index == 0 || index == 1 || index == 2
|
||||
}, index == 0 || index == 1 || index == 2 ? {
|
||||
c: common_assets._imports_4$4
|
||||
c: common_assets._imports_7$2
|
||||
} : {}, {
|
||||
d: index == 3 || index == 4
|
||||
}, index == 3 || index == 4 ? common_vendor.e({
|
||||
@@ -48,15 +90,20 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
||||
}, index == 4 ? {} : {}) : {}, {
|
||||
g: index == 5 || index == 6
|
||||
}, index == 5 || index == 6 ? {
|
||||
h: common_assets._imports_5$4
|
||||
h: common_assets._imports_8$2
|
||||
} : {}, {
|
||||
i: index
|
||||
});
|
||||
}),
|
||||
g: common_assets._imports_5$4,
|
||||
h: common_vendor.s("margin-top:" + $data.navH + "px;"),
|
||||
i: common_vendor.o(($event) => $options.clickJoinVip())
|
||||
};
|
||||
p: common_assets._imports_8$2,
|
||||
q: common_vendor.n("privilegeList " + ($data.memberInfo.is_member ? "vip" : "")),
|
||||
r: common_vendor.s("margin-top:" + $data.navH + "px;")
|
||||
}) : {}, {
|
||||
s: $data.memberInfo
|
||||
}, $data.memberInfo ? {
|
||||
t: common_vendor.t($data.memberInfo.is_member ? "您已是年度VIP" : "立即加入年度VIP"),
|
||||
v: common_vendor.o(($event) => $options.clickJoinVip())
|
||||
} : {});
|
||||
}
|
||||
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render]]);
|
||||
wx.createPage(MiniProgramPage);
|
||||
|
||||
@@ -1 +1 @@
|
||||
<view><nav-bar wx:if="{{a}}" u-i="667ff406-0" bind:__l="__l" u-p="{{a}}"></nav-bar><image class="topBg absolute" src="{{b}}" mode="widthFix"></image><view class="vipC" style="{{h}}"><view class="vipInfoC relative"><image class="bg" src="{{c}}" mode="widthFix"></image><view class="infoC absolute"><view class="title">价值前沿</view><view class="tips">您还不是会员 加入尊享N项服务</view></view></view><view class="privilegeCompareC relative"><view class="titleC flexCenter"><image class="icon" src="{{d}}" mode="widthFix"></image><view class="title">特权对比</view><image class="icon" src="{{e}}" mode="widthFix"></image></view><view class="privilegeList"><view class="header flex"><view class="privilege item">专属特权</view><view class="item free">普通免费</view><view class="item vip">VIP会员</view></view><view class="list"><view wx:for="{{f}}" wx:for-item="item" wx:key="i" class="item flex"><view class="optionItem privilege flex">{{item.a}}</view><view class="optionItem free flexCenter"><block wx:if="{{item.b}}"><image class="notContain" src="{{item.c}}" mode="widthFix"></image></block><block wx:if="{{item.d}}"><block wx:if="{{item.e}}">限制查看数量</block><block wx:if="{{item.f}}">每日查看2只</block></block><block wx:if="{{item.g}}"><image class="contain" src="{{item.h}}" mode="widthFix"></image></block></view><view class="optionItem vip flexCenter"><image class="contain" src="{{g}}" mode="widthFix"></image></view></view></view></view></view></view><view class="joinVipC fixed" bindtap="{{i}}">立即加入年度VIP</view></view>
|
||||
<view><nav-bar wx:if="{{a}}" u-i="667ff406-0" bind:__l="__l" u-p="{{a}}"></nav-bar><image class="topBg absolute" src="{{b}}" mode="widthFix"></image><view wx:if="{{c}}" class="vipC" style="{{r}}"><view class="vipInfoC relative"><image wx:if="{{d}}" class="bg" src="{{e}}" mode="widthFix"></image><image wx:else class="bg" src="{{f}}" mode="widthFix"></image><view wx:if="{{g}}" class="infoC vip absolute"><view class="title">尊贵的VIP会员</view><view class="tips">会员有效期至:{{h}}</view></view><view wx:else class="infoC absolute"><view class="title">价值前沿</view><view class="tips">您还不是会员 加入尊享N项服务</view></view></view><view class="privilegeCompareC relative"><view class="titleC flexCenter"><image wx:if="{{i}}" class="icon" src="{{j}}" mode="widthFix"></image><image wx:else class="icon" src="{{k}}" mode="widthFix"></image><view class="title">特权对比</view><image wx:if="{{l}}" class="icon" src="{{m}}" mode="widthFix"></image><image wx:else class="icon" src="{{n}}" mode="widthFix"></image></view><view class="{{q}}"><view class="header flex"><view class="privilege item">专属特权</view><view class="item free">普通免费</view><view class="item vip">VIP会员</view></view><view class="list"><view wx:for="{{o}}" wx:for-item="item" wx:key="i" class="item flex"><view class="optionItem privilege flex">{{item.a}}</view><view class="optionItem free flexCenter"><block wx:if="{{item.b}}"><image class="notContain" src="{{item.c}}" mode="widthFix"></image></block><block wx:if="{{item.d}}"><block wx:if="{{item.e}}">限制查看数量</block><block wx:if="{{item.f}}">每日查看2只</block></block><block wx:if="{{item.g}}"><image class="contain" src="{{item.h}}" mode="widthFix"></image></block></view><view class="optionItem vip flexCenter"><image class="contain" src="{{p}}" mode="widthFix"></image></view></view></view></view></view></view><view wx:if="{{s}}" class="joinVipC fixed" bindtap="{{v}}">{{t}}</view></view>
|
||||
@@ -28,6 +28,12 @@
|
||||
font-weight: 500;
|
||||
color: #65758A;
|
||||
}
|
||||
.vipC .vipInfoC .infoC.vip .title {
|
||||
color: #AB3D1A;
|
||||
}
|
||||
.vipC .vipInfoC .infoC.vip .tips {
|
||||
color: #AB3D1A;
|
||||
}
|
||||
.vipC .privilegeCompareC {
|
||||
background-color: white;
|
||||
margin-top: -70rpx;
|
||||
@@ -100,6 +106,9 @@
|
||||
.vipC .privilegeCompareC .privilegeList .list .optionItem.vip {
|
||||
width: 160rpx;
|
||||
}
|
||||
.vipC .privilegeCompareC .privilegeList.vip {
|
||||
box-shadow: 0px 0px 9px 0px rgba(249, 115, 22, 0.4);
|
||||
}
|
||||
.joinVipC {
|
||||
background-color: #F97316;
|
||||
margin: 0 25rpx;
|
||||
|
||||
Reference in New Issue
Block a user