feat: 新增首页、设备、数据、我的页面及底部 tabBar 导航
扩展应用结构,接入底部导航;完善个人信息页提交文案与校验代码风格。 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Sonnet 4.6
parent
83d909b95b
commit
b264205cf4
@@ -63,10 +63,22 @@ Page({
|
||||
const heightNum = parseFloat(height)
|
||||
const weightNum = parseFloat(weight)
|
||||
|
||||
if (!name) return wx.showToast({ title: '请填写姓名', icon: 'none' })
|
||||
if (!gender) return wx.showToast({ title: '请填写正确的身份证号', icon: 'none' })
|
||||
if (!height || isNaN(heightNum) || heightNum <= 0) return wx.showToast({ title: '请填写身高', icon: 'none' })
|
||||
if (!serverResult) return wx.showToast({ title: '请先验证姓名与身份证号', icon: 'none' })
|
||||
if (!name) {
|
||||
wx.showToast({ title: '请填写姓名', icon: 'none' })
|
||||
return
|
||||
}
|
||||
if (!gender) {
|
||||
wx.showToast({ title: '请填写正确的身份证号', icon: 'none' })
|
||||
return
|
||||
}
|
||||
if (!height || isNaN(heightNum) || heightNum <= 0) {
|
||||
wx.showToast({ title: '请填写身高', icon: 'none' })
|
||||
return
|
||||
}
|
||||
if (!serverResult) {
|
||||
wx.showToast({ title: '请先验证姓名与身份证号', icon: 'none' })
|
||||
return
|
||||
}
|
||||
|
||||
const parsed = parseIdCard(idCard)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user