|
|
|
@ -288,29 +288,10 @@ class EditInfoController extends GetxController { |
|
|
|
birthday.value = userData.value?.birthDate ?? ""; |
|
|
|
} |
|
|
|
|
|
|
|
goPreview() async { |
|
|
|
try { |
|
|
|
final response = await _userApi.getMarriageInformationDetailsById(miId: userData.value?.id ?? ""); |
|
|
|
if (response.data.isSuccess && response.data.data != null) { |
|
|
|
final data = response.data.data; |
|
|
|
|
|
|
|
|
|
|
|
Get.to(() => UserInformationPage( |
|
|
|
miId: userData.value?.id ?? "", |
|
|
|
userId: GlobalData().userId ?? "", |
|
|
|
)); |
|
|
|
} else { |
|
|
|
// 响应失败,抛出异常 |
|
|
|
throw Exception(response.data.message ?? '获取数据失败'); |
|
|
|
} |
|
|
|
} catch(e){ |
|
|
|
print('收入列表获取失败: $e'); |
|
|
|
SmartDialog.showToast('收入列表获取失败'); |
|
|
|
rethrow; |
|
|
|
} |
|
|
|
goPreview() { |
|
|
|
Get.to(() => UserInformationPage(miId: userData.value?.id ?? "", userId: GlobalData().userId ?? "")); |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
int calculateAge(String birthdayStr) { |
|
|
|
final birthday = DateTime.parse(birthdayStr); // 自动识别 1996-1-20 |
|
|
|
final today = DateTime.now(); |
|
|
|
|