fix : di for Role
This commit is contained in:
@@ -89,7 +89,7 @@ class ModulesLogic extends GetxController {
|
||||
selectedIndex.value = index;
|
||||
await Future.delayed(Duration(milliseconds: 300));
|
||||
selectedIndex.value = null;
|
||||
saveModule(module);
|
||||
// saveModule(module);
|
||||
await navigateToModule(module);
|
||||
}
|
||||
|
||||
@@ -98,14 +98,14 @@ class ModulesLogic extends GetxController {
|
||||
|
||||
if (target.value?[0] != null) {
|
||||
isLoading.value = !isLoading.value;
|
||||
await target.value?[0];
|
||||
await target.value?[0]?.call();
|
||||
isLoading.value = !isLoading.value;
|
||||
}
|
||||
|
||||
await Get.toNamed(target.key, arguments: module);
|
||||
|
||||
if (target.value?[1] != null) {
|
||||
await target.value?[1];
|
||||
await target.value?[1]?.call();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -87,26 +87,25 @@ class SplashLogic extends GetxController with GetTickerProviderStateMixin {
|
||||
children: [
|
||||
const Text('در حال دانلود بروزرسانی برنامه...'),
|
||||
Obx(
|
||||
() =>
|
||||
Row(
|
||||
spacing: 8,
|
||||
children: [
|
||||
Expanded(
|
||||
child: LinearProgressIndicator(
|
||||
value: percent.value,
|
||||
color: AppColor.greenNormal,
|
||||
minHeight: 4,
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
width: 55.w,
|
||||
child: Text(
|
||||
'${(percent.value * 100).toStringAsFixed(2)}%',
|
||||
textAlign: TextAlign.center,
|
||||
),
|
||||
),
|
||||
],
|
||||
() => Row(
|
||||
spacing: 8,
|
||||
children: [
|
||||
Expanded(
|
||||
child: LinearProgressIndicator(
|
||||
value: percent.value,
|
||||
color: AppColor.greenNormal,
|
||||
minHeight: 4,
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
width: 55.w,
|
||||
child: Text(
|
||||
'${(percent.value * 100).toStringAsFixed(2)}%',
|
||||
textAlign: TextAlign.center,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
|
||||
Row(
|
||||
@@ -119,9 +118,9 @@ class SplashLogic extends GetxController with GetTickerProviderStateMixin {
|
||||
height: 40.h,
|
||||
onPressed: data.value != null
|
||||
? () {
|
||||
installApk();
|
||||
Get.back();
|
||||
}
|
||||
installApk();
|
||||
Get.back();
|
||||
}
|
||||
: null,
|
||||
text: 'نصب',
|
||||
);
|
||||
@@ -163,10 +162,7 @@ class SplashLogic extends GetxController with GetTickerProviderStateMixin {
|
||||
await Future.wait(funs ?? []);
|
||||
|
||||
Get.offAndToNamed(target.route!);
|
||||
|
||||
}
|
||||
|
||||
|
||||
} catch (e, st) {
|
||||
debugPrint("onReady error: $e\n$st");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user