2025-08-15 11:14:42 +08:00
|
|
|
<view class="page">
|
|
|
|
|
|
|
|
<!-- 顶部 Logo 与标题 -->
|
|
|
|
<image class="logo" src="/static/logo.jpg" mode="aspectFit" />
|
|
|
|
<text class="page-title">欢迎登录 — 丁香校园</text>
|
|
|
|
|
|
|
|
<!-- 注册卡片 -->
|
|
|
|
<view class="card">
|
|
|
|
|
|
|
|
<view class="card-head">
|
|
|
|
<text class="card-title">账号注册</text>
|
|
|
|
</view>
|
|
|
|
|
|
|
|
<!-- 表单 -->
|
|
|
|
<view class="form">
|
|
|
|
|
|
|
|
<!-- 昵称 -->
|
|
|
|
<view class="field">
|
|
|
|
<input
|
|
|
|
class="field-input"
|
|
|
|
placeholder="{{ placeholder }}"
|
|
|
|
placeholder-class="ph"
|
|
|
|
maxlength="18"
|
|
|
|
bindinput="onInput" data-field="nickname" value="{{nickname}}"
|
|
|
|
/>
|
|
|
|
</view>
|
|
|
|
|
|
|
|
<!-- 手机号 -->
|
|
|
|
<view class="field">
|
|
|
|
<input
|
|
|
|
class="field-input"
|
|
|
|
placeholder="请输入手机号"
|
|
|
|
placeholder-class="ph"
|
|
|
|
maxlength="11"
|
|
|
|
type="number"
|
|
|
|
bindinput="onInput" data-field="phone" value="{{phone}}"
|
|
|
|
/>
|
|
|
|
</view>
|
|
|
|
|
|
|
|
<!-- 验证码(输入 + 发送) -->
|
|
|
|
<view class="field field-row">
|
|
|
|
<input
|
|
|
|
class="field-input flex-1"
|
|
|
|
placeholder="请输入验证码"
|
|
|
|
placeholder-class="ph"
|
|
|
|
maxlength="6"
|
|
|
|
bindinput="onInput" data-field="captcha" value="{{captcha}}"
|
|
|
|
/>
|
|
|
|
<view
|
|
|
|
bindtap="{{sending ? '' : 'sendSmsCode'}}"
|
|
|
|
class="code-btn {{sending ? 'disabled' : ''}}"
|
|
|
|
>
|
|
|
|
<text class="code-btn-text">{{ sending ? count + 's后重发' : '发送验证码' }}
|
|
|
|
</text>
|
2025-05-17 23:17:14 +08:00
|
|
|
</view>
|
|
|
|
</view>
|
2025-08-15 11:14:42 +08:00
|
|
|
|
|
|
|
<!-- 邀请码 -->
|
|
|
|
<view class="field">
|
|
|
|
<input
|
|
|
|
class="field-input"
|
|
|
|
placeholder="请输入邀请码"
|
|
|
|
placeholder-class="ph"
|
|
|
|
maxlength="6"
|
|
|
|
bindinput="onInput" data-field="inviteCode" value="{{inviteCode}}"
|
|
|
|
/>
|
|
|
|
</view>
|
|
|
|
|
|
|
|
<!-- 密码 -->
|
|
|
|
<view class="field">
|
|
|
|
<input
|
|
|
|
class="field-input"
|
|
|
|
placeholder="请输入密码"
|
|
|
|
placeholder-class="ph"
|
|
|
|
password="true"
|
|
|
|
maxlength="18"
|
|
|
|
bindinput="onInput" data-field="password" value="{{password}}"
|
|
|
|
/>
|
|
|
|
</view>
|
|
|
|
|
|
|
|
<!-- 协议勾选 -->
|
|
|
|
<view class="agreements">
|
2025-05-17 23:17:14 +08:00
|
|
|
<checkbox-group bindchange="onCheckboxChange">
|
|
|
|
<checkbox value="agree" checked="{{agree}}" color="#FF8D1A" />
|
|
|
|
</checkbox-group>
|
2025-08-15 11:14:42 +08:00
|
|
|
<view class="agreements-text">
|
|
|
|
<text class="muted">我已阅读并同意</text>
|
|
|
|
<text class="link" bind:tap="gotoAgreement">《用户协议》</text>
|
|
|
|
<text class="muted">&</text>
|
|
|
|
<text class="link" bind:tap="gotoPolicy">《隐私协议》</text>
|
2025-05-17 23:17:14 +08:00
|
|
|
</view>
|
|
|
|
</view>
|
2025-08-15 11:14:42 +08:00
|
|
|
|
|
|
|
<!-- 注册按钮 -->
|
|
|
|
<view class="btn-primary" bindtap="onRegister">
|
|
|
|
<text class="btn-primary-text">注册</text>
|
|
|
|
</view>
|
2025-05-17 23:17:14 +08:00
|
|
|
</view>
|
2025-08-15 11:14:42 +08:00
|
|
|
</view>
|
|
|
|
|
|
|
|
<!-- 登录引导 -->
|
|
|
|
<view class="footer-tip">
|
|
|
|
<text class="muted">已有账号?</text>
|
|
|
|
<text class="link-strong" bindtap="gotoLogin">立即登录 →</text>
|
|
|
|
</view>
|
|
|
|
|
|
|
|
</view>
|