feat: 完善协议管理、师傅资质认证、分账配置并完成测试环境全量部署与同步

这个提交包含在:
2026-11-12 17:19:49 +08:00
父节点 fafddceaf2
当前提交 72cea8445f
共有 179 个文件被更改,包括 29242 次插入 和 3340 次删除

文件差异内容过多而无法显示 加载差异

查看文件

@@ -205,29 +205,11 @@
</view>
</view>
</YjyfRefreshScroll>
<!-- 协议阅读弹窗(内容完全取自后端真实接口) -->
<view class="agr-mask" v-if="agrDialog.visible" @tap="agrDialog.visible = false">
<view class="agr-box" @tap.stop>
<view class="agr-hd">
<text class="agr-title">{{ agrDialog.title }}</text>
<view class="agr-close clickable-hover" @tap="agrDialog.visible = false">
<image class="agr-close-ico" src="/static/icons/close.svg" mode="aspectFit" />
</view>
</view>
<scroll-view class="agr-scroll" scroll-y="true">
<text class="agr-content">{{ agrDialog.content }}</text>
</scroll-view>
<view class="agr-ft">
<view class="agr-btn clickable-hover" @tap="agrDialog.visible = false">我知道了</view>
</view>
</view>
</view>
</view>
</template>
<script setup>
import { ref, reactive, computed, onMounted } from 'vue';
import { ref, computed, onMounted } from 'vue';
import YjyfNavBar from '@/components/YjyfNavBar.vue';
import YjyfRefreshScroll from '@/components/YjyfRefreshScroll.vue';
import api from '@/utils/api.js';
@@ -250,11 +232,6 @@
});
const currentRole = ref('user');
const servicePhone = ref('');
const agrDialog = reactive({
visible: false,
title: '',
content: ''
});
const orderNavItems = computed(() => {
const c = orderCounts.value || {};
@@ -344,33 +321,24 @@
}
function openAgreementPicker() {
const items = isMerchantAccount.value
? [
{ label: '用户服务协议', type: 'user_service' },
{ label: '隐私保护指引', type: 'privacy' },
{ label: '企业商家协同服务协议', type: 'merchant' }
]
: [
{ label: '用户服务协议', type: 'user_service' },
{ label: '隐私保护指引', type: 'privacy' }
];
const items = [
{ label: '用户服务协议', type: 'user_service' },
{ label: '隐私保护指引', type: 'privacy' }
];
if (isMerchantAccount.value) {
items.push({ label: '企业商家协同服务协议', type: 'merchant' });
}
if (master.value) {
items.push({ label: '师傅入驻与履约服务协议', type: 'master' });
}
uni.showActionSheet({
itemList: items.map(i => i.label),
success: async (res) => {
success: (res) => {
const picked = items[res.tapIndex];
if (!picked) return;
try {
uni.showLoading({ title: '加载中...' });
const data = await api.agreement(picked.type, { silent: false });
uni.hideLoading();
if (data && data.content) {
agrDialog.title = data.title || picked.label;
agrDialog.content = data.content;
agrDialog.visible = true;
}
} catch (e) {
uni.hideLoading();
}
uni.navigateTo({
url: `/pages/agreement/detail?type=${encodeURIComponent(picked.type)}&title=${encodeURIComponent(picked.label)}`
});
}
});
}
@@ -947,87 +915,6 @@
font-weight: 500;
}
/* ---------- 协议与规则阅读弹窗 ---------- */
.agr-mask {
position: fixed;
left: 0;
right: 0;
top: 0;
bottom: 0;
z-index: 999;
background: rgba(0, 0, 0, 0.5);
display: flex;
align-items: center;
justify-content: center;
padding: 0 48rpx;
}
.agr-box {
width: 100%;
max-height: 76vh;
background: #FFFFFF;
border-radius: 24rpx;
display: flex;
flex-direction: column;
overflow: hidden;
}
.agr-hd {
display: flex;
align-items: center;
justify-content: space-between;
padding: 28rpx 32rpx 20rpx;
border-bottom: 1rpx solid #F0F0F2;
}
.agr-title {
font-size: 30rpx;
font-weight: 700;
color: #1F1F1F;
}
.agr-close {
width: 48rpx;
height: 48rpx;
display: flex;
align-items: center;
justify-content: center;
}
.agr-close-ico {
width: 28rpx;
height: 28rpx;
}
.agr-scroll {
max-height: 48vh;
padding: 24rpx 32rpx;
box-sizing: border-box;
}
.agr-content {
font-size: 26rpx;
color: #444444;
line-height: 1.7;
white-space: pre-wrap;
}
.agr-ft {
padding: 20rpx 32rpx 28rpx;
}
.agr-btn {
height: 80rpx;
border-radius: 40rpx;
background: linear-gradient(135deg, #FFA93F 0%, #F0710D 100%);
color: #FFFFFF;
font-size: 28rpx;
font-weight: 600;
display: flex;
align-items: center;
justify-content: center;
}
/* ---------- 点击反馈与无障碍 ---------- */
.clickable-hover {
transition: opacity 0.15s ease, transform 0.15s ease;

查看文件

@@ -268,6 +268,7 @@
<script setup>
import { ref, onMounted } from 'vue';
import api from '@/utils/api.js';
import { executeOrderWxPay } from '@/utils/pay.js';
import { isLogin, toLogin } from '@/utils/request.js';
import { getNavBarMetrics } from '@/utils/system.js';
import YjyfNavBar from '@/components/YjyfNavBar.vue';
@@ -513,10 +514,13 @@
if (!o || actingOrderId.value) return;
actingOrderId.value = o.id;
try {
await api.orderPay({ order_id: o.id, pay_type: 'mock' });
await executeOrderWxPay(api.orderPay, { order_id: o.id });
uni.showToast({ title: '支付成功', icon: 'success' });
await load();
} catch (e) {
if (e && e.code === undefined && !e.handledToast && !e.unsupportedEnv && e.message) {
uni.showToast({ title: e.message, icon: 'none' });
}
} finally {
actingOrderId.value = 0;
}