diff --git a/lib/app/modules/detailRoute/views/detail_route_view.dart b/lib/app/modules/detailRoute/views/detail_route_view.dart index dab0aac2..04c4d546 100644 --- a/lib/app/modules/detailRoute/views/detail_route_view.dart +++ b/lib/app/modules/detailRoute/views/detail_route_view.dart @@ -115,6 +115,26 @@ class DetailRouteView extends GetView { // Cancel → stay return false; } + if (save == true) { + controller.saveChanges(); + controller.onEdit.value = false; + WidgetsBinding.instance.addPostFrameCallback((_) { + ScaffoldMessenger.of(context).showSnackBar( + SnackBar( + backgroundColor: tColors.secondaryBackgroundColor, + content: Text( + SentenceManager( + currentLanguage: AppSettings.selectedLanguage, + ).sentences + .taskUpdated, + style: TextStyle( + color: tColors.primaryTextColor, + ), + ), + ), + ); + }); + } // Yes (true) or No (false) → both allow popping the screen return true; }, @@ -385,3 +405,4 @@ class AttributeWidget extends StatelessWidget { } } } +