fix : some di remove in module page
This commit is contained in:
@@ -26,7 +26,6 @@ sealed class AppPages {
|
||||
name: AppPaths.moduleList,
|
||||
page: () => ModulesPage(),
|
||||
binding: BindingsBuilder(() {
|
||||
|
||||
Get.lazyPut(() => SliderLogic(), tag: "up");
|
||||
Get.lazyPut(() => SliderLogic(), tag: "down");
|
||||
Get.put(ModulesLogic());
|
||||
@@ -58,14 +57,20 @@ Map<String, Future<void>?> getTargetModule(Module? value) {
|
||||
}
|
||||
}
|
||||
|
||||
Map<String, Future<void>?> getAuthTargetPage(Module? value) {
|
||||
Map<String, List<Future<void>?>?> getAuthTargetPage(Module? value) {
|
||||
switch (value) {
|
||||
case Module.inspection:
|
||||
return {InspectionRoutes.auth: setupInspectionDI()};
|
||||
return {
|
||||
InspectionRoutes.auth: [setupInspectionDI(), removeInspectionDI()],
|
||||
};
|
||||
case Module.liveStocks:
|
||||
return {LiveStockRoutes.auth: setupLiveStockDI()};
|
||||
return {
|
||||
LiveStockRoutes.auth: [setupLiveStockDI(), removeLiveStockDI()],
|
||||
};
|
||||
case Module.chicken:
|
||||
return {ChickenRoutes.auth: setupChickenDI()};
|
||||
return {
|
||||
ChickenRoutes.auth: [setupChickenDI(), removeChickenDI()],
|
||||
};
|
||||
default:
|
||||
return {AppPaths.moduleList: null};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user