重构项目文件夹目录
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
Page({
|
||||
data: { form: { oldPassword: '', newPassword: '', confirmPassword: '' } },
|
||||
onInput(event) { this.setData({ [`form.${event.currentTarget.dataset.field}`]: event.detail.value }) },
|
||||
save() {
|
||||
if (this.data.form.newPassword !== this.data.form.confirmPassword) {
|
||||
wx.showToast({ title: '两次密码不一致', icon: 'none' })
|
||||
return
|
||||
}
|
||||
wx.showToast({ title: '已提交' })
|
||||
},
|
||||
back() { wx.navigateBack() }
|
||||
})
|
||||
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"navigationBarTitleText": "修改密码"
|
||||
}
|
||||
@@ -0,0 +1,8 @@
|
||||
<view class="page no-tab">
|
||||
<view class="card form-card">
|
||||
<view class="field"><text class="field-label">原密码</text><input password value="{{form.oldPassword}}" data-field="oldPassword" bindinput="onInput" /></view>
|
||||
<view class="field"><text class="field-label">新密码</text><input password value="{{form.newPassword}}" data-field="newPassword" bindinput="onInput" /></view>
|
||||
<view class="field"><text class="field-label">确认密码</text><input password value="{{form.confirmPassword}}" data-field="confirmPassword" bindinput="onInput" /></view>
|
||||
</view>
|
||||
<view class="fixed-bottom"><button class="primary-btn" bindtap="save">保存密码</button></view>
|
||||
</view>
|
||||
@@ -0,0 +1 @@
|
||||
|
||||
Reference in New Issue
Block a user