This commit is contained in:
@@ -6,8 +6,6 @@
|
||||
<view class="card">
|
||||
<view class="card-title">订单信息</view>
|
||||
<view class="info-row"><text>订单号</text><text>{{ order.order_no || '-' }}</text></view>
|
||||
<view class="info-row"><text>购买角色</text><text>{{ order.purchase_role || '-' }}</text></view>
|
||||
<view class="info-row"><text>资产标识</text><text>{{ order.asset_identifier || '-' }}</text></view>
|
||||
<view class="info-row"><text>支付方式</text><text>{{ formatPaymentMethod(order.payment_method) }}</text></view>
|
||||
<view class="info-row"><text>支付状态</text><text>{{ order.payment_status_name || getStatusText(order.payment_status) }}</text></view>
|
||||
<view class="info-row"><text>订单金额</text><text class="amount">¥{{ formatMoney(order.total_amount) }}</text></view>
|
||||
|
||||
@@ -1,5 +1,20 @@
|
||||
<template>
|
||||
<view class="container">
|
||||
<view class="page-navbar">
|
||||
<view class="navbar-back" @tap="goBack">
|
||||
<view class="back-chevron"></view>
|
||||
</view>
|
||||
<view class="navbar-title">我的订单</view>
|
||||
<view class="navbar-tools">
|
||||
<view class="navbar-search-icon"></view>
|
||||
<view class="navbar-filter-icon">
|
||||
<view class="filter-line filter-line-top"></view>
|
||||
<view class="filter-line filter-line-middle"></view>
|
||||
<view class="filter-line filter-line-bottom"></view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="filter-tabs">
|
||||
<view
|
||||
v-for="(item, index) in filterOptions"
|
||||
@@ -23,10 +38,12 @@
|
||||
<view v-else class="order-list">
|
||||
<view class="order-card" v-for="item in orderList" :key="item.order_id" @tap="openOrderDetail(item)">
|
||||
<view class="card-header">
|
||||
<view class="header-left">
|
||||
<view class="header-row">
|
||||
<text class="field-tag">订单号</text>
|
||||
<text class="order-no">{{ item.order_no }}</text>
|
||||
<view class="order-number" @tap.stop="copyOrderNo(item.order_no)">
|
||||
<text class="order-label">订单号:</text>
|
||||
<text class="order-no">{{ item.order_no || '-' }}</text>
|
||||
<view class="copy-icon">
|
||||
<view class="copy-back"></view>
|
||||
<view class="copy-front"></view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="status-badge" :class="getStatusClass(item.payment_status)">
|
||||
@@ -35,32 +52,27 @@
|
||||
</view>
|
||||
|
||||
<view class="card-body">
|
||||
<view class="info-grid">
|
||||
<view class="info-item">
|
||||
<view class="info-label">套餐名称:</view>
|
||||
<view class="info-value">{{ getPackageNamesText(item) }}</view>
|
||||
</view>
|
||||
<view class="info-item">
|
||||
<view class="info-label">资产标识:</view>
|
||||
<view class="info-value">{{ item.asset_identifier || '-' }}</view>
|
||||
</view>
|
||||
<view class="info-item">
|
||||
<view class="info-label">订单金额:</view>
|
||||
<view class="info-value amount">¥{{ formatMoney(item.total_amount) }}</view>
|
||||
</view>
|
||||
<view class="info-item">
|
||||
<view class="info-label">下单时间:</view>
|
||||
<view class="info-value">{{ item.created_at }}</view>
|
||||
<view class="package-row">
|
||||
<view class="package-content">
|
||||
<view class="package-name">{{ getPackageNamesText(item) }}</view>
|
||||
</view>
|
||||
<view class="order-amount">¥{{ formatMoney(item.total_amount) }}</view>
|
||||
</view>
|
||||
|
||||
<view class="card-footer">
|
||||
<button v-if="item.payment_status === 1" class="btn-pay" :disabled="orderPayingId !== null"
|
||||
@tap.stop="showOrderPaymentMethods(item)">
|
||||
{{ isOrderPaying(item) ? '处理中...' : '立即支付' }}
|
||||
</button>
|
||||
<up-button class="btn-renew" type="primary" size="small"
|
||||
:disabled="orderPayingId !== null" @tap.stop="startOrderRenewal(item)">立即续费</up-button>
|
||||
<view class="card-divider"></view>
|
||||
|
||||
<view class="card-footer">
|
||||
<view class="created-time">下单时间:{{ item.created_at || '-' }}</view>
|
||||
<view class="order-actions">
|
||||
<button class="order-action-button detail-action-button"
|
||||
@tap.stop="openOrderDetail(item)">查看详情</button>
|
||||
<button v-if="item.payment_status === 1" class="order-action-button primary-action-button"
|
||||
@tap.stop="showOrderPaymentMethods(item)">
|
||||
立即支付
|
||||
</button>
|
||||
<button v-if="item.payment_status !== 1" class="order-action-button primary-action-button"
|
||||
@tap.stop="startOrderRenewal(item)">立即续费</button>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
@@ -79,23 +91,16 @@
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { ref, reactive, onMounted, computed } from 'vue';
|
||||
import { ref, reactive, onMounted } from 'vue';
|
||||
import { onShow } from '@dcloudio/uni-app';
|
||||
import { assetApi, orderApi } from '@/api/index.js';
|
||||
import { orderApi } from '@/api/index.js';
|
||||
import RenewalPaymentPopup from '@/components/RenewalPaymentPopup.vue';
|
||||
import { useUserStore } from '@/store/index.js';
|
||||
import {
|
||||
consumePendingPaymentRefresh,
|
||||
handlePaymentError,
|
||||
isValidAlipayPaymentLink,
|
||||
isValidWechatPayConfig,
|
||||
openAlipayPayment,
|
||||
PAYMENT_REFRESH_TARGETS,
|
||||
showPaymentToast,
|
||||
wechatH5Pay
|
||||
PAYMENT_REFRESH_TARGETS
|
||||
} from '@/utils/payment.js';
|
||||
import { formatMoney } from '@/utils/display.js';
|
||||
import { getPaymentMethodOptions, normalizePaymentMethods } from '@/utils/payment-methods.js';
|
||||
|
||||
const userStore = useUserStore();
|
||||
|
||||
@@ -103,13 +108,9 @@
|
||||
const loading = ref(false);
|
||||
const noMore = ref(false);
|
||||
const page = ref(1);
|
||||
const orderPayingId = ref(null);
|
||||
const renewalPopupRef = ref(null);
|
||||
const pageSize = 10;
|
||||
const filterIndex = ref(0);
|
||||
const allowedPaymentMethods = ref([]);
|
||||
let assetTypePromise = null;
|
||||
const paymentMethodOptions = computed(() => getPaymentMethodOptions(allowedPaymentMethods.value));
|
||||
const filterOptions = [
|
||||
{ label: '全部', value: null },
|
||||
{ label: '待支付', value: 1 },
|
||||
@@ -128,24 +129,6 @@
|
||||
return classMap[status] || '';
|
||||
};
|
||||
|
||||
const loadAssetType = async () => {
|
||||
if (!userStore.state.identifier) return;
|
||||
if (assetTypePromise) return assetTypePromise;
|
||||
|
||||
assetTypePromise = assetApi.getInfo(userStore.state.identifier)
|
||||
.then((data) => {
|
||||
allowedPaymentMethods.value = normalizePaymentMethods(data.allowed_payment_methods);
|
||||
})
|
||||
.catch((error) => {
|
||||
console.error('加载资产类型失败', error);
|
||||
})
|
||||
.finally(() => {
|
||||
assetTypePromise = null;
|
||||
});
|
||||
|
||||
return assetTypePromise;
|
||||
};
|
||||
|
||||
const resetOrderListAndLoad = () => {
|
||||
page.value = 1;
|
||||
noMore.value = false;
|
||||
@@ -187,7 +170,6 @@
|
||||
|
||||
const newData = (data.items || []).map((item) => ({
|
||||
...item,
|
||||
asset_identifier: item.asset_identifier || item.virtual_no || item.VirtualNo || item.imei || '',
|
||||
payment_status_name: item.payment_status === 1
|
||||
? '待支付'
|
||||
: item.payment_status === 2
|
||||
@@ -224,8 +206,6 @@
|
||||
}
|
||||
};
|
||||
|
||||
const isOrderPaying = (order) => orderPayingId.value === order.order_id;
|
||||
|
||||
const getPackageNamesText = (order) => {
|
||||
const packageNames = Array.isArray(order?.package_names)
|
||||
? order.package_names.filter(Boolean)
|
||||
@@ -233,8 +213,25 @@
|
||||
return packageNames.join('、') || '-';
|
||||
};
|
||||
|
||||
const copyOrderNo = (orderNo) => {
|
||||
if (!orderNo) return;
|
||||
uni.setClipboardData({
|
||||
data: String(orderNo),
|
||||
success: () => uni.showToast({ title: '订单号已复制', icon: 'success' })
|
||||
});
|
||||
};
|
||||
|
||||
const goBack = () => {
|
||||
const pages = getCurrentPages();
|
||||
if (pages.length > 1) {
|
||||
uni.navigateBack();
|
||||
return;
|
||||
}
|
||||
uni.reLaunch({ url: '/pages/index/index' });
|
||||
};
|
||||
|
||||
const openOrderDetail = (order) => {
|
||||
if (!order?.order_id || orderPayingId.value !== null) return;
|
||||
if (!order?.order_id) return;
|
||||
uni.navigateTo({ url: `/pages/order-detail/order-detail?id=${order.order_id}` });
|
||||
};
|
||||
|
||||
@@ -248,98 +245,10 @@
|
||||
renewalPopupRef.value?.open(packageIds, packageNames);
|
||||
};
|
||||
|
||||
const showOrderPaymentMethods = async (order) => {
|
||||
if (orderPayingId.value !== null || !order?.order_id) return;
|
||||
await loadAssetType();
|
||||
const options = paymentMethodOptions.value;
|
||||
if (!options.length) {
|
||||
uni.showToast({ title: '暂无可用支付方式', icon: 'none' });
|
||||
return;
|
||||
}
|
||||
|
||||
uni.showActionSheet({
|
||||
itemList: options.map((item) => item.label),
|
||||
success: ({ tapIndex }) => {
|
||||
const selectedMethod = options[tapIndex]?.value;
|
||||
if (selectedMethod) {
|
||||
handleOrderPayment(order, selectedMethod);
|
||||
}
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
const handleOrderPayment = async (order, paymentMethod) => {
|
||||
if (orderPayingId.value !== null || !order?.order_id) return;
|
||||
|
||||
orderPayingId.value = order.order_id;
|
||||
uni.showLoading({
|
||||
title: '处理中...',
|
||||
mask: true
|
||||
});
|
||||
|
||||
try {
|
||||
const payData = await orderApi.pay(order.order_id, paymentMethod);
|
||||
uni.hideLoading();
|
||||
|
||||
if (paymentMethod === 'wallet') {
|
||||
await confirmOrderStatus(order);
|
||||
setTimeout(() => {
|
||||
resetOrderListAndLoad();
|
||||
}, 1500);
|
||||
return;
|
||||
}
|
||||
|
||||
if (paymentMethod === 'wechat') {
|
||||
if (!isValidWechatPayConfig(payData?.pay_config)) {
|
||||
uni.showToast({
|
||||
title: '支付参数获取失败',
|
||||
icon: 'none'
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
try {
|
||||
await wechatH5Pay(payData.pay_config);
|
||||
await confirmOrderStatus(order);
|
||||
setTimeout(() => {
|
||||
resetOrderListAndLoad();
|
||||
}, 1500);
|
||||
} catch (error) {
|
||||
handlePaymentError(error);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
if (!isValidAlipayPaymentLink(payData?.payment_link)) {
|
||||
uni.showToast({
|
||||
title: '支付链接获取失败',
|
||||
icon: 'none'
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
await openAlipayPayment(payData.payment_link, PAYMENT_REFRESH_TARGETS.ORDER_LIST);
|
||||
} catch (error) {
|
||||
uni.hideLoading();
|
||||
console.error('订单支付失败', error);
|
||||
uni.showToast({
|
||||
title: error.msg || error.message || '支付失败,请稍后重试',
|
||||
icon: 'none'
|
||||
});
|
||||
} finally {
|
||||
orderPayingId.value = null;
|
||||
}
|
||||
};
|
||||
|
||||
const confirmOrderStatus = async (order) => {
|
||||
try {
|
||||
const detail = await orderApi.getDetail(order.order_id);
|
||||
const status = detail?.payment_status ?? detail?.order?.payment_status;
|
||||
showPaymentToast(status === 2, status === 2 ? '支付成功' : '支付结果确认中');
|
||||
} catch (error) {
|
||||
console.error('确认订单支付状态失败', error);
|
||||
showPaymentToast(false, '支付结果确认失败,请稍后查看订单');
|
||||
}
|
||||
const showOrderPaymentMethods = (order) => {
|
||||
if (!order?.order_id) return;
|
||||
const packageNames = Array.isArray(order.package_names) ? order.package_names : [];
|
||||
renewalPopupRef.value?.openOrderPayment(order.order_id, packageNames);
|
||||
};
|
||||
|
||||
onShow(() => {
|
||||
@@ -351,7 +260,6 @@
|
||||
});
|
||||
|
||||
onMounted(() => {
|
||||
loadAssetType();
|
||||
loadOrderList();
|
||||
});
|
||||
</script>
|
||||
@@ -525,35 +433,24 @@
|
||||
padding-top: 24rpx;
|
||||
border-top: 1rpx solid #f0f0f0;
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
flex-direction: column;
|
||||
gap: 16rpx;
|
||||
|
||||
.btn-pay {
|
||||
background: #1890ff;
|
||||
color: #fff;
|
||||
border: none;
|
||||
border-radius: 20rpx;
|
||||
height: 64rpx;
|
||||
padding: 0 28rpx;
|
||||
font-size: 26rpx;
|
||||
font-weight: 500;
|
||||
width: auto;
|
||||
min-width: 168rpx;
|
||||
line-height: 64rpx;
|
||||
|
||||
&[disabled] {
|
||||
opacity: 0.7;
|
||||
}
|
||||
|
||||
&::after {
|
||||
border: none;
|
||||
}
|
||||
}
|
||||
|
||||
.btn-renew {
|
||||
flex: 1;
|
||||
.order-action-button {
|
||||
width: 100%;
|
||||
min-width: 0;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.payment-action-buttons {
|
||||
display: flex;
|
||||
width: 100%;
|
||||
gap: 16rpx;
|
||||
|
||||
.order-action-button {
|
||||
flex: 1;
|
||||
width: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -592,4 +489,330 @@
|
||||
color: #999;
|
||||
font-size: 24rpx;
|
||||
}
|
||||
|
||||
/* Screenshot-aligned order list skin */
|
||||
.container {
|
||||
top: 0;
|
||||
background: #f8f9fb;
|
||||
padding-top: var(--status-bar-height, 0px);
|
||||
}
|
||||
|
||||
.page-navbar {
|
||||
position: relative;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
flex-shrink: 0;
|
||||
height: 88rpx;
|
||||
padding: 0 32rpx;
|
||||
background: #fff;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.navbar-back,
|
||||
.navbar-tools {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.navbar-back {
|
||||
width: 64rpx;
|
||||
height: 64rpx;
|
||||
justify-content: flex-start;
|
||||
}
|
||||
|
||||
.back-chevron {
|
||||
width: 24rpx;
|
||||
height: 24rpx;
|
||||
margin-left: 8rpx;
|
||||
border-left: 5rpx solid #111;
|
||||
border-bottom: 5rpx solid #111;
|
||||
transform: rotate(45deg);
|
||||
}
|
||||
|
||||
.navbar-title {
|
||||
position: absolute;
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
color: #111;
|
||||
font-size: 36rpx;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.navbar-tools {
|
||||
gap: 36rpx;
|
||||
margin-left: auto;
|
||||
}
|
||||
|
||||
.navbar-search-icon {
|
||||
position: relative;
|
||||
width: 32rpx;
|
||||
height: 32rpx;
|
||||
border: 4rpx solid #111;
|
||||
border-radius: 50%;
|
||||
box-sizing: border-box;
|
||||
|
||||
&::after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
right: -13rpx;
|
||||
bottom: -9rpx;
|
||||
width: 14rpx;
|
||||
height: 4rpx;
|
||||
background: #111;
|
||||
border-radius: 4rpx;
|
||||
transform: rotate(45deg);
|
||||
}
|
||||
}
|
||||
|
||||
.navbar-filter-icon {
|
||||
position: relative;
|
||||
width: 34rpx;
|
||||
height: 34rpx;
|
||||
}
|
||||
|
||||
.filter-line {
|
||||
position: absolute;
|
||||
left: 50%;
|
||||
height: 4rpx;
|
||||
width: 34rpx;
|
||||
background: #111;
|
||||
border-radius: 4rpx;
|
||||
transform: translateX(-50%);
|
||||
|
||||
&::after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
top: -5rpx;
|
||||
width: 14rpx;
|
||||
height: 14rpx;
|
||||
border: 4rpx solid #111;
|
||||
border-radius: 50%;
|
||||
background: #fff;
|
||||
}
|
||||
}
|
||||
|
||||
.filter-line-top { top: 7rpx; &::after { left: 6rpx; } }
|
||||
.filter-line-middle { top: 16rpx; &::after { right: 5rpx; } }
|
||||
.filter-line-bottom { top: 25rpx; &::after { left: 6rpx; } }
|
||||
|
||||
.filter-tabs {
|
||||
display: flex;
|
||||
align-items: stretch;
|
||||
flex-shrink: 0;
|
||||
margin-top: 0;
|
||||
padding: 0 20rpx;
|
||||
background: #fff;
|
||||
border-radius: 0;
|
||||
border-bottom: 1rpx solid #f0f1f3;
|
||||
box-shadow: none;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.filter-tabs .tab-item {
|
||||
position: relative;
|
||||
flex: 1;
|
||||
min-width: 128rpx;
|
||||
padding: 28rpx 12rpx 24rpx;
|
||||
color: #777b84;
|
||||
font-size: 28rpx;
|
||||
text-align: center;
|
||||
white-space: nowrap;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.filter-tabs .tab-item.active {
|
||||
color: #18a765;
|
||||
font-size: 28rpx;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.filter-tabs .tab-line {
|
||||
bottom: 0;
|
||||
width: 42rpx;
|
||||
height: 6rpx;
|
||||
background: #18a765;
|
||||
border-radius: 8rpx;
|
||||
}
|
||||
|
||||
.scroll-container {
|
||||
min-height: 0;
|
||||
}
|
||||
|
||||
.order-list {
|
||||
padding: 20rpx 24rpx 48rpx;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.order-card {
|
||||
margin-bottom: 20rpx;
|
||||
padding: 0 32rpx;
|
||||
background: #fff;
|
||||
border: 1rpx solid #f0f1f3;
|
||||
border-radius: 18rpx;
|
||||
box-shadow: 0 6rpx 18rpx rgba(31, 35, 41, 0.04);
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.order-card .card-header {
|
||||
align-items: center;
|
||||
padding: 32rpx 0 24rpx;
|
||||
border-bottom: 0;
|
||||
}
|
||||
|
||||
.order-number {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
min-width: 0;
|
||||
color: #777b84;
|
||||
font-size: 26rpx;
|
||||
}
|
||||
|
||||
.order-label { flex-shrink: 0; }
|
||||
|
||||
.order-no {
|
||||
max-width: 410rpx;
|
||||
overflow: hidden;
|
||||
color: #777b84;
|
||||
font-size: 26rpx;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.copy-icon {
|
||||
position: relative;
|
||||
width: 30rpx;
|
||||
height: 30rpx;
|
||||
margin-left: 14rpx;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.copy-back,
|
||||
.copy-front {
|
||||
position: absolute;
|
||||
width: 15rpx;
|
||||
height: 15rpx;
|
||||
border: 3rpx solid #717782;
|
||||
border-radius: 4rpx;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.copy-back { top: 3rpx; left: 3rpx; }
|
||||
.copy-front { right: 2rpx; bottom: 2rpx; background: #fff; }
|
||||
|
||||
.order-card .card-body {
|
||||
padding: 0 0 28rpx;
|
||||
}
|
||||
|
||||
.package-row {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
min-width: 0;
|
||||
gap: 20rpx;
|
||||
}
|
||||
|
||||
.package-content {
|
||||
min-width: 0;
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
.package-name {
|
||||
color: #16181c;
|
||||
font-size: 30rpx;
|
||||
font-weight: 600;
|
||||
line-height: 1.25;
|
||||
word-break: break-all;
|
||||
}
|
||||
|
||||
.order-amount {
|
||||
align-self: center;
|
||||
color: #ff302f;
|
||||
font-size: 30rpx;
|
||||
font-weight: 600;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.card-divider {
|
||||
height: 1rpx;
|
||||
margin: 28rpx 0 20rpx;
|
||||
background: #edf0f2;
|
||||
}
|
||||
|
||||
.order-card .card-footer {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
gap: 16rpx;
|
||||
margin-top: 0;
|
||||
padding: 0 0 28rpx;
|
||||
border-top: 0;
|
||||
flex-direction: row;
|
||||
}
|
||||
|
||||
.created-time {
|
||||
min-width: 0;
|
||||
color: #777b84;
|
||||
font-size: 24rpx;
|
||||
line-height: 1.3;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.order-actions {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 16rpx;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.order-card .order-action-button {
|
||||
width: 180rpx;
|
||||
height: 58rpx;
|
||||
min-width: 0;
|
||||
margin: 0;
|
||||
padding: 0 16rpx;
|
||||
border: 1rpx solid transparent;
|
||||
border-radius: 12rpx;
|
||||
font-size: 25rpx;
|
||||
font-weight: 500;
|
||||
line-height: 56rpx;
|
||||
box-sizing: border-box;
|
||||
white-space: nowrap;
|
||||
-webkit-tap-highlight-color: transparent;
|
||||
|
||||
&::after { border: none; }
|
||||
}
|
||||
|
||||
.detail-action-button {
|
||||
border-color: #d9dde2;
|
||||
background: #fff;
|
||||
color: #17191c;
|
||||
}
|
||||
|
||||
.primary-action-button {
|
||||
border-color: #16ad63;
|
||||
background: #16ad63;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.order-card .status-badge {
|
||||
padding: 0 0 0 16rpx;
|
||||
background: transparent;
|
||||
border-radius: 0;
|
||||
font-size: 25rpx;
|
||||
font-weight: 500;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.order-card .status-badge.tag-warning { color: #f08a00; }
|
||||
.order-card .status-badge.tag-success { color: #147de2; }
|
||||
.order-card .status-badge.tag-secondary { color: #7d828b; }
|
||||
.order-card .status-badge.tag-info { color: #666d78; }
|
||||
|
||||
.load-more {
|
||||
padding: 24rpx 32rpx 40rpx;
|
||||
color: #9aa0aa;
|
||||
font-size: 23rpx;
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
</view>
|
||||
<view class="package-main">
|
||||
<view class="data-block">
|
||||
<view class="data-label">可用流量</view>
|
||||
<view class="data-label">套餐流量</view>
|
||||
<view class="package-data">{{ formatData(item.data_allowance, item.data_unit) }}</view>
|
||||
</view>
|
||||
<view class="price-block">
|
||||
@@ -36,7 +36,6 @@
|
||||
<text class="package-price">{{ formatPackagePrice(item.retail_price) }}</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="package-desc" v-if="item.description">{{ item.description }}</view>
|
||||
<view class="package-footer">
|
||||
<view class="btn">
|
||||
<up-button type="primary" size="small" @click="buyPackage(item)">立即订购</up-button>
|
||||
@@ -56,7 +55,7 @@
|
||||
<view class="summary-price">¥{{ formatPackagePrice(currentPackage?.retail_price) }}</view>
|
||||
<view class="summary-details">
|
||||
<view class="detail-item">
|
||||
<text class="detail-label">可用流量</text>
|
||||
<text class="detail-label">套餐流量</text>
|
||||
<text class="detail-value">{{ formatData(currentPackage?.data_allowance, currentPackage?.data_unit) }}</text>
|
||||
</view>
|
||||
<view class="detail-divider"></view>
|
||||
@@ -672,13 +671,6 @@
|
||||
}
|
||||
}
|
||||
|
||||
.package-desc {
|
||||
font-size: 24rpx;
|
||||
color: var(--text-secondary);
|
||||
line-height: 1.5;
|
||||
margin-bottom: 22rpx;
|
||||
}
|
||||
|
||||
.package-footer {
|
||||
display: block;
|
||||
padding-top: 22rpx;
|
||||
|
||||
Reference in New Issue
Block a user