fix: formulario solicitud profesional - botón enviar no respondía
- Eliminado Flutter Form widget, validación manual por campo - submitForReview() en provider sin depender de formKey - Errores inline visibles (cédula obligatoria, profesión obligatoria) - Loading spinner en el botón mientras envía - try/catch con snackbar de error si falla la API - Orden de campos: foto cédula, profesión, RETHUS (opcional), especializaciones (opcional) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Sonnet 4.6
parent
aa2fde187a
commit
f433bb2f6e
@@ -72,6 +72,11 @@ class ProfessionalFormProvider with ChangeNotifier {
|
||||
return true;
|
||||
}
|
||||
|
||||
Future<void> submitForReview() async {
|
||||
await _api.patch('/professionals/me', profesional!.toDocument());
|
||||
NotificationsService.showSnackbar('Solicitud enviada a revisión');
|
||||
}
|
||||
|
||||
Future<bool> updateProfesionalProfileInfo(String userId) async {
|
||||
if (!_validProfileForm()) return false;
|
||||
await _api.patch('/professionals/me', profesional!.toDocument());
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user