Cleaned up code, implemented message queue to notify subscribers of document updates.

This commit is contained in:
Anton Stubenbord
2023-02-06 01:04:13 +01:00
parent 337c178be8
commit 4d7fab1839
111 changed files with 1412 additions and 1029 deletions

View File

@@ -158,18 +158,16 @@ class _DocumentSearchPageState extends State<DocumentSearchPage> {
isLabelClickable: false,
isLoading: state.isLoading,
hasLoaded: state.hasLoaded,
onTap: (document) async {
final updatedDocument = await Navigator.pushNamed(
enableHeroAnimation: false,
onTap: (document) {
Navigator.pushNamed(
context,
DocumentDetailsRoute.routeName,
arguments: DocumentDetailsRouteArguments(
document: document,
isLabelClickable: false,
),
) as DocumentModel?;
if (updatedDocument != document) {
context.read<DocumentSearchCubit>().reload();
}
);
},
)
],