| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281 |
- <template>
- <view>
- <customNav :shownav="true" :title="$t('index.huiyuanzhx')" titledetl=""></customNav>
- <view class="">
- <image class="imagV" src="/static/defimages/huiyuanxc.png" mode="widthFix"></image>
- </view>
- <view class="actBTct">
- <view class="actBTV" >
- <view class="blockView" v-for="(item,index) in vipList" @click="xuangou(item.id)">
- <view class="notecontent">
- <text class="titleact">{{item.name}}</text>
- <text class="noteact">${{item.price}}</text>
- </view>
-
- </view>
- </view>
- </view>
- <view class="huiyuanqyct">
- <text class="notev">{{$t('huiy.goumjswty')}}</text>
- <image class="huiyuanqy" src="/static/defimages/huiyuanqy.png" mode="heightFix"></image>
- </view>
- <view class="keywordLct">
- <view class="hyqyct">
- <text class="titlefl">2张平台券</text>
- <view class="qyblockView">
- <text class="yhqje">$5</text>
- <view class="shuline"></view>
- <view class="notecontent">
- <text class="titlev">VIP会员权益 $5优惠券</text>
- <text class="notev">满$20可用</text>
- </view>
- <text class="zhangshu">X 2 张</text>
- </view>
- </view>
- </view>
- <view class="keywordLct">
- <view class="hyqyct">
- <text class="titlefl">10张运费券</text>
- <view class="qyblockView">
- <text class="yhqje">$10</text>
- <view class="shuline"></view>
- <view class="notecontent">
- <text class="titlev">VIP会员权益 $10运费抵扣券</text>
- <text class="notev">满$50可用</text>
- </view>
- <text class="zhangshu">X 5 张</text>
- </view>
- <view class="qyblockView">
- <text class="yhqje">$5</text>
- <view class="shuline"></view>
- <view class="notecontent">
- <text class="titlev">VIP会员权益 $5运费抵扣券</text>
- <text class="notev">满$30可用</text>
- </view>
- <text class="zhangshu">X 5 张</text>
- </view>
- </view>
- </view>
- <view class="keywordLct">
- <view class="hyqyct">
- <text class="titlefl">5张商家联盟券</text>
- <view class="qyblockView">
- <text class="yhqje">$20</text>
- <view class="shuline"></view>
- <view class="notecontent">
- <text class="titlev">VIP会员权益 $20优惠券</text>
- <text class="notev">满$100可用</text>
- </view>
- <text class="zhangshu">X 5 张</text>
- </view>
- </view>
- </view>
- </view>
- </template>
- <script>
- import api from "@/pages/api/api.js"
- export default {
- data() {
- return {
- vipList:[],
- userInfo:[]
- }
- },
- onShow() {
- this.getviplist();
- // var temp = uni.getStorageSync('userInfo');
- // this.userInfo = JSON.parse(temp);
- },
- methods: {
- xuangou(id){
-
- var token = uni.getStorageSync("token");
- console.log('2222',token)
- if(token == '' || token == undefined || token == null){
- uni.navigateTo({
- url:'/pages/UserCenter/LoginView'
- })
- return;
- }
-
- uni.showModal({
- title: '提示',
- content: '选择支付方式并支付,待完善?',
- success: function (res) {
- }
- })
- return;
- this.adduservip(id);
- },
- getviplist(){
- api('getviplist',{
- },r=>{
- this.vipList = r.data.data;
- },failc=>{
- //console.log('getadvertis----',failc)
- })
- },
- async adduservip(id){
- api('adduservip',{
- id:id
- },r=>{
- console.log(r)
- },failc=>{
- //console.log('getadvertis----',failc)
- })
- },
- },
- }
- </script>
- <style lang="scss">
-
- .imagV{
- width: 100%;
- }
- .imageIcon{
- width: 60rpx;
- }
- .actBTct{
- display: flex;
- flex-direction: row;
- justify-content:center;
- align-items: center;
- background-color: aliceblue;
- }
- .actBTV{
- width: 92%;
- display: flex;
- flex-direction: row;
- justify-content:space-between;
- align-items: center;
- }
- .blockView{
- width: 30%;
- height: 140rpx;
- margin-top: 10rpx;
- align-items:center;
- justify-content:center;
- background-color: white;
- border: 2rpx dotted sandybrown;
- }
- .notecontent{
- margin-left: 12rpx;
- display: flex;
- flex-direction:column;
- justify-content: flex-start;
-
- }
- .titleact{
- font-size: 36rpx;
- text-align: left;
- color: saddlebrown;
- }
- .noteact{
- font-size: 40rpx;
- font-weight: bold;
- color: crimson;
- text-align: right;
- margin-top: 26rpx;
- margin-right: 10rpx;
- }
- .keywordLct{
- display: flex;
- flex-direction: colum;
- justify-content:flex-start;
- background-color: aliceblue;
- }
- .titlefl{
- font-size: 30rpx;
- padding-left: 16rpx;
- text-align: left;
- }
- .titlev{
- font-size: 30rpx;
- text-align: left;
- }
- .notev{
- font-size: 28rpx;
- color: darkgray;
- text-align: left;
- }
- .xuangou{
- font-size: 28rpx;
- margin-left: auto;
- margin-right: 20rpx;
- padding: 8rpx;
- border: 2rpx solid brown;
- border-radius: 8rpx;
- }
- .huiyuanqyct{
- display: flex;
- flex-direction: column;
- justify-content:center;
- align-items: center;
- background-color: aliceblue;
- }
- .huiyuanqy{
- width: 100%;
- margin-top: 20rpx;
- height: 40rpx;
- }
- .hyqyct{
- width: 86%;
- margin: 16rpx;
- padding-bottom: 18rpx;
- display: flex;
- flex-direction: column;
- justify-content:flex-start;
- border-bottom-width: 2rpx;
- border-bottom-color: lightgray;
- border-bottom-style: solid;
-
- }
- .qyblockView{
- width: 100%;
- margin-top: 6rpx;
- margin-left: 16rpx;
- margin-right: 16rpx;
- padding: 20rpx;
- display: flex;
- flex-direction:row;
- justify-content: flex-start;
- align-items:center;
- background-color: wheat;
- }
- .zhangshu{
- font-size: 28rpx;
- margin-left: auto;
- margin-right: 20rpx;
- padding: 8rpx;
- }
- .yhqje{
- width: 100rpx;
- font-size: 46rpx;
- text-align: right;
- padding-left: 10rpx;
- }
- .shuline{
- margin-left: 10rpx;
- margin-right: 6rpx;
- background-color: darkgray;
- width: 4rpx;
- height: 80rpx;
- }
- </style>
|