fix: Add providers to bulk edit routes

This commit is contained in:
Anton Stubenbord
2023-05-12 13:00:56 +02:00
parent 72f61c7866
commit 2fad76c697
6 changed files with 188 additions and 156 deletions

View File

@@ -109,13 +109,16 @@ class HomeRoute extends StatelessWidget {
providers: [
ProxyProvider3<PaperlessDocumentsApi, DocumentChangedNotifier, LabelRepository,
DocumentsCubit>(
update: (context, docApi, notifier, labelRepo, previous) => DocumentsCubit(
docApi,
notifier,
labelRepo,
Hive.box<LocalUserAppState>(HiveBoxes.localUserAppState)
.get(currentLocalUserId)!,
)..reload(),
update: (context, docApi, notifier, labelRepo, previous) {
print("UPDATED DOCUMENT CUBIT"); //TODO: REMOVE
return DocumentsCubit(
docApi,
notifier,
labelRepo,
Hive.box<LocalUserAppState>(HiveBoxes.localUserAppState)
.get(currentLocalUserId)!,
)..reload();
},
),
Provider(create: (context) => DocumentScannerCubit()),
ProxyProvider4<PaperlessDocumentsApi, PaperlessServerStatsApi, LabelRepository,