From d84fc9409b9117b5f92ba217164a8558e10ab585 Mon Sep 17 00:00:00 2001 From: hailin Date: Wed, 10 Dec 2025 08:30:52 -0800 Subject: [PATCH] fix(mobile): add 5s delay before confirm-province-city API call MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Backend requires 5 seconds wait time after selectProvinceCity before confirmProvinceCity can be called. Added delay to comply with this rule. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 --- .../presentation/pages/planting_location_page.dart | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/frontend/mobile-app/lib/features/planting/presentation/pages/planting_location_page.dart b/frontend/mobile-app/lib/features/planting/presentation/pages/planting_location_page.dart index d85cfbd4..706806be 100644 --- a/frontend/mobile-app/lib/features/planting/presentation/pages/planting_location_page.dart +++ b/frontend/mobile-app/lib/features/planting/presentation/pages/planting_location_page.dart @@ -132,10 +132,14 @@ class _PlantingLocationPageState extends ConsumerState { cityName: _selectedCityName!, ); - // 2. 确认省市选择 + // 2. 等待5秒后确认省市选择(后端要求等待5秒确认时间) + debugPrint('[PlantingLocationPage] 等待5秒确认时间...'); + await Future.delayed(const Duration(seconds: 5)); + + // 3. 确认省市选择 await plantingService.confirmProvinceCity(widget.orderNo); - // 3. 支付订单 + // 4. 支付订单 await plantingService.payOrder(widget.orderNo); if (mounted) {