Showing
9 changed files
with
612 additions
and
21 deletions
@@ -17,6 +17,14 @@ exports.familyIndex = (req, res, next) => { | @@ -17,6 +17,14 @@ exports.familyIndex = (req, res, next) => { | ||
17 | }).catch(next); | 17 | }).catch(next); |
18 | }; | 18 | }; |
19 | 19 | ||
20 | +exports.familyVip = (req, res, next) => { | ||
21 | + // let uid = req.user.uid; | ||
22 | + | ||
23 | + req.ctx(family).familyVip().then(result => { | ||
24 | + res.json(result); | ||
25 | + }).catch(next); | ||
26 | +}; | ||
27 | + | ||
20 | exports.coinDetail = (req, res) => { | 28 | exports.coinDetail = (req, res) => { |
21 | let responseData = { | 29 | let responseData = { |
22 | module: 'home', | 30 | module: 'home', |
@@ -64,9 +64,9 @@ class familyModel extends global.yoho.BaseModel { | @@ -64,9 +64,9 @@ class familyModel extends global.yoho.BaseModel { | ||
64 | { | 64 | { |
65 | uid: null, | 65 | uid: null, |
66 | iconUrl: 'http://img12.static.yhbimg.com/article/2017/08/23/10/02412723632a13bd6ad1eef8fe580095a5.png?imageView/{mode}/w/{width}/h/{height}', | 66 | iconUrl: 'http://img12.static.yhbimg.com/article/2017/08/23/10/02412723632a13bd6ad1eef8fe580095a5.png?imageView/{mode}/w/{width}/h/{height}', |
67 | - sourceName: 'yoho', | 67 | + sourceName: 'yohobuy', |
68 | source: 1, | 68 | source: 1, |
69 | - login: false | 69 | + login: true |
70 | }, | 70 | }, |
71 | { | 71 | { |
72 | uid: null, | 72 | uid: null, |
@@ -126,6 +126,233 @@ class familyModel extends global.yoho.BaseModel { | @@ -126,6 +126,233 @@ class familyModel extends global.yoho.BaseModel { | ||
126 | return appList; | 126 | return appList; |
127 | } | 127 | } |
128 | 128 | ||
129 | + /** | ||
130 | + *查询各个体系成长等级信息及等级特权 | ||
131 | + */ | ||
132 | + _getVipInfo() { | ||
133 | + let result = { | ||
134 | + code: 200, | ||
135 | + data: { | ||
136 | + mars: { | ||
137 | + vipLevelList: [ | ||
138 | + { | ||
139 | + growthValue: 100, | ||
140 | + level: 0, | ||
141 | + levelImg: "http://img01.yohomars.com/mars/2017/01/24/d1f9cb68a1e7aae4a1a6c4eeca7b1b0e.png?imageView/{mode}/w/{width}/h/{height}", | ||
142 | + marsPointDiscount: 100 | ||
143 | + }, | ||
144 | + { | ||
145 | + growthValue: 400, | ||
146 | + level: 1, | ||
147 | + levelImg: "http://img01.yohomars.com/mars/2017/01/24/5336ef84190a715bd221fca50a9e9e3d.png?imageView/{mode}/w/{width}/h/{height}", | ||
148 | + marsPointDiscount: 100 | ||
149 | + }, | ||
150 | + { | ||
151 | + growthValue: 1000, | ||
152 | + level: 2, | ||
153 | + levelImg: "http://img01.yohomars.com/mars/2017/01/24/1027321fcaf5311ab21963f925ecb0dd.png?imageView/{mode}/w/{width}/h/{height}", | ||
154 | + marsPointDiscount: 95, | ||
155 | + privilege: "mars points 9.5折兑换" | ||
156 | + }, | ||
157 | + { | ||
158 | + growthValue: 2000, | ||
159 | + level: 3, | ||
160 | + levelImg: "http://img01.yohomars.com/mars/2017/01/24/e4512e2c5e78140170bf4967c4368645.png?imageView/{mode}/w/{width}/h/{height}", | ||
161 | + marsPointDiscount: 90, | ||
162 | + privilege: "mars points 9折兑换" | ||
163 | + }, | ||
164 | + { | ||
165 | + growthValue: 5000, | ||
166 | + level: 4, | ||
167 | + levelImg: "http://img01.yohomars.com/mars/2017/01/24/312d0b334370eb8a9711065d489451ca.png?imageView/{mode}/w/{width}/h/{height}", | ||
168 | + marsPointDiscount: 85, | ||
169 | + privilege: "mars points 8.5折兑换" | ||
170 | + }, | ||
171 | + { | ||
172 | + growthVaue: 10000, | ||
173 | + level: 5, | ||
174 | + levelImg: "http://img01.yohomars.com/mars/2017/01/24/148be1f69f64ebc1872c43b5b4b7e620.png?imageView/{mode}/w/{width}/h/{height}", | ||
175 | + marsPointDiscount: 80, | ||
176 | + privilege: "mars points 8折兑换" | ||
177 | + } | ||
178 | + ] | ||
179 | + }, | ||
180 | + yohobuy: { | ||
181 | + privilegeList: [ | ||
182 | + { | ||
183 | + description: "在原折扣基础上享受VIP折上折", | ||
184 | + id: 1, | ||
185 | + pic: "http://static.yohobuy.com/images/app/icon_2x_zhekou.png", | ||
186 | + title: "银卡会员购物9.5折" | ||
187 | + }, | ||
188 | + { | ||
189 | + description: "在原折扣基础上享受VIP折上折", | ||
190 | + id: 2, | ||
191 | + pic: "http://static.yohobuy.com/images/app/icon_2x_zhekou.png", | ||
192 | + title: "金卡会员购物9.0折" | ||
193 | + }, | ||
194 | + { | ||
195 | + description: "在原折扣基础上享受VIP折上折", | ||
196 | + id: 3, | ||
197 | + pic: "http://static.yohobuy.com/images/app/icon_2x_zhekou.png", | ||
198 | + title: "白金卡会员购物8.8折" | ||
199 | + }, | ||
200 | + { | ||
201 | + description: "年度级的sale促销活动中,VIP会员可以享受优先购买权", | ||
202 | + id: 4, | ||
203 | + pic: "http://static.yohobuy.com/images/app/icon_2x_niandu.png", | ||
204 | + title: "年度活动优惠" | ||
205 | + }, | ||
206 | + { | ||
207 | + description: "白金卡会员的订单将采用最快速度进行免费配送,金卡会员的订单免费配送", | ||
208 | + id: 5, | ||
209 | + pic: "http://static.yohobuy.com/images/app/icon_2x_kssd.png", | ||
210 | + title: "快速送达" | ||
211 | + }, | ||
212 | + { | ||
213 | + description: "浏览《YOHO!潮流志》、《YOHO!GIRL》电子版,最新最权威的潮流资讯尽在掌握!", | ||
214 | + id: 6, | ||
215 | + pic: "http://static.yohobuy.com/images/app/icon_2x_zzzy.png", | ||
216 | + title: "电子杂志赠阅" | ||
217 | + }, | ||
218 | + { | ||
219 | + description: "赠送生日优惠券", | ||
220 | + id: 8, | ||
221 | + pic: "http://static.yohobuy.com/images/app/icon_2x_sryh.png", | ||
222 | + title: "生日特惠" | ||
223 | + }, | ||
224 | + { | ||
225 | + description: "获取大量潮流新品及优惠活动的信息", | ||
226 | + id: 9, | ||
227 | + pic: "http://static.yohobuy.com/images/app/icon_2x_yhxx.png", | ||
228 | + title: "优惠信息" | ||
229 | + }, | ||
230 | + { | ||
231 | + description: "参加\"VIP会员限定\"活动", | ||
232 | + id: 10, | ||
233 | + pic: "http://static.yohobuy.com/images/app/icon_2x_vip.png", | ||
234 | + title: "VIP活动优惠" | ||
235 | + } | ||
236 | + ], | ||
237 | + vipLevelLis: [ | ||
238 | + { | ||
239 | + growthValue: 0, | ||
240 | + level: 0, | ||
241 | + name: "普通会员", | ||
242 | + privilege: "" | ||
243 | + }, | ||
244 | + { | ||
245 | + growthValue: 600, | ||
246 | + level: 1, | ||
247 | + name: "银卡会员", | ||
248 | + privilege: "1,4,10,6,8,9" | ||
249 | + }, | ||
250 | + { | ||
251 | + growthValue: 2000, | ||
252 | + level: 2, | ||
253 | + name: "金卡会员", | ||
254 | + privilege: "2,4,10,5,6,8,9" | ||
255 | + }, | ||
256 | + { | ||
257 | + growthValue: 5000, | ||
258 | + level: 3, | ||
259 | + name: "白金会员", | ||
260 | + privilege: "3,4,10,5,6,8,9" | ||
261 | + } | ||
262 | + ] | ||
263 | + } | ||
264 | + } | ||
265 | + }; | ||
266 | + | ||
267 | + return result.data; | ||
268 | + } | ||
269 | + | ||
270 | + /** | ||
271 | + *查询当前用户各个体系成长等级信息及等级特权 | ||
272 | + */ | ||
273 | + _getUserVipInfo() { | ||
274 | + let result = { | ||
275 | + data: { | ||
276 | + mars: { | ||
277 | + growthValue: 2000, | ||
278 | + level: 4, | ||
279 | + nextLevel: 5, | ||
280 | + privilege: "mars points 8.5折兑换", | ||
281 | + valueToNextLevel: 3000 | ||
282 | + }, | ||
283 | + yohobuy: { | ||
284 | + growthValue: 1500, | ||
285 | + level: 1, | ||
286 | + name: "银卡会员", | ||
287 | + nextLevel: 2, | ||
288 | + valueToNextLevel: 500, | ||
289 | + privilege: [ | ||
290 | + { | ||
291 | + description: "在原折扣基础上享受VIP折上折", | ||
292 | + id: 1, | ||
293 | + pic: "http://static.yohobuy.com/images/app/icon_2x_zhekou.png", | ||
294 | + title: "银卡会员购物9.5折" | ||
295 | + }, | ||
296 | + { | ||
297 | + description: "年度级的sale促销活动中,VIP会员可以享受优先购买权", | ||
298 | + id: 4, | ||
299 | + pic: "http://static.yohobuy.com/images/app/icon_2x_niandu.png", | ||
300 | + title: "年度活动优惠" | ||
301 | + }, | ||
302 | + { | ||
303 | + description: "浏览《YOHO!潮流志》、《YOHO!GIRL》电子版,最新最权威的潮流资讯尽在掌握!", | ||
304 | + id: 6, | ||
305 | + pic: "http://static.yohobuy.com/images/app/icon_2x_zzzy.png", | ||
306 | + title: "电子杂志赠阅" | ||
307 | + }, | ||
308 | + { | ||
309 | + description: "赠送生日优惠券", | ||
310 | + id: 8, | ||
311 | + pic: "http://static.yohobuy.com/images/app/icon_2x_sryh.png", | ||
312 | + title: "生日特惠" | ||
313 | + }, | ||
314 | + { | ||
315 | + description: "获取大量潮流新品及优惠活动的信息", | ||
316 | + id: 9, | ||
317 | + pic: "http://static.yohobuy.com/images/app/icon_2x_yhxx.png", | ||
318 | + title: "优惠信息" | ||
319 | + }, | ||
320 | + { | ||
321 | + description: "参加\"VIP会员限定\"活动", | ||
322 | + id: 10, | ||
323 | + pic: "http://static.yohobuy.com/images/app/icon_2x_vip.png", | ||
324 | + title: "VIP活动优惠" | ||
325 | + } | ||
326 | + ] | ||
327 | + } | ||
328 | + } | ||
329 | + }; | ||
330 | + | ||
331 | + return result.data; | ||
332 | + } | ||
333 | + | ||
334 | + /** | ||
335 | + *各个app的会员信息 | ||
336 | + */ | ||
337 | + familyVip() { | ||
338 | + return Promise.all([ | ||
339 | + this._getVipInfo(), | ||
340 | + this._getUserVipInfo() | ||
341 | + ]).then((result) => { | ||
342 | + _.forEach(result[1], function(val, key) { | ||
343 | + _.forEach(result[0], function(data, index) { | ||
344 | + if (index === key) { | ||
345 | + val = _.assign(val, { | ||
346 | + vipLevelLis: data.vipLevelLis | ||
347 | + }); | ||
348 | + } | ||
349 | + }); | ||
350 | + }); | ||
351 | + | ||
352 | + return result[1]; | ||
353 | + }); | ||
354 | + } | ||
355 | + | ||
129 | familyIndex(uid) { | 356 | familyIndex(uid) { |
130 | return Promise.all([ | 357 | return Promise.all([ |
131 | this._userData(uid), | 358 | this._userData(uid), |
@@ -151,6 +378,10 @@ class familyModel extends global.yoho.BaseModel { | @@ -151,6 +378,10 @@ class familyModel extends global.yoho.BaseModel { | ||
151 | familyIndexData.appList = result[2]; | 378 | familyIndexData.appList = result[2]; |
152 | } | 379 | } |
153 | 380 | ||
381 | + // if (result[3]) { | ||
382 | + // familyIndexData.vipDetail = result[3]; | ||
383 | + // } | ||
384 | + | ||
154 | return familyIndexData; | 385 | return familyIndexData; |
155 | }); | 386 | }); |
156 | } | 387 | } |
@@ -178,6 +178,7 @@ router.post('/return/exchange/cancel-apply', auth, exchange.cancelApply); // AJA | @@ -178,6 +178,7 @@ router.post('/return/exchange/cancel-apply', auth, exchange.cancelApply); // AJA | ||
178 | router.get('/tide-command', auth, tideCommand.tideCommand); // 设置潮流口令 | 178 | router.get('/tide-command', auth, tideCommand.tideCommand); // 设置潮流口令 |
179 | 179 | ||
180 | router.get('/family', auth, family.familyIndex); // family首页 | 180 | router.get('/family', auth, family.familyIndex); // family首页 |
181 | +router.get('/family/vipDetailData', auth, family.familyVip); // 获取VIP信息 | ||
181 | router.get('/family/coinDetail', auth, family.coinDetail); // 积分详情页 | 182 | router.get('/family/coinDetail', auth, family.coinDetail); // 积分详情页 |
182 | router.get('/family/coinDetail/getCoinData', auth, family.getCoinData); // 筛选积分详情 | 183 | router.get('/family/coinDetail/getCoinData', auth, family.getCoinData); // 筛选积分详情 |
183 | router.get('/family/userInfo', auth, family.userInfo); // family个人信息页 | 184 | router.get('/family/userInfo', auth, family.userInfo); // family个人信息页 |
@@ -37,7 +37,7 @@ | @@ -37,7 +37,7 @@ | ||
37 | <div class="title">会员等级及权益</div> | 37 | <div class="title">会员等级及权益</div> |
38 | <div class="grade-content"> | 38 | <div class="grade-content"> |
39 | {{# appList}} | 39 | {{# appList}} |
40 | - <div class="content-item" data-login="{{login}}"> | 40 | + <div class="content-item" data-login="{{login}}" data-name="{{sourceName}}"> |
41 | <img class="item-tag" src="{{image iconUrl 140 140}}"> | 41 | <img class="item-tag" src="{{image iconUrl 140 140}}"> |
42 | <span class="name">{{sourceName}}</span> | 42 | <span class="name">{{sourceName}}</span> |
43 | <span class="level">黄金</span> | 43 | <span class="level">黄金</span> |
@@ -60,16 +60,6 @@ | @@ -60,16 +60,6 @@ | ||
60 | </div> | 60 | </div> |
61 | </div> | 61 | </div> |
62 | </div> | 62 | </div> |
63 | + <div class="dia-c"></div> | ||
63 | {{/ familyIndexData}} | 64 | {{/ familyIndexData}} |
64 | - | ||
65 | - <div class="vip-detail"> | ||
66 | - <div class="back"></div> | ||
67 | - <div class="detail-content"> | ||
68 | - <div class="banner"> | ||
69 | - </div> | ||
70 | - <div class="main"> | ||
71 | - | ||
72 | - </div> | ||
73 | - </div> | ||
74 | - </div> | ||
75 | </div> | 65 | </div> |
public/hbs/home/vip-detail.hbs
0 → 100644
1 | +<div class="vip-detail"> | ||
2 | + <div class="close"></div> | ||
3 | + <div class="back"></div> | ||
4 | + <div class="detail-content"> | ||
5 | + <div class="banner"> | ||
6 | + </div> | ||
7 | + <div class="main"> | ||
8 | + <div class="user-info clearfix{{#if noUid}} hide{{/if}}"> | ||
9 | + <div class="base clearfix"> | ||
10 | + <div class="pic"{{#if headIco}} style="background-image:url({{image headIco 125 125}})"{{/if}}> | ||
11 | + <div class="level-pic vip-{{level}}"></div> | ||
12 | + </div> | ||
13 | + <div class="intro"> | ||
14 | + <div class="name"><span></span>您好!</div> | ||
15 | + <div class="level"> | ||
16 | + <span class="now">我的成长值:<span class="val">{{growthValue}}</span></span> | ||
17 | + {{#if valueToNextLevel}} | ||
18 | + <span class="next">下次升级还需:<span class="val">{{valueToNextLevel}}</span></span> | ||
19 | + {{/if}} | ||
20 | + </div> | ||
21 | + </div> | ||
22 | + </div> | ||
23 | + <div class="level-process yoho-level clearfix"> | ||
24 | + <div class="line-c"> | ||
25 | + <div class="line"{{#if percent}} style="width:{{percent}}%"{{/if}}></div> | ||
26 | + <div class="point"> | ||
27 | + {{# vipLevelLis}} | ||
28 | + <div class="point-item"> | ||
29 | + <div class="level-text"> | ||
30 | + <p>{{name}}</p> | ||
31 | + <p>{{growthValue}}</p> | ||
32 | + </div> | ||
33 | + </div> | ||
34 | + {{/ vipLevelLis}} | ||
35 | + </div> | ||
36 | + </div> | ||
37 | + </div> | ||
38 | + </div> | ||
39 | + | ||
40 | + <div class="privilege-list"> | ||
41 | + <div class="privilege-title"> | ||
42 | + <b></b> | ||
43 | + 当前可享受特权 | ||
44 | + <a class="more">更多</a> | ||
45 | + </div> | ||
46 | + {{# privilege}} | ||
47 | + <a class="privilege-item"> | ||
48 | + <img class="icon" src="{{pic}}"> | ||
49 | + <p> | ||
50 | + {{title}} | ||
51 | + <span>{{description}}</span> | ||
52 | + </p> | ||
53 | + </a> | ||
54 | + {{/ privilege}} | ||
55 | + {{# privilegeCro}} | ||
56 | + <div class="level-item"> | ||
57 | + <img class="item-ico" src="{{image iconUrl 125 125}}"> | ||
58 | + <span class="le-name">{{sourceName}}发的我客来福侧那我可掉入了</span> | ||
59 | + <span class="state">已开启</span> | ||
60 | + </div> | ||
61 | + {{/ privilegeCro}} | ||
62 | + </div> | ||
63 | + </div> | ||
64 | + </div> | ||
65 | +</div> |
public/img/home/family/close.png
0 → 100644

4.13 KB
public/img/home/family/point.png
0 → 100644

1.63 KB
@@ -4,6 +4,7 @@ import Page from 'yoho-page'; | @@ -4,6 +4,7 @@ import Page from 'yoho-page'; | ||
4 | import tip from 'plugin/tip'; | 4 | import tip from 'plugin/tip'; |
5 | import yoho from 'yoho-app'; | 5 | import yoho from 'yoho-app'; |
6 | import integral from 'home/integral-paradise.hbs'; | 6 | import integral from 'home/integral-paradise.hbs'; |
7 | +import vipDetailInfo from 'home/vip-detail.hbs'; | ||
7 | 8 | ||
8 | const echarts = require('echarts/lib/echarts'); | 9 | const echarts = require('echarts/lib/echarts'); |
9 | 10 | ||
@@ -14,6 +15,7 @@ class FamilyIndex extends Page { | @@ -14,6 +15,7 @@ class FamilyIndex extends Page { | ||
14 | super(); | 15 | super(); |
15 | 16 | ||
16 | this.selector = { | 17 | this.selector = { |
18 | + $diaC: $('.dia-c'), | ||
17 | $userAvatar: $('.user-avatar'), | 19 | $userAvatar: $('.user-avatar'), |
18 | $codeSet: $('.code-set'), | 20 | $codeSet: $('.code-set'), |
19 | $invition: $('.invition'), | 21 | $invition: $('.invition'), |
@@ -21,13 +23,19 @@ class FamilyIndex extends Page { | @@ -21,13 +23,19 @@ class FamilyIndex extends Page { | ||
21 | $textarea: $('textarea'), | 23 | $textarea: $('textarea'), |
22 | integralCh: echarts.init(document.getElementById('charts')), | 24 | integralCh: echarts.init(document.getElementById('charts')), |
23 | chartWidth: $('.charts').width(), | 25 | chartWidth: $('.charts').width(), |
24 | - $integralContent: $('.integral-content') | 26 | + $integralContent: $('.integral-content'), |
27 | + $contentItem: $('.content-item'), | ||
28 | + $close: $('.close'), | ||
29 | + $userName: $('.user-name') | ||
25 | }; | 30 | }; |
26 | 31 | ||
27 | this.view = { | 32 | this.view = { |
28 | - integral | 33 | + integral, |
34 | + vipDetailInfo | ||
29 | }; | 35 | }; |
30 | 36 | ||
37 | + this.vipInfo; | ||
38 | + | ||
31 | this.init(); | 39 | this.init(); |
32 | } | 40 | } |
33 | 41 | ||
@@ -35,12 +43,15 @@ class FamilyIndex extends Page { | @@ -35,12 +43,15 @@ class FamilyIndex extends Page { | ||
35 | this.headIco(); | 43 | this.headIco(); |
36 | this.integralCharts(); | 44 | this.integralCharts(); |
37 | this.bindEvents(); | 45 | this.bindEvents(); |
46 | + this.viewVipInfo(); | ||
38 | } | 47 | } |
39 | 48 | ||
40 | bindEvents() { | 49 | bindEvents() { |
41 | this.selector.$codeSet.on('click', this.setTrendPop.bind(this)); | 50 | this.selector.$codeSet.on('click', this.setTrendPop.bind(this)); |
42 | this.selector.$textarea.on('blur', this.saveTrendWord.bind(this)); | 51 | this.selector.$textarea.on('blur', this.saveTrendWord.bind(this)); |
43 | this.selector.integralCh.on('click', this.jump.bind(this)); | 52 | this.selector.integralCh.on('click', this.jump.bind(this)); |
53 | + this.selector.$contentItem.on('click', this.showVipInfo.bind(this)); | ||
54 | + this.selector.$diaC.on('click', this.selector.$close, this.hideVipInfo.bind(this)); | ||
44 | } | 55 | } |
45 | 56 | ||
46 | // 头像 | 57 | // 头像 |
@@ -85,6 +96,18 @@ class FamilyIndex extends Page { | @@ -85,6 +96,18 @@ class FamilyIndex extends Page { | ||
85 | }); | 96 | }); |
86 | } | 97 | } |
87 | 98 | ||
99 | + // 查看VIP信息 | ||
100 | + viewVipInfo() { | ||
101 | + this.ajax({ | ||
102 | + type: 'GET', | ||
103 | + url: location.protocol + '//m.yohobuy.com/home/family/vipDetailData' | ||
104 | + }).then(result => { | ||
105 | + this.vipInfo = result; | ||
106 | + }).catch(() => { | ||
107 | + tip.show('服务异常,请稍后重试'); | ||
108 | + }); | ||
109 | + } | ||
110 | + | ||
88 | // 设置潮流口令 | 111 | // 设置潮流口令 |
89 | setTrendPop() { | 112 | setTrendPop() { |
90 | this.selector.$invition.hide(); | 113 | this.selector.$invition.hide(); |
@@ -121,6 +144,36 @@ class FamilyIndex extends Page { | @@ -121,6 +144,36 @@ class FamilyIndex extends Page { | ||
121 | jump(params) { | 144 | jump(params) { |
122 | yoho.goH5(`${location.protocol}//m.yohobuy.com/home/family/coinDetail?plateType=${params.data.plateType}`); | 145 | yoho.goH5(`${location.protocol}//m.yohobuy.com/home/family/coinDetail?plateType=${params.data.plateType}`); |
123 | } | 146 | } |
147 | + | ||
148 | + // 点击APP图标显示会员信息 | ||
149 | + showVipInfo(e) { | ||
150 | + let $this = $(e.currentTarget); | ||
151 | + let appType = $this.data('name').toLowerCase(); | ||
152 | + let isLogin = $this.data('login'); | ||
153 | + | ||
154 | + if (isLogin) { | ||
155 | + if (this.vipInfo[appType]) { | ||
156 | + this.selector.$diaC.append(this.view.vipDetailInfo(this.vipInfo[appType])); | ||
157 | + } else { | ||
158 | + this.viewVipInfo(); | ||
159 | + | ||
160 | + this.selector.$diaC.append(this.view.vipDetailInfo(this.vipInfo[appType])); | ||
161 | + } | ||
162 | + | ||
163 | + if (this.selector.$userAvatar.data('avatar')) { | ||
164 | + $('.base .pic').css('background-image', 'url(' + this.selector.$userAvatar.data('avatar') + ')'); | ||
165 | + } | ||
166 | + | ||
167 | + if (this.selector.$userName.text() !== '') { | ||
168 | + $('.intro .name span').text($('.user-name').text() + ','); | ||
169 | + } | ||
170 | + } | ||
171 | + } | ||
172 | + | ||
173 | + // 点击关闭会员信息弹框 | ||
174 | + hideVipInfo() { | ||
175 | + $('.vip-detail').remove(); | ||
176 | + } | ||
124 | } | 177 | } |
125 | 178 | ||
126 | $(() => { | 179 | $(() => { |
@@ -199,11 +199,6 @@ | @@ -199,11 +199,6 @@ | ||
199 | overflow: hidden; | 199 | overflow: hidden; |
200 | position: relative; | 200 | position: relative; |
201 | 201 | ||
202 | - canvas { | ||
203 | - width: 100% !important; | ||
204 | - height: 100% !important; | ||
205 | - } | ||
206 | - | ||
207 | .charts { | 202 | .charts { |
208 | float: left; | 203 | float: left; |
209 | } | 204 | } |
@@ -288,6 +283,18 @@ | @@ -288,6 +283,18 @@ | ||
288 | height: 100%; | 283 | height: 100%; |
289 | z-index: 5; | 284 | z-index: 5; |
290 | 285 | ||
286 | + .close { | ||
287 | + height: 50px; | ||
288 | + width: 50px; | ||
289 | + background-image: resolve("home/family/close.png"); | ||
290 | + background-size: 100%; | ||
291 | + background-repeat: no-repeat; | ||
292 | + position: relative; | ||
293 | + top: 150px; | ||
294 | + right: -668px; | ||
295 | + z-index: 6; | ||
296 | + } | ||
297 | + | ||
291 | .back { | 298 | .back { |
292 | width: 100%; | 299 | width: 100%; |
293 | height: 100%; | 300 | height: 100%; |
@@ -309,11 +316,247 @@ | @@ -309,11 +316,247 @@ | ||
309 | left: 50%; | 316 | left: 50%; |
310 | margin-top: 180px; | 317 | margin-top: 180px; |
311 | margin-left: -315px; | 318 | margin-left: -315px; |
319 | + height: 950px; | ||
320 | + overflow-y: scroll; | ||
321 | + overflow-x: hidden; | ||
322 | + border-bottom-left-radius: 10px; | ||
323 | + border-bottom-right-radius: 10px; | ||
312 | } | 324 | } |
313 | 325 | ||
314 | .banner { | 326 | .banner { |
315 | width: 100%; | 327 | width: 100%; |
316 | height: 200px; | 328 | height: 200px; |
317 | } | 329 | } |
330 | + | ||
331 | + .user-info { | ||
332 | + padding: 34px 40px 115px; | ||
333 | + background-color: #fff; | ||
334 | + border-bottom: solid 1px #e5e5e5; | ||
335 | + | ||
336 | + .base { | ||
337 | + .pic { | ||
338 | + width: 120px; | ||
339 | + height: 120px; | ||
340 | + float: left; | ||
341 | + background-size: 100% 100%; | ||
342 | + background-position: center; | ||
343 | + border-radius: 50%; | ||
344 | + border: 1px solid #eee; | ||
345 | + position: relative; | ||
346 | + background-image: resolve("home/index/user-avatar.png"); | ||
347 | + | ||
348 | + .level-pic { | ||
349 | + width: 82px; | ||
350 | + height: 36px; | ||
351 | + background-size: 100% 100%; | ||
352 | + position: absolute; | ||
353 | + bottom: -18px; | ||
354 | + left: 50%; | ||
355 | + margin-left: -41px; | ||
356 | + } | ||
357 | + | ||
358 | + .vip-3 { | ||
359 | + background-image: url("/home/grade-new/vip-3.png"); | ||
360 | + } | ||
361 | + | ||
362 | + .vip-2 { | ||
363 | + background-image: url("/home/grade-new/vip-2.png"); | ||
364 | + } | ||
365 | + | ||
366 | + .vip-1 { | ||
367 | + background-image: url("/home/grade-new/vip-1.png"); | ||
368 | + } | ||
369 | + } | ||
370 | + | ||
371 | + .intro { | ||
372 | + padding: 0 0 15px 30px; | ||
373 | + float: left; | ||
374 | + width: 400px; | ||
375 | + } | ||
376 | + | ||
377 | + .name { | ||
378 | + color: #000; | ||
379 | + font-size: 30px; | ||
380 | + line-height: 60px; | ||
381 | + } | ||
382 | + | ||
383 | + .level { | ||
384 | + font-size: 24px; | ||
385 | + line-height: 32px; | ||
386 | + color: #000; | ||
387 | + } | ||
388 | + | ||
389 | + .now { | ||
390 | + float: left; | ||
391 | + } | ||
392 | + | ||
393 | + .next { | ||
394 | + float: left; | ||
395 | + } | ||
396 | + } | ||
397 | + | ||
398 | + .level-process { | ||
399 | + padding: 0 10px; | ||
400 | + | ||
401 | + .line-c { | ||
402 | + width: 530px; | ||
403 | + height: 4px; | ||
404 | + background-color: #f0f0f0; | ||
405 | + margin: 50px auto 0; | ||
406 | + position: relative; | ||
407 | + } | ||
408 | + | ||
409 | + .line { | ||
410 | + width: 470px; | ||
411 | + height: 100%; | ||
412 | + max-width: 100%; | ||
413 | + background-color: #444; | ||
414 | + } | ||
415 | + | ||
416 | + .point { | ||
417 | + width: 490px; | ||
418 | + position: absolute; | ||
419 | + top: -9px; | ||
420 | + left: -2px; | ||
421 | + } | ||
422 | + | ||
423 | + .point-item { | ||
424 | + width: 23px; | ||
425 | + height: 23px; | ||
426 | + background-image: resolve("home/family/point.png"); | ||
427 | + background-size: 100%; | ||
428 | + background-repeat: no-repeat; | ||
429 | + float: left; | ||
430 | + position: relative; | ||
431 | + } | ||
432 | + | ||
433 | + .point-item:last-child { | ||
434 | + margin-right: 0; | ||
435 | + } | ||
436 | + | ||
437 | + .level-text { | ||
438 | + width: 120px; | ||
439 | + position: absolute; | ||
440 | + top: 29px; | ||
441 | + left: 50%; | ||
442 | + margin-left: -60px; | ||
443 | + font-size: 24px; | ||
444 | + text-align: center; | ||
445 | + line-height: 40px; | ||
446 | + } | ||
447 | + } | ||
448 | + | ||
449 | + .yoho-level { | ||
450 | + padding: 0 30px; | ||
451 | + | ||
452 | + .line-c { | ||
453 | + width: 490px; | ||
454 | + } | ||
455 | + | ||
456 | + .point-item { | ||
457 | + margin-right: 132px; | ||
458 | + } | ||
459 | + } | ||
460 | + } | ||
461 | + | ||
462 | + .privilege-list { | ||
463 | + .privilege-title { | ||
464 | + height: 70px; | ||
465 | + line-height: 70px; | ||
466 | + font-size: 24px; | ||
467 | + border-bottom: 1px solid #e5e5e5; | ||
468 | + display: inline-block; | ||
469 | + width: 100%; | ||
470 | + color: #000; | ||
471 | + padding-left: 40px; | ||
472 | + | ||
473 | + b { | ||
474 | + display: block; | ||
475 | + width: 10px; | ||
476 | + height: 10px; | ||
477 | + background-color: #000; | ||
478 | + float: left; | ||
479 | + margin-top: 30px; | ||
480 | + margin-right: 10px; | ||
481 | + } | ||
482 | + | ||
483 | + .more { | ||
484 | + float: right; | ||
485 | + margin-right: 47px; | ||
486 | + } | ||
487 | + } | ||
488 | + | ||
489 | + .icon { | ||
490 | + float: left; | ||
491 | + display: block; | ||
492 | + width: 1.75rem; | ||
493 | + height: 1.75rem; | ||
494 | + } | ||
495 | + | ||
496 | + .privilege-item { | ||
497 | + width: 690px; | ||
498 | + clear: both; | ||
499 | + float: left; | ||
500 | + padding: 25px 0; | ||
501 | + border-bottom: solid 1px #e5e5e5; | ||
502 | + position: relative; | ||
503 | + margin-left: 40px; | ||
504 | + | ||
505 | + &:last-child { | ||
506 | + border-bottom: 0; | ||
507 | + } | ||
508 | + | ||
509 | + .iconfont { | ||
510 | + float: right; | ||
511 | + line-height: 70px; | ||
512 | + position: absolute; | ||
513 | + top: 50%; | ||
514 | + transform: translate(-50%, -50%); | ||
515 | + right: -10px; | ||
516 | + } | ||
517 | + } | ||
518 | + | ||
519 | + p { | ||
520 | + font-size: 28px; | ||
521 | + margin-left: 30px; | ||
522 | + min-height: 70px; | ||
523 | + width: 480px; | ||
524 | + float: left; | ||
525 | + } | ||
526 | + | ||
527 | + span { | ||
528 | + display: block; | ||
529 | + color: #b0b0b0; | ||
530 | + font-size: 22px; | ||
531 | + } | ||
532 | + | ||
533 | + .level-item { | ||
534 | + width: 210px; | ||
535 | + text-align: center; | ||
536 | + float: left; | ||
537 | + margin-bottom: 50px; | ||
538 | + | ||
539 | + .item-ico { | ||
540 | + width: 125px; | ||
541 | + height: 125px; | ||
542 | + border-radius: 50%; | ||
543 | + overflow: hidden; | ||
544 | + margin-top: 30px; | ||
545 | + margin-bottom: 20px; | ||
546 | + } | ||
547 | + | ||
548 | + .le-name { | ||
549 | + font-size: 28px; | ||
550 | + line-height: 36px; | ||
551 | + color: #000; | ||
552 | + } | ||
553 | + | ||
554 | + .state { | ||
555 | + font-size: 24px; | ||
556 | + color: #b0b0b0; | ||
557 | + margin-top: 10px; | ||
558 | + } | ||
559 | + } | ||
560 | + } | ||
318 | } | 561 | } |
319 | } | 562 | } |
-
Please register or login to post a comment