|
@@ -1,52 +1,56 @@
|
|
|
<template>
|
|
|
<view class="container cashier">
|
|
|
- <custom :navbar-data='nvabarData' />
|
|
|
- <view class="container-banner" :style="{ paddingTop:CustomBar + 180 +'px' }">
|
|
|
- <view class="login-input">
|
|
|
- <input type="text"
|
|
|
- v-model="params.ticket"
|
|
|
- maxlength="20"
|
|
|
- disabled="true"
|
|
|
- class="input"
|
|
|
- />
|
|
|
+ <tui-skeleton v-if="skeletonShow" backgroundColor="#fafafa" borderRadius="10rpx" :isLoading="true" :loadingType="5" />
|
|
|
+ <template v-else>
|
|
|
+ <custom :navbar-data='nvabarData' />
|
|
|
+ <view class="container-banner" :style="{ paddingTop:CustomBar + 170 +'px' }">
|
|
|
+ <view class="container-title">{{ voteTitle }}</view>
|
|
|
+ <view class="login-input">
|
|
|
+ <input type="text"
|
|
|
+ v-model="params.ticket"
|
|
|
+ maxlength="20"
|
|
|
+ disabled="true"
|
|
|
+ class="input"
|
|
|
+ />
|
|
|
+ </view>
|
|
|
+ <view class="login-input">
|
|
|
+ <input type="text"
|
|
|
+ v-model="params.name"
|
|
|
+ maxlength="10"
|
|
|
+ class="input"
|
|
|
+ placeholder="您的姓名"
|
|
|
+ />
|
|
|
+ </view>
|
|
|
+ <view class="login-input">
|
|
|
+ <input type="text"
|
|
|
+ v-model="params.idCard"
|
|
|
+ maxlength="20"
|
|
|
+ class="input"
|
|
|
+ placeholder="证件号码(身份证/港澳台通行证/护照)"
|
|
|
+ />
|
|
|
+ </view>
|
|
|
+ <view class="login-input">
|
|
|
+ <input type="text"
|
|
|
+ v-model="params.mobile"
|
|
|
+ maxlength="11"
|
|
|
+ class="input"
|
|
|
+ placeholder="您的联系电话"
|
|
|
+ />
|
|
|
+ </view>
|
|
|
+ <view class="login-input">
|
|
|
+ <input type="text"
|
|
|
+ v-model="params.work"
|
|
|
+ maxlength="15"
|
|
|
+ class="input"
|
|
|
+ placeholder="您的职业"
|
|
|
+ />
|
|
|
+ </view>
|
|
|
+ <view class="login-btn" v-show="isBundled" @click="handleEntry">绑定采美账号</view>
|
|
|
+ <view class="login-text">
|
|
|
+ 说明:门票绑定的证件号码是作为进入大会会场的凭证。
|
|
|
+ </view>
|
|
|
</view>
|
|
|
- <view class="login-input">
|
|
|
- <input type="text"
|
|
|
- v-model="params.name"
|
|
|
- maxlength="10"
|
|
|
- class="input"
|
|
|
- placeholder="您的姓名"
|
|
|
- />
|
|
|
- </view>
|
|
|
- <view class="login-input">
|
|
|
- <input type="text"
|
|
|
- v-model="params.idCard"
|
|
|
- maxlength="20"
|
|
|
- class="input"
|
|
|
- placeholder="证件号码(身份证/港澳台通行证/护照)"
|
|
|
- />
|
|
|
- </view>
|
|
|
- <view class="login-input">
|
|
|
- <input type="text"
|
|
|
- v-model="params.mobile"
|
|
|
- maxlength="11"
|
|
|
- class="input"
|
|
|
- placeholder="您的联系电话"
|
|
|
- />
|
|
|
- </view>
|
|
|
- <view class="login-input">
|
|
|
- <input type="text"
|
|
|
- v-model="params.work"
|
|
|
- maxlength="15"
|
|
|
- class="input"
|
|
|
- placeholder="您的职业"
|
|
|
- />
|
|
|
- </view>
|
|
|
- <view class="login-btn" @click="handleEntry">绑定采美账号</view>
|
|
|
- <view class="login-text">
|
|
|
- 说明:门票绑定的证件号码是作为进入大会会场的凭证。
|
|
|
- </view>
|
|
|
- </view>
|
|
|
+ </template>
|
|
|
<!-- 提示弹窗 -->
|
|
|
<tui-modal
|
|
|
:show="modal"
|
|
@@ -77,7 +81,8 @@
|
|
|
textLeft:this.$store.state.isIphone
|
|
|
},
|
|
|
isIphoneX:this.$store.state.isIphoneX,
|
|
|
- CustomBar:this.CustomBar,// 顶部导航栏高度
|
|
|
+ CustomBar:this.CustomBar,// 顶部导航栏高度
|
|
|
+ skeletonShow:true,
|
|
|
params:{
|
|
|
name:'',
|
|
|
idCard:'',
|
|
@@ -86,6 +91,7 @@
|
|
|
work:'',
|
|
|
userId:''
|
|
|
},
|
|
|
+ voteTitle:'',
|
|
|
modal: false,
|
|
|
contentModalText: '', //操作文字提示语句
|
|
|
modalButton: [
|
|
@@ -102,12 +108,12 @@
|
|
|
},
|
|
|
plain: false
|
|
|
}
|
|
|
- ]
|
|
|
+ ],
|
|
|
+ isBundled:true
|
|
|
}
|
|
|
},
|
|
|
onLoad(option) {
|
|
|
wxLogin.wxLoginAuthorize()
|
|
|
- this.params.ticket = option.ticket
|
|
|
setTimeout(()=>{
|
|
|
this.initData(option)
|
|
|
},2000)
|
|
@@ -119,8 +125,31 @@
|
|
|
// 初始化
|
|
|
async initData(option) {
|
|
|
const userInfo = await this.$api.getStorage()
|
|
|
- this.params.userId = userInfo.userId
|
|
|
- this.contentModalText = `您的采美机构账号为【${userInfo.name}】,确认绑定吗?`
|
|
|
+ this.params.ticket = option.ticket
|
|
|
+ this.voteTitle = option.voteType*1 === 1 ? '大会通票' : '学术套票'
|
|
|
+ console.log('userInfo',userInfo)
|
|
|
+ if(userInfo.userId){
|
|
|
+ this.params.userId = userInfo.userId
|
|
|
+ this.contentModalText = `您的采美机构账号为【${userInfo.name}】,确认绑定吗?`
|
|
|
+ }
|
|
|
+ this.getTicketDetails({ ticket: option.ticket})
|
|
|
+ },
|
|
|
+ // 查询门票信息
|
|
|
+ async getTicketDetails(params){
|
|
|
+ try{
|
|
|
+ const res = await this.UserService.getTicketDetails(params)
|
|
|
+ const data = res.data
|
|
|
+ if(data.userId){
|
|
|
+ this.isBundled = false
|
|
|
+ this.params = {...this.params ,...data}
|
|
|
+ this.params.idCard = data.idCard.substring(0, 4) + '**********' + data.idCard.substring(data.idCard.length - 4);
|
|
|
+ }else{
|
|
|
+ this.isBundled = true
|
|
|
+ }
|
|
|
+ this.skeletonShow = false
|
|
|
+ }catch(error){
|
|
|
+ this.$util.msg(error.msg,2000)
|
|
|
+ }
|
|
|
},
|
|
|
//确认操作
|
|
|
handleClick(e) {
|
|
@@ -191,6 +220,14 @@
|
|
|
background-size: contain;
|
|
|
box-sizing: border-box;
|
|
|
padding: 0 110rpx;
|
|
|
+ .container-title{
|
|
|
+ height: 120rpx;
|
|
|
+ line-height: 120rpx;
|
|
|
+ font-size: $font-size-48;
|
|
|
+ font-weight: 600;
|
|
|
+ text-align: center;
|
|
|
+ color: #FFFFFF;
|
|
|
+ }
|
|
|
.login-title{
|
|
|
font-size: $font-size-28;
|
|
|
line-height: 58rpx;
|