refactor: chicken module for other role's

feat: steward Role
chore: add some rive file and library
This commit is contained in:
2025-09-02 14:40:55 +03:30
parent dfb9298097
commit 5ec772ee8a
49 changed files with 395 additions and 201 deletions

View File

@@ -1,8 +1,8 @@
import 'package:flutter/material.dart';
import 'package:rasadyar_chicken/presentation/pages/root/logic.dart';
import 'package:rasadyar_chicken/presentation/pages/steward/root/logic.dart';
import 'package:rasadyar_core/core.dart';
Widget inventoryWidget(RootLogic rootLogic) {
Widget inventoryWidget(StewardRootLogic rootLogic) {
return Container(
width: Get.width,
height: 39,

View File

@@ -1,11 +1,12 @@
import 'package:rasadyar_chicken/chicken.dart';
import 'package:rasadyar_chicken/presentation/pages/steward/root/logic.dart';
import 'package:rasadyar_core/core.dart';
enum WidelyUsedType { edit, normal }
class WidelyUsedLogic extends GetxController {
Rx<WidelyUsedType> type = WidelyUsedType.normal.obs;
RootLogic rootLogic = Get.find<RootLogic>();
StewardRootLogic rootLogic = Get.find<StewardRootLogic>();
@override

View File

@@ -60,7 +60,7 @@ class WidelyUsedWidget extends StatelessWidget {
controller.rootLogic.currentPage.value = 0;
controller.rootLogic.currentPage.refresh();
await Future.delayed(Duration(milliseconds: 100));
Get.toNamed(ChickenRoutes.buysOutOfProvince, id: 0);
Get.toNamed(ChickenRoutes.buysOutOfProvinceSteward, id: 0);
},
),
@@ -74,7 +74,7 @@ class WidelyUsedWidget extends StatelessWidget {
controller.rootLogic.currentPage.value = 0;
controller.rootLogic.currentPage.refresh();
await Future.delayed(Duration(milliseconds: 100));
Get.toNamed(ChickenRoutes.buysInProvince, id: 0);
Get.toNamed(ChickenRoutes.buysInProvinceSteward, id: 0);
},
isOnEdit: false,
),
@@ -87,7 +87,7 @@ class WidelyUsedWidget extends StatelessWidget {
controller.rootLogic.currentPage.value = 1;
controller.rootLogic.currentPage.refresh();
await Future.delayed(Duration(milliseconds: 100));
Get.toNamed(ChickenRoutes.salesOutOfProvince, id: 1);
Get.toNamed(ChickenRoutes.salesOutOfProvinceSteward, id: 1);
},
),
@@ -99,7 +99,7 @@ class WidelyUsedWidget extends StatelessWidget {
controller.rootLogic.currentPage.value = 1;
controller.rootLogic.currentPage.refresh();
await Future.delayed(Duration(milliseconds: 100));
Get.toNamed(ChickenRoutes.salesInProvince, id: 1);
Get.toNamed(ChickenRoutes.salesInProvinceSteward, id: 1);
},
),
],