You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

311 lines
6.8 KiB

4 years ago
<template>
<view>
<view class="orderBoxList">
<view class="orderBox">
<view class="orderBoxTitle flex-row">
4 years ago
<text class="orderBoxTitleTxt">{{info.type==1?"团队预约信息":"个人预约信息"}}</text>
4 years ago
</view>
<view class="orderBoxInfo flex-col">
<view class="orderBoxInfoRow flex-row" style="margin-bottom: 20rpx;">
<text class="iconfont icon-youkexuzhi"></text>
4 years ago
<text
class="orderBoxInfoRowTxt">订单信息{{$u.timeFormat(new Date(info.date), 'mm月dd日')}}{{info.time||""}}{{info.total||0}}位观众</text></text>
4 years ago
</view>
<view class="orderBoxInfoRow flex-row">
<text class="iconfont icon-iconfontgerenzhongxin"></text>
4 years ago
<text class="orderBoxInfoRowTxt">联系人{{info.leader||""}} {{info.mobile||""}}</text>
4 years ago
</view>
4 years ago
<view class="orderBoxInfoRow flex-row" v-if="info.type==1" style="margin-top: 20rpx;">
4 years ago
<text class="iconfont icon-danwei"></text>
4 years ago
<text class="orderBoxInfoRowTxt">单位名称{{info.unit||""}}</text>
4 years ago
</view>
</view>
<view class="orderBoxTime">
4 years ago
<text>下单时间{{info.created_at||""}}</text>
4 years ago
</view>
</view>
</view>
4 years ago
<view class="orderBoxList p0" v-if="false">
4 years ago
<view class="orderBox">
<view class="orderBoxTitle flex-row">
<text class="orderBoxTitleTxt">二维码</text>
</view>
<view class="orderBoxInfo flex-col ewmcode">
<text>{{info.code}}</text>
<view>
4 years ago
<view :class="item.status!=1?'imgs isuse':'imgs'">
<canvas canvas-id="qrcode" style="width: 300rpx;margin: 0 auto;" />
4 years ago
</view>
</view>
<text class="ewminfo">{{isuse?'已使用':'请前往现场核销订单二维码'}}</text>
</view>
</view>
</view>
<view class="orderBoxList p0">
<view class="orderBox">
<view class="orderBoxTitle flex-row" style="justify-content: space-between;">
<text class="orderBoxTitleTxt">观众信息</text>
4 years ago
<text v-if="false" :class="isuse?'share shareuse orderBoxInfoRowTxt':'share orderBoxInfoRowTxt'">
4 years ago
分享二维码
</text>
</view>
<view class="orderBoxInfo flex-col">
<view class="orderBoxInfoRow flex-row" style="margin-bottom: 20rpx;"
v-for="(item,index) in info.details">
<view>
<text class="iconfont icon-iconfontgerenzhongxin iconinfo"></text>
</view>
<view class="usercard">
<text class="orderBoxInfoRowTxt">{{item.name}}</text>
<text class="orderBoxInfoRowTxt">{{item.idcard}}</text>
</view>
</view>
</view>
</view>
</view>
<view class="orderBoxList p0">
<view class="orderBoxTitle flex-row">
<text class="stars orderBoxTitleTxt">*</text>
<text class="orderBoxTitleTxt">参观须知</text>
</view>
<view class="orderBoxTitle flex-row">
<text
4 years ago
class="orderBoxInfoRowTxt">{{info.type==1?vinfo.person_notice:vinfo.team_notice}}</text>
4 years ago
</view>
</view>
4 years ago
</view>
</template>
<script>
4 years ago
import uQRCode from "@/utils/qrcode.js"
4 years ago
export default {
data() {
return {
4 years ago
info: {},
vinfo: {}
4 years ago
}
},
4 years ago
onLoad(options) {
this.loadIntroduce();
4 years ago
if (!this.util.isNull(options.id)) {
this.loadInfo(options.id);
4 years ago
}
},
methods: {
4 years ago
qrFun: function(text) {
uQRCode.make({
canvasId: 'qrcode',
componentInstance: this,
text: text,
size: 150,
margin: 0,
backgroundColor: '#ffffff',
foregroundColor: '#000000',
fileType: 'jpg',
errorCorrectLevel: uQRCode.errorCorrectLevel.H,
success: res => {
4 years ago
4 years ago
}
})
},
4 years ago
loadIntroduce() {
var that = this;
this.util.request({
api: '/api/mobile/visit/introduce',
utilSuccess: function(res) {
that.vinfo = res;
},
utilFail: function(res) {
}
})
},
4 years ago
loadInfo(id) {
var that = this;
this.util.request({
api: '/api/mobile/user/my-visit-order-show',
data: {
id: id
},
utilSuccess: function(res) {
that.info = res;
4 years ago
that.qrFun(res.code);
4 years ago
},
utilFail: function(res) {
uni.showToast({
icon: "none",
title: res
})
}
})
}
4 years ago
}
}
</script>
<style>
4 years ago
.orderBoxFooter {
4 years ago
padding: 20rpx 0 0 0;
}
.fbtn {
background: #EF9525;
border-radius: 8rpx;
font-size: 24rpx;
color: #FFFFFF;
padding: 7rpx 17rpx;
}
.cancel {
background: #F7F6F4;
color: #828282;
}
.iconfont {
color: #6EAC97;
margin-right: 20rpx;
font-size: 24rpx;
}
.infotop {
background: #FFFFFF;
box-shadow: 2rpx 3rpx 10rpx 0px rgba(107, 94, 77, 0.3);
}
page {
background-color: #f7f6f4;
}
.orderBoxList {
padding: 26rpx;
box-sizing: border-box;
}
.orderBox {
min-height: 393rpx;
background: #FFFFFF;
border-radius: 16rpx;
box-sizing: border-box;
padding: 29rpx 18rpx;
position: relative;
margin-bottom: 17rpx;
}
.orderBoxTitle {
padding: 0rpx 0rpx 25rpx 0rpx;
border-bottom: 2rpx solid #F7F6F4;
}
.orderBoxInfoRow {
align-items: center;
}
.orderBoxTitleTxt {
font-size: 32rpx;
color: #351C1B;
}
.orderBoxStatus {
background: #EF9525;
border-top-right-radius: 16rpx;
border-bottom-left-radius: 16rpx;
font-size: 24rpx;
padding: 19rpx 23rpx 17rpx 23rpx;
color: #FFFFFF;
position: absolute;
right: 0;
top: 0;
}
.orderBoxInfo {
padding: 29rpx 0rpx;
border-bottom: 2rpx solid #F7F6F4;
}
.orderBoxInfoRowTxt {
font-size: 24rpx;
font-family: PingFang SC;
color: #828282;
}
.orderBoxTime {
color: #CFCFCF;
padding: 23rpx 0;
border-bottom: 2rpx solid #F7F6F4;
font-size: 24rpx;
4 years ago
}
.p0 {
padding-top: 0
}
.ewmcode {
text-align: center;
font-size: 28rpx
}
.imgs {
width: 273rpx;
height: 273rpx;
margin: 30rpx 0 50rpx 0;
font-size: 0;
display: inline-block;
}
.imgs image {
width: 273rpx;
height: 273rpx;
}
.imgs.isuse {
background: url(../../static/img/used.png);
background-position: bottom right;
background-size: 161rpx;
background-repeat: no-repeat;
}
.imgs.isuse image {
opacity: .4;
}
.ewminfo {
color: #828282;
font-size: 24rpx;
}
.iconinfo {
font-size: 35rpx;
}
.usercard text {
display: block;
}
.share {
background: url(../../static/img/share.png) no-repeat left center;
background-size: 21rpx;
background-color: #EF9525;
background-position: 18rpx;
padding: 7rpx 20rpx;
padding-left: 46rpx;
border-radius: 10px;
color: #fff;
}
.shareuse {
background: url(../../static/img/share_used.png) no-repeat left center;
background-color: #F7F6F4;
color: #828282;
background-position: 18rpx;
background-size: 21rpx;
}
.stars {
color: #EF9525;
margin-right: 12rpx
4 years ago
}
4 years ago
</style>