feat(apply): 入驻只收基本信息并新增启动页、材料后补与改服务城市

入驻表单移除身份证与证件材料(服务城市单选下拉,默认北京),只填姓名/手机/性别/城市/简介即可提交;新增 pages/launch 启动页先解析身份再跳转,无身份直接进申请页不再闪现首页;新增 pages/materials 证件材料补传页;个人资料页支持在职陪诊师修改服务城市;appId 更名为 wxapp_companion。
This commit is contained in:
lik
2026-11-10 16:34:00 +08:00
parent 5848d181a6
commit ff1b1664fa
20 changed files with 738 additions and 176 deletions
+36
View File
@@ -0,0 +1,36 @@
// pages/launch/index.js
// 启动页:冷启动先解析身份再决定去首页还是入驻申请页,
// 避免默认首页先渲染一帧再被全局守卫重定向。
const role = require('../../utils/role.js')
Page({
data: {
error: ''
},
onShow() {
this.enter()
},
enter() {
this.setData({ error: '' })
role
.ensureRoleSafe(true)
.then((detail) => {
if (!detail.ok) {
this.setData({ error: '网络异常,请重试' })
return
}
if (detail.role === 'none') {
wx.reLaunch({ url: '/pages/apply/index' })
return
}
wx.switchTab({ url: '/pages/home/index' })
})
.catch(() => this.setData({ error: '网络异常,请重试' }))
},
onRetry() {
this.enter()
}
})
+4
View File
@@ -0,0 +1,4 @@
{
"navigationStyle": "custom",
"usingComponents": {}
}
+50
View File
@@ -0,0 +1,50 @@
/* pages/launch/index.less */
page {
background-color: #FAF6F1;
}
.launch-page {
min-height: 100vh;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
background: #FAF6F1;
}
.launch-brand {
display: flex;
flex-direction: column;
align-items: center;
}
.launch-title {
font-size: 44rpx;
font-weight: 700;
color: #C26A2E;
}
.launch-sub {
margin-top: 12rpx;
font-size: 26rpx;
color: #9C9188;
}
.launch-tip {
margin-top: 48rpx;
font-size: 24rpx;
color: #B5AAA0;
}
.launch-error {
margin-top: 48rpx;
font-size: 26rpx;
color: #C26A2E;
}
.launch-retry {
margin-top: 24rpx;
border-radius: 40rpx;
background: #C26A2E;
color: #fff;
}
+13
View File
@@ -0,0 +1,13 @@
<!--pages/launch/index.wxml-->
<view class="launch-page">
<view class="launch-brand">
<text class="launch-title">暖橙陪诊</text>
<text class="launch-sub">陪诊师工作台</text>
</view>
<block wx:if="{{error}}">
<text class="launch-error">{{error}}</text>
<button class="launch-retry" size="mini" bindtap="onRetry">重试</button>
</block>
<text wx:else class="launch-tip">正在进入…</text>
</view>