This commit is contained in:
2026-04-01 15:06:04 +08:00
parent 95fdfe6269
commit 9242dcaf70
3 changed files with 6 additions and 40 deletions

View File

@@ -140,29 +140,10 @@ class _LoginPageState extends State<LoginPage> with SingleTickerProviderStateMix
children: [
const SizedBox(height: 30),
// 根据 Tab 显示不同的输入框
!_isAgreed
? GestureDetector(
onTap: () => _handleLogin(controller),
behavior: HitTestBehavior.opaque,
child: Container(
width: double.infinity,
height: 55.h,
padding: const EdgeInsets.symmetric(
horizontal: 24,
),
alignment: Alignment.centerLeft,
child: Text(
"请先阅读并同意用户协议和隐私政策",
style: TextStyle(
color: Colors.grey,
fontSize: 16,
),
),
),
)
: (_tabController.index == 0
? _buildDriverInputFields(controller)
: _buildStationInputFields(controller)),
if (_isAgreed)
(_tabController.index == 0
? _buildDriverInputFields(controller)
: _buildStationInputFields(controller)),
const SizedBox(height: 30),
// 统一登录按钮
@@ -265,10 +246,12 @@ class _LoginPageState extends State<LoginPage> with SingleTickerProviderStateMix
child: TextField(
controller: controller.phoneController,
keyboardType: TextInputType.phone,
maxLength: 11,
decoration: const InputDecoration(
hintText: '请输入手机号',
border: InputBorder.none,
contentPadding: EdgeInsets.symmetric(horizontal: 24),
counterText: ""
),
),
),