parent
a215b9b263
commit
738f058281
File diff suppressed because it is too large
Load Diff
|
|
@ -83,7 +83,7 @@
|
||||||
mode="aspectFill"></image>
|
mode="aspectFill"></image>
|
||||||
</view>
|
</view>
|
||||||
<view class="promo-right">
|
<view class="promo-right">
|
||||||
<view class="promo-content" >
|
<view class="promo-content">
|
||||||
<text class="promo-title">{{ transferData.promoTitle }}</text>
|
<text class="promo-title">{{ transferData.promoTitle }}</text>
|
||||||
<view class="promo-tags">
|
<view class="promo-tags">
|
||||||
<text class="tag">{{ transferData.promoTag }}</text>
|
<text class="tag">{{ transferData.promoTag }}</text>
|
||||||
|
|
@ -677,6 +677,10 @@ const goBack = () => {
|
||||||
::v-deep .tipLayer {
|
::v-deep .tipLayer {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
::v-deep .uni-navbar__header-btns {
|
||||||
|
width: 100px !important;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.status-bar {
|
.status-bar {
|
||||||
|
|
|
||||||
|
|
@ -15,8 +15,7 @@
|
||||||
<l-painter-image :src="bgImage" css="width: 822px; display: block;"></l-painter-image>
|
<l-painter-image :src="bgImage" css="width: 822px; display: block;"></l-painter-image>
|
||||||
|
|
||||||
<!-- 人物图片 -->
|
<!-- 人物图片 -->
|
||||||
<l-painter-image :src="hePingData.imgUrl" :css="characterStyle"
|
<l-painter-image :src="hePingData.imgUrl" :css="characterStyle"></l-painter-image>
|
||||||
mode="heightFix"></l-painter-image>
|
|
||||||
<template v-if="hePingData.type == 2">
|
<template v-if="hePingData.type == 2">
|
||||||
<!-- 头像 -->
|
<!-- 头像 -->
|
||||||
<l-painter-image :src="hePingData.avatar"
|
<l-painter-image :src="hePingData.avatar"
|
||||||
|
|
@ -78,7 +77,7 @@
|
||||||
<text>×</text>
|
<text>×</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="upload-btn" v-else @click="handleChooseImgUrl">
|
<view class="upload-btn" v-else>
|
||||||
<text class="plus">+</text>
|
<text class="plus">+</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -121,6 +120,7 @@
|
||||||
import { ref, reactive, computed, watch, onMounted, getCurrentInstance } from 'vue'
|
import { ref, reactive, computed, watch, onMounted, getCurrentInstance } from 'vue'
|
||||||
import { onLoad, onReady, onUnload } from '@dcloudio/uni-app'
|
import { onLoad, onReady, onUnload } from '@dcloudio/uni-app'
|
||||||
import { imgLocal } from '@/utils/common.js';
|
import { imgLocal } from '@/utils/common.js';
|
||||||
|
import NavBar from '@/components/nav-bar/nav-bar.vue';
|
||||||
const instance = getCurrentInstance();
|
const instance = getCurrentInstance();
|
||||||
const { proxy } = getCurrentInstance();
|
const { proxy } = getCurrentInstance();
|
||||||
|
|
||||||
|
|
@ -177,7 +177,13 @@ onLoad(async () => {
|
||||||
uni.setStorageSync('hePingData', hePingData);
|
uni.setStorageSync('hePingData', hePingData);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
bgImage.value = await imgLocal.getLocalImage(`other/game/heping/bg-${hePingData.type}.jpg`)
|
try {
|
||||||
|
bgImage.value = await imgLocal.getLocalImage(`other/game/heping/bg-${hePingData.type}.jpg`);
|
||||||
|
} catch (e) {
|
||||||
|
console.error('获取背景图失败:', e);
|
||||||
|
uni.showToast({ title: '背景图加载失败', icon: 'none' });
|
||||||
|
}
|
||||||
|
|
||||||
uni.$on('editFormPhoto', (info) => {
|
uni.$on('editFormPhoto', (info) => {
|
||||||
if (currentEditImgField.value) {
|
if (currentEditImgField.value) {
|
||||||
tempData[currentEditImgField.value] = info;
|
tempData[currentEditImgField.value] = info;
|
||||||
|
|
@ -190,12 +196,14 @@ onLoad(async () => {
|
||||||
});
|
});
|
||||||
|
|
||||||
// 进入页面埋点
|
// 进入页面埋点
|
||||||
proxy.$apiUserEvent('all', {
|
if (proxy && proxy.$apiUserEvent) {
|
||||||
type: 'click',
|
proxy.$apiUserEvent('all', {
|
||||||
key: 'heping',
|
type: 'click',
|
||||||
prefix: '.uni.other.',
|
key: 'heping',
|
||||||
value: "和平精英"
|
prefix: '.uni.other.',
|
||||||
})
|
value: "和平精英"
|
||||||
|
});
|
||||||
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
onUnload(() => {
|
onUnload(() => {
|
||||||
|
|
@ -297,7 +305,12 @@ async function handleChangeTheme(typeIndex) {
|
||||||
bgImage.value = ''; // 强制卸载旧画板,确保能重新渲染和生成新海报
|
bgImage.value = ''; // 强制卸载旧画板,确保能重新渲染和生成新海报
|
||||||
hePingData.type = typeIndex;
|
hePingData.type = typeIndex;
|
||||||
uni.setStorageSync('hePingData', hePingData);
|
uni.setStorageSync('hePingData', hePingData);
|
||||||
bgImage.value = await imgLocal.getLocalImage(`other/game/heping/bg-${typeIndex}.jpg`);
|
try {
|
||||||
|
bgImage.value = await imgLocal.getLocalImage(`other/game/heping/bg-${typeIndex}.jpg`);
|
||||||
|
} catch (e) {
|
||||||
|
console.error('切换主题加载背景图失败:', e);
|
||||||
|
uni.showToast({ title: '背景加载失败', icon: 'none' });
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 点击画布触发横向预览
|
// 点击画布触发横向预览
|
||||||
|
|
|
||||||
|
|
@ -15,8 +15,7 @@
|
||||||
<l-painter-image :src="bgImage" css="width: 822px; display: block;"></l-painter-image>
|
<l-painter-image :src="bgImage" css="width: 822px; display: block;"></l-painter-image>
|
||||||
|
|
||||||
<!-- 人物图片 -->
|
<!-- 人物图片 -->
|
||||||
<l-painter-image :src="wuweiData.imgUrl" :css="characterStyle"
|
<l-painter-image :src="wuweiData.imgUrl" :css="characterStyle"></l-painter-image>
|
||||||
mode="widthFix"></l-painter-image>
|
|
||||||
<!-- 击败 -->
|
<!-- 击败 -->
|
||||||
<l-painter-text :text="wuweiData.killCount" :css="killCountStyle"></l-painter-text>
|
<l-painter-text :text="wuweiData.killCount" :css="killCountStyle"></l-painter-text>
|
||||||
<template v-if="wuweiData.type == 1">
|
<template v-if="wuweiData.type == 1">
|
||||||
|
|
@ -99,7 +98,7 @@
|
||||||
<text>×</text>
|
<text>×</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="upload-btn" v-else @click="handleChooseImgUrl">
|
<view class="upload-btn" v-else>
|
||||||
<text class="plus">+</text>
|
<text class="plus">+</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -174,6 +173,7 @@
|
||||||
import { ref, reactive, computed, watch, onMounted, getCurrentInstance } from 'vue'
|
import { ref, reactive, computed, watch, onMounted, getCurrentInstance } from 'vue'
|
||||||
import { onLoad, onReady, onUnload } from '@dcloudio/uni-app'
|
import { onLoad, onReady, onUnload } from '@dcloudio/uni-app'
|
||||||
import { imgLocal } from '@/utils/common.js';
|
import { imgLocal } from '@/utils/common.js';
|
||||||
|
import NavBar from '@/components/nav-bar/nav-bar.vue';
|
||||||
const instance = getCurrentInstance();
|
const instance = getCurrentInstance();
|
||||||
const { proxy } = getCurrentInstance();
|
const { proxy } = getCurrentInstance();
|
||||||
|
|
||||||
|
|
@ -270,7 +270,13 @@ onLoad(async () => {
|
||||||
uni.setStorageSync('wuweiData', wuweiData);
|
uni.setStorageSync('wuweiData', wuweiData);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
bgImage.value = await imgLocal.getLocalImage(`other/game/wuwei/bg-${wuweiData.type}.jpg`)
|
try {
|
||||||
|
bgImage.value = await imgLocal.getLocalImage(`other/game/wuwei/bg-${wuweiData.type}.jpg`);
|
||||||
|
} catch (e) {
|
||||||
|
console.error('获取背景图失败:', e);
|
||||||
|
uni.showToast({ title: '背景图加载失败', icon: 'none' });
|
||||||
|
}
|
||||||
|
|
||||||
uni.$on('editFormPhoto', (info) => {
|
uni.$on('editFormPhoto', (info) => {
|
||||||
if (currentEditImgField.value) {
|
if (currentEditImgField.value) {
|
||||||
tempData[currentEditImgField.value] = info;
|
tempData[currentEditImgField.value] = info;
|
||||||
|
|
@ -283,12 +289,14 @@ onLoad(async () => {
|
||||||
});
|
});
|
||||||
|
|
||||||
// 进入页面埋点
|
// 进入页面埋点
|
||||||
proxy.$apiUserEvent('all', {
|
if (proxy && proxy.$apiUserEvent) {
|
||||||
type: 'click',
|
proxy.$apiUserEvent('all', {
|
||||||
key: 'wuwei',
|
type: 'click',
|
||||||
prefix: '.uni.other.',
|
key: 'wuwei',
|
||||||
value: "无畏契约"
|
prefix: '.uni.other.',
|
||||||
})
|
value: "无畏契约"
|
||||||
|
});
|
||||||
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
onUnload(() => {
|
onUnload(() => {
|
||||||
|
|
@ -391,7 +399,12 @@ async function handleChangeTheme(typeIndex) {
|
||||||
bgImage.value = ''; // 强制卸载旧画板,确保能重新渲染和生成新海报
|
bgImage.value = ''; // 强制卸载旧画板,确保能重新渲染和生成新海报
|
||||||
wuweiData.type = typeIndex;
|
wuweiData.type = typeIndex;
|
||||||
uni.setStorageSync('wuweiData', wuweiData);
|
uni.setStorageSync('wuweiData', wuweiData);
|
||||||
bgImage.value = await imgLocal.getLocalImage(`other/game/wuwei/bg-${typeIndex}.jpg`);
|
try {
|
||||||
|
bgImage.value = await imgLocal.getLocalImage(`other/game/wuwei/bg-${typeIndex}.jpg`);
|
||||||
|
} catch (e) {
|
||||||
|
console.error('切换主题加载背景图失败:', e);
|
||||||
|
uni.showToast({ title: '背景加载失败', icon: 'none' });
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 点击画布触发横向预览
|
// 点击画布触发横向预览
|
||||||
|
|
|
||||||
|
|
@ -20,22 +20,26 @@
|
||||||
<template v-slot:center>
|
<template v-slot:center>
|
||||||
<view class="codefun-flex-row">
|
<view class="codefun-flex-row">
|
||||||
<text class="text">订单</text>
|
<text class="text">订单</text>
|
||||||
<text class="text_2 ml-15">行程服务</text>
|
<text class="text_2 ml-15">{{ ticketsInfo.status == '已出行' ? '推荐' : '行程服务' }}</text>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
<template v-slot:right>
|
<template v-slot:right>
|
||||||
<view class="codefun-flex-col pos_2">
|
<view class="codefun-flex-col pos_2">
|
||||||
<view class="codefun-flex-row">
|
<view class="codefun-flex-row" style="margin-right: 10px;">
|
||||||
<view class="codefun-flex-col codefun-items-center">
|
<view class="codefun-flex-col codefun-items-center">
|
||||||
<image class="image_5" src="/static/image/other/train-tickets/ctrip/customer-sevice.png" />
|
<image class="image_5" src="/static/image/other/train-tickets/ctrip/customer-sevice.png" />
|
||||||
<text class="font text_3">客服</text>
|
<text class="font text_3">客服</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="codefun-flex-col codefun-items-center"
|
<view class="codefun-flex-col codefun-items-center" style="margin-left: 16rpx;">
|
||||||
style="margin-left: 16rpx;margin-right: 10px;">
|
|
||||||
<image class="image_5"
|
<image class="image_5"
|
||||||
src="/static/image/other/train-tickets/ctrip/refund-instructions.png" />
|
src="/static/image/other/train-tickets/ctrip/refund-instructions.png" />
|
||||||
<text class="font text_3">退改说明</text>
|
<text class="font text_3">退改说明</text>
|
||||||
</view>
|
</view>
|
||||||
|
<view v-if="ticketsInfo.status == '已出行'" class="codefun-flex-col codefun-items-center"
|
||||||
|
style="margin-left: 16rpx;">
|
||||||
|
<image class="image_5" src="/static/image/other/train-tickets/ctrip/fenxiang.png" />
|
||||||
|
<text class="font text_3">分享</text>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
@ -47,8 +51,10 @@
|
||||||
<view class="codefun-flex-row group_5">
|
<view class="codefun-flex-row group_5">
|
||||||
<image class="image_8" src="/static/image/other/train-tickets/ctrip/success.png" />
|
<image class="image_8" src="/static/image/other/train-tickets/ctrip/success.png" />
|
||||||
<view class="codefun-flex-col codefun-items-start group_33 codefun-ml-10">
|
<view class="codefun-flex-col codefun-items-start group_33 codefun-ml-10">
|
||||||
<text class="text_5">抢票成功</text>
|
<text class="text_5">{{ ticketsInfo.status || '抢票成功' }}</text>
|
||||||
<text class="font_2 text_6 codefun-mt-8">携程祝您出行愉快</text>
|
<text class="font_2 text_6 codefun-mt-8">{{ ticketsInfo.status == '已出行' ? '携程已为您完成本次预定' :
|
||||||
|
'携程祝您出行愉快'
|
||||||
|
}}</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<image class="image_7" src="/static/image/other/train-tickets/ctrip/buy-return-trip.png" />
|
<image class="image_7" src="/static/image/other/train-tickets/ctrip/buy-return-trip.png" />
|
||||||
|
|
@ -66,9 +72,13 @@
|
||||||
<view class="main-container">
|
<view class="main-container">
|
||||||
<view class="codefun-flex-col codefun-justify-start section_3">
|
<view class="codefun-flex-col codefun-justify-start section_3">
|
||||||
<view class="codefun-flex-row codefun-justify-between codefun-items-center section_4">
|
<view class="codefun-flex-row codefun-justify-between codefun-items-center section_4">
|
||||||
<text class="text_8">注意确认行程信息</text>
|
<text v-if="ticketsInfo.status == '抢票成功'" class="text_8">注意确认行程信息</text>
|
||||||
|
<view v-else class="codefun-flex-col codefun-items-start">
|
||||||
|
<text class="text_8">行程已结束</text>
|
||||||
|
<text class="text_8" style="font-size: 14px;font-weight: 400;margin-top: 6px;">感谢您使用携程火车票</text>
|
||||||
|
</view>
|
||||||
<view class="codefun-flex-col">
|
<view class="codefun-flex-col">
|
||||||
<view class="codefun-flex-row group_6">
|
<view v-if="ticketsInfo.status == '抢票成功'" class="codefun-flex-row group_6">
|
||||||
<view class="item-box codefun-flex-col codefun-items-center">
|
<view class="item-box codefun-flex-col codefun-items-center">
|
||||||
<image class="image_6" src="/static/image/other/train-tickets/ctrip/zaixianhuanzuo.png" />
|
<image class="image_6" src="/static/image/other/train-tickets/ctrip/zaixianhuanzuo.png" />
|
||||||
<text class="font_3 text_9 mt-5">在线换座</text>
|
<text class="font_3 text_9 mt-5">在线换座</text>
|
||||||
|
|
@ -84,6 +94,18 @@
|
||||||
<text class="font_3 text_11 ml-11 mt-5">分享行程</text>
|
<text class="font_3 text_11 ml-11 mt-5">分享行程</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<view v-if="ticketsInfo.status == '已出行'" class="codefun-flex-row group_6">
|
||||||
|
<view class="item-box codefun-flex-col codefun-items-center">
|
||||||
|
<image class="image_6 ml-11"
|
||||||
|
src="/static/image/other/train-tickets/ctrip/jiesongzhan.png" />
|
||||||
|
<text class="font_3 text_10 ml-11 mt-5">接送站</text>
|
||||||
|
</view>
|
||||||
|
<view class="item-box codefun-flex-col codefun-items-center">
|
||||||
|
<image class="image_6 ml-11"
|
||||||
|
src="/static/image/other/train-tickets/ctrip/fapiaobaoxiao-yichuxing.png" />
|
||||||
|
<text class="font_3 text_11 ml-11 mt-5">发票报销</text>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -92,7 +114,8 @@
|
||||||
<view class="codefun-flex-col group_8">
|
<view class="codefun-flex-col group_8">
|
||||||
<view class="codefun-flex-row codefun-justify-between" style="width: 100%;">
|
<view class="codefun-flex-row codefun-justify-between" style="width: 100%;">
|
||||||
<text class="font_6 text_12">取票号:{{ ticketsInfo.orderInfo.orderNo }}</text>
|
<text class="font_6 text_12">取票号:{{ ticketsInfo.orderInfo.orderNo }}</text>
|
||||||
<text class="font_5 text_13">{{ ticketsInfo.ticketInfo.gate }}</text>
|
<text v-if="ticketsInfo.status == '抢票成功'" class="font_5 text_13">
|
||||||
|
{{ ticketsInfo.ticketInfo.gate }}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="codefun-flex-row codefun-justify-between codefun-self-stretch group_9">
|
<view class="codefun-flex-row codefun-justify-between codefun-self-stretch group_9">
|
||||||
<view class="codefun-flex-col">
|
<view class="codefun-flex-col">
|
||||||
|
|
@ -122,7 +145,7 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="codefun-flex-row codefun-items-center">
|
<view class="codefun-flex-row codefun-items-center">
|
||||||
<text class="font_9 text_19">{{ ticketsInfo.ticketInfo.trainNo }}</text>
|
<text class="font_9 text_19">{{ ticketsInfo.ticketInfo.trainNo }}</text>
|
||||||
<view v-if="ticketsInfo.ticketInfo.trainName"
|
<view v-if="ticketsInfo.ticketInfo.trainName && ticketsInfo.status == '抢票成功'"
|
||||||
class="codefun-flex-row codefun-items-center train-name">
|
class="codefun-flex-row codefun-items-center train-name">
|
||||||
<text class="font_6">{{ ticketsInfo.ticketInfo.trainName }}</text>
|
<text class="font_6">{{ ticketsInfo.ticketInfo.trainName }}</text>
|
||||||
<uni-icons type="right" size="10" color="#767676"></uni-icons>
|
<uni-icons type="right" size="10" color="#767676"></uni-icons>
|
||||||
|
|
@ -162,15 +185,16 @@
|
||||||
</view>
|
</view>
|
||||||
<view class="codefun-flex-row codefun-justify-between codefun-mt-8">
|
<view class="codefun-flex-row codefun-justify-between codefun-mt-8">
|
||||||
<view class="codefun-flex-row codefun-items-center">
|
<view class="codefun-flex-row codefun-items-center">
|
||||||
<image class="image_15"
|
<image v-show="Number(item.points) > 0" class="image_15"
|
||||||
src="/static/image/other/train-tickets/ctrip/jifen.png" />
|
src="/static/image/other/train-tickets/ctrip/jifen.png" />
|
||||||
<view class="group_17">
|
<view v-show="Number(item.points) > 0" class="group_17">
|
||||||
<text class="font_13">铁路会员积分+{{ item.points }}(价值</text>
|
<text class="font_13">铁路会员积分+{{ item.points }}(价值</text>
|
||||||
<text class="font_14 text_24">¥{{ (item.points *
|
<text class="font_14 text_24">¥{{ (item.points *
|
||||||
0.01).toFixed(2) }}</text>
|
0.01).toFixed(2) }}</text>
|
||||||
<text class="font_13 text_24 text_25">)</text>
|
<text class="font_13 text_24 text_25">)</text>
|
||||||
</view>
|
</view>
|
||||||
<image class="image_16"
|
<image v-show="Number(item.points) > 0" class="image_16"
|
||||||
|
style="margin-top: 2px;"
|
||||||
src="/static/image/other/train-tickets/ctrip/help.png" />
|
src="/static/image/other/train-tickets/ctrip/help.png" />
|
||||||
</view>
|
</view>
|
||||||
<view class="codefun-flex-row codefun-items-center">
|
<view class="codefun-flex-row codefun-items-center">
|
||||||
|
|
@ -182,8 +206,10 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="codefun-flex-row codefun-justify-between codefun-items-center">
|
<view class="codefun-flex-row codefun-justify-between codefun-items-center">
|
||||||
<text class="success-text">购票成功</text>
|
<text class="success-text"
|
||||||
<view class="codefun-flex-row codefun-justify-end group_18">
|
:style="{ 'margin-top': Number(item.points) > 0 ? '0px' : '-60px' }">购票成功</text>
|
||||||
|
<view class="codefun-flex-row codefun-justify-end group_18 "
|
||||||
|
:class="{ yichuxing: ticketsInfo.status == '已出行' }">
|
||||||
<view
|
<view
|
||||||
class="codefun-flex-col codefun-justify-start codefun-items-center text-wrapper_2">
|
class="codefun-flex-col codefun-justify-start codefun-items-center text-wrapper_2">
|
||||||
<text class="font_16 text_28">改签</text>
|
<text class="font_16 text_28">改签</text>
|
||||||
|
|
@ -192,7 +218,7 @@
|
||||||
class="codefun-flex-col codefun-justify-start codefun-items-center text-wrapper_3 ml-7">
|
class="codefun-flex-col codefun-justify-start codefun-items-center text-wrapper_3 ml-7">
|
||||||
<text class="font_16 text_29">退票</text>
|
<text class="font_16 text_29">退票</text>
|
||||||
</view>
|
</view>
|
||||||
<view v-if="item.isMe"
|
<view v-if="item.isMe && ticketsInfo.status == '抢票成功'"
|
||||||
class="codefun-flex-col codefun-justify-start codefun-items-center text-wrapper_1 ml-7">
|
class="codefun-flex-col codefun-justify-start codefun-items-center text-wrapper_1 ml-7">
|
||||||
<text class="font_17 text_30">扫码检票</text>
|
<text class="font_17 text_30">扫码检票</text>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -278,27 +304,64 @@
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
|
<!-- 样式选择弹窗 -->
|
||||||
|
<uni-popup ref="stylePopup" type="center">
|
||||||
|
<view class="style-popup-container">
|
||||||
|
<view class="popup-title">选择展示样式</view>
|
||||||
|
<view class="popup-list">
|
||||||
|
<view class="popup-item" @click="selectStyle('抢票成功')">
|
||||||
|
<text class="item-text">抢票成功 (默认)</text>
|
||||||
|
<uni-icons v-if="ticketsInfo.status === '抢票成功' || !ticketsInfo.status" type="checkmarkempty"
|
||||||
|
color="#3B82F6" size="20"></uni-icons>
|
||||||
|
</view>
|
||||||
|
<view class="popup-item" @click="selectStyle('已出行')">
|
||||||
|
<text class="item-text">已出行</text>
|
||||||
|
<uni-icons v-if="ticketsInfo.status === '已出行'" type="checkmarkempty" color="#3B82F6"
|
||||||
|
size="20"></uni-icons>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="popup-cancel" @click="closeStylePopup">取消</view>
|
||||||
|
</view>
|
||||||
|
</uni-popup>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import NavBar from '@/components/nav-bar/nav-bar.vue';
|
import NavBar from '@/components/nav-bar/nav-bar.vue';
|
||||||
import { reactive, toRefs } from 'vue';
|
import { reactive, toRefs, ref } from 'vue';
|
||||||
import { onShow, onPageScroll } from '@dcloudio/uni-app';
|
import { onShow, onPageScroll } from '@dcloudio/uni-app';
|
||||||
import { util } from '@/utils/common.js';
|
import { util } from '@/utils/common.js';
|
||||||
|
|
||||||
const buttonGroup = [{
|
const buttonGroup = [
|
||||||
name: "编辑车票信息",
|
{
|
||||||
click: () => {
|
name: "编辑车票信息",
|
||||||
goEdit()
|
click: () => {
|
||||||
|
goEdit()
|
||||||
|
}
|
||||||
|
}, {
|
||||||
|
name: "切换样式",
|
||||||
|
click: () => {
|
||||||
|
stylePopup.value.open();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}]
|
]
|
||||||
|
|
||||||
|
const stylePopup = ref(null);
|
||||||
|
|
||||||
function goEdit() {
|
function goEdit() {
|
||||||
util.goPage(`/pages/other/train-tickets/edit/edit?app=ctrip&storageKey=${data.STORAGE_KEY}`)
|
util.goPage(`/pages/other/train-tickets/edit/edit?app=ctrip&storageKey=${data.STORAGE_KEY}`)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const selectStyle = (status) => {
|
||||||
|
data.ticketsInfo.status = status;
|
||||||
|
uni.setStorageSync(data.STORAGE_KEY, data.ticketsInfo);
|
||||||
|
stylePopup.value.close();
|
||||||
|
}
|
||||||
|
|
||||||
|
const closeStylePopup = () => {
|
||||||
|
stylePopup.value.close();
|
||||||
|
}
|
||||||
|
|
||||||
const data = reactive({
|
const data = reactive({
|
||||||
navBar: {
|
navBar: {
|
||||||
bgColor: 'transparent'
|
bgColor: 'transparent'
|
||||||
|
|
@ -312,6 +375,7 @@ const data = reactive({
|
||||||
],
|
],
|
||||||
STORAGE_KEY: 'ctripTrainTicketsInfo',
|
STORAGE_KEY: 'ctripTrainTicketsInfo',
|
||||||
ticketsInfo: {
|
ticketsInfo: {
|
||||||
|
"status": "抢票成功",
|
||||||
"orderInfo": {
|
"orderInfo": {
|
||||||
"orderNo": "EJ66223536",
|
"orderNo": "EJ66223536",
|
||||||
"price": "4440"
|
"price": "4440"
|
||||||
|
|
@ -961,6 +1025,33 @@ const formatMMDD = (mdStr) => {
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
&.yichuxing {
|
||||||
|
.text-wrapper_2 {
|
||||||
|
background-color: #FFFFFF;
|
||||||
|
border-radius: 6px;
|
||||||
|
width: 45px;
|
||||||
|
height: 28px;
|
||||||
|
border: solid 0.5px #e0e4e3;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
.text-wrapper_3 {
|
||||||
|
background-color: #ffffff;
|
||||||
|
border-radius: 6px;
|
||||||
|
width: 45px;
|
||||||
|
height: 28px;
|
||||||
|
border: solid 0.5px #e0e4e3;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
.font_16 {
|
||||||
|
font-size: 13px;
|
||||||
|
line-height: 28px;
|
||||||
|
font-weight: 500;
|
||||||
|
color: #D0D0D0;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -1227,4 +1318,50 @@ const formatMMDD = (mdStr) => {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.style-popup-container {
|
||||||
|
width: 300px;
|
||||||
|
background-color: #ffffff;
|
||||||
|
border-radius: 12px;
|
||||||
|
padding-bottom: 1px;
|
||||||
|
|
||||||
|
.popup-title {
|
||||||
|
text-align: center;
|
||||||
|
font-size: 16px;
|
||||||
|
font-weight: bold;
|
||||||
|
color: #333333;
|
||||||
|
padding: 20px 0 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.popup-list {
|
||||||
|
padding: 0 20px;
|
||||||
|
|
||||||
|
.popup-item {
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
align-items: center;
|
||||||
|
padding: 15px 0;
|
||||||
|
border-bottom: 1px solid #f0f0f0;
|
||||||
|
|
||||||
|
&:last-child {
|
||||||
|
border-bottom: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.item-text {
|
||||||
|
font-size: 15px;
|
||||||
|
color: #333333;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.popup-cancel {
|
||||||
|
margin: 15px 20px 20px;
|
||||||
|
background-color: #f5f5f5;
|
||||||
|
border-radius: 8px;
|
||||||
|
text-align: center;
|
||||||
|
padding: 12px 0;
|
||||||
|
font-size: 15px;
|
||||||
|
color: #666666;
|
||||||
|
}
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
||||||
Binary file not shown.
|
After Width: | Height: | Size: 1.5 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 1.0 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 1.9 KiB |
Loading…
Reference in New Issue