Authored by zhangxiaoru

添加头部

... ... @@ -366,7 +366,6 @@ exports.getGrade = (uid, channel) => {
obj = _.assign(obj, {
costOfThisYear: result[0].data.current_year_cost,
sumCost: result[0].data.current_total_cost,
allUrl: helpers.urlFormat('/me/privilege'),
costGap: upg
});
... ...
<div class="vip-privilege-page yoho-page">
<div class="blk-header-wrap">
<div class="blk-header">
<div class="blk-header-left">
<i class="icon icon-back go-back-btn"></i>
</div>
<div class="blk-header-main">
<span class="blk-header-title">VIP特权</span>
</div>
</div>
<ul class="privilege-list">
{{#each privilege}}
<li>
... ...
const yoho = require('yoho');
const $ = require('jquery');
$('.go-back-btn').click(function() {
yoho.goBack({}, function() {}, function() {});
})
... ...
.vip-grade-page,
.vip-privilege-page {
.blk-header {
box-sizing: content-box;
position: fixed;
top: 0;
right: 0;
left: 0;
z-index: 210;
padding: 20px 34px;
height: 70px;
max-width: 750px;
margin-left: auto;
margin-right: auto;
line-height: 70px;
font-size: 48px;
background-color: #fff;
border-bottom: 1px solid #eee;
color: #000;
.icon,
.blk-header-title {
vertical-align: middle;
}
.blk-header-right {
margin-right: -32px;
}
.icon {
min-width: 110px;
min-height: 110px;
line-height: 110px;
margin-top: -20px;
margin-left: -32px;
text-indent: 32px;
display: inline-block;
}
.go-back-btn {
&:hover {
background: #ccc;
opacity: 0.5;
}
}
}
.blk-header-left {
float: left;
font-size: 42px;
}
.blk-header-main {
display: block;
text-align: center;
margin-left: auto;
margin-right: auto;
font-size: 42px;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
position: absolute;
left: 0;
right: 0;
z-index: -1;
}
}
.vip-grade-page {
background: #f0f0f0;
padding-bottom: 30px;
... ... @@ -11,7 +79,7 @@
}
.basic-info {
padding-top: 30px;
padding-top: 130px;
padding-bottom: 25px;
p {
... ... @@ -180,7 +248,7 @@
}
.vip-privilege-page {
padding: 0 20px;
padding: 120px 20px 0 20px;
}
.privilege-list {
... ...
<template>
<div class="blk-header-wrap">
<div class="blk-header">
<div class="blk-header-left">
<i class="icon icon-back go-back-btn" @click="goBack"></i>
</div>
<div class="blk-header-main">
<span class="blk-header-title">会员等级</span>
</div>
</div>
</div>
<div class="basic-info block" v-if="vipGrade.vip3">
<p>
<span class="user-name">{{vipGrade.name}}</span>
... ... @@ -108,7 +118,7 @@
</ul>
</div>
<a class="all-privilege block tap-hightlight" href="{{vipGrade.allUrl}}">
<a class="all-privilege block tap-hightlight" href="/me/privilege">
查看全部VIP特权
<span class="icon icon-right"></span>
</a>
... ... @@ -131,6 +141,9 @@
}).then(result => {
this.vipGrade = result || {};
});
},
goBack() {
yoho.goBack({}, function() {}, function() {});
}
},
ready() {
... ...