feat: C 端套餐沉默期展示与自助延期
All checks were successful
构建并部署前端到测试环境 / build-and-deploy (push) Successful in 23m46s

- 套餐历史展示沉默期状态、截止日期、累计延期与调整审批中,可延期时显示延期入口
- 新增延期页:资格、档位与自定义天数试算、支付方式、下单(request_id 幂等)
- 支付宝走现有支付页;微信为链接时在微信外直接跳转,否则展示二维码与复制链接
- 新增我的延期订单列表与详情、沉默期记录,沉默期错误码转客户提示
This commit is contained in:
邹进
2026-11-07 13:19:33 +09:00
parent b2f802e6f8
commit 31ff18d66a
15 changed files with 1500 additions and 22 deletions

View File

@@ -1,5 +1,8 @@
<template>
<view class="container">
<view class="history-toolbar">
<text class="silence-orders-link" role="button" tabindex="0" @tap="openSilenceOrders">我的延期订单</text>
</view>
<view v-if="!historyLoaded || (loading && packageList.length === 0)" class="loading-state">
<up-loading-icon text="加载中" size="30"></up-loading-icon>
</view>
@@ -27,6 +30,7 @@
<script setup>
import { ref, onMounted } from 'vue';
import { onShow } from '@dcloudio/uni-app';
import { assetApi } from '@/api/index.js';
import PackageHistoryNode from '@/components/PackageHistoryNode.vue';
import { useUserStore } from '@/store/index.js';
@@ -86,12 +90,39 @@
const loadMore = () => loadPackageList(true);
const SILENCE_COMPLETED_KEY = 'silence_extension_completed';
const openSilenceOrders = () => {
uni.navigateTo({ url: '/pages/silence-orders/silence-orders' });
};
onMounted(() => {
uni.removeStorageSync(SILENCE_COMPLETED_KEY);
loadPackageList();
});
// 延期成功后返回本页:重新加载第一页,展示新的沉默期截止日期
onShow(() => {
if (!uni.getStorageSync(SILENCE_COMPLETED_KEY)) return;
uni.removeStorageSync(SILENCE_COMPLETED_KEY);
page.value = 1;
noMore.value = false;
loadPackageList();
});
</script>
<style lang="scss" scoped>
.history-toolbar {
display: flex;
justify-content: flex-end;
margin-bottom: var(--space-sm);
}
.silence-orders-link {
padding: 8rpx 0;
font-size: 26rpx;
color: var(--primary-dark);
}
.loading-state {
display: flex;
align-items: center;