feat : live stock module

This commit is contained in:
2025-05-19 16:17:01 +03:30
parent 905e407ccd
commit 7f72f2c70d
6 changed files with 63 additions and 16 deletions

View File

@@ -1,6 +1,6 @@
import 'package:flutter/material.dart';
import 'package:rasadyar_core/core.dart';
class ActionLogic extends GetxController with GetTickerProviderStateMixin {
late Rx<SlidableController> slidController;
bool showSlideHint = true;
@@ -15,11 +15,11 @@ class ActionLogic extends GetxController with GetTickerProviderStateMixin {
'خروج از سامانه',
];
List<String> headersIcons = [
Assets.vecProfileUserSvg,
Assets.vecCalendarSearchSvg,
Assets.vecDiagramSvg,
Assets.vecLogoutSvg,
List<Widget> headersIcons = [
Assets.vec.profileUserSvg.svg(),
Assets.vec.calendarSearchSvg.svg(),
Assets.vec.diagramSvg.svg(),
Assets.vec.logoutSvg.svg(),
];
RxList<bool> supervisionHistoryList = [false, false, false, false].obs;
@@ -46,7 +46,6 @@ class ActionLogic extends GetxController with GetTickerProviderStateMixin {
void onInit() {
super.onInit();
slidController = SlidableController(this).obs;
}
@override
@@ -69,9 +68,8 @@ class ActionLogic extends GetxController with GetTickerProviderStateMixin {
showSlideHint = !showSlideHint;
}
void updateSelectedIndex(int index) {
if(index == selectedIndex.value) {
if (index == selectedIndex.value) {
return;
}
previousIndex.value = selectedIndex.value;

View File

@@ -0,0 +1,25 @@
import 'package:rasadyar_auth/auth.dart';
import 'package:rasadyar_core/core.dart';
import 'package:rasadyar_livestock/presentation/page/root/view.dart';
part'app_routes.dart';
sealed class LiveStockPages {
LiveStockPages._();
static final pages = [
GetPage(
name: LiveStockRoutes.init,
page: () => RootPage(),
middlewares: [AuthMiddleware()],
binding: BindingsBuilder(() {
}),
),
];
}

View File

@@ -0,0 +1,9 @@
part of 'app_pages.dart';
sealed class LiveStockRoutes {
LiveStockRoutes._();
static const init = '/liveStockRoutesInit';
}

View File

@@ -1,4 +1,4 @@
name: livestock
name: rasadyar_livestock
description: A starting point for Dart libraries or applications.
version: 1.0.0
publish_to: 'none'
@@ -9,9 +9,12 @@ environment:
dependencies:
flutter:
sdk: flutter
rasadyar_core:
path: ../core
rasadyar_auth:
path: ../auth
##code generation
freezed_annotation: ^3.0.0
json_annotation: ^4.9.0
@@ -31,7 +34,4 @@ dev_dependencies:
mocktail: ^1.0.4
get_test: ^4.0.1
flutter:
uses-material-design: true

View File

@@ -1,5 +1,4 @@
import 'package:livestock/livestock.dart';
import 'package:test/test.dart';
void main() {

View File

@@ -24,6 +24,9 @@ dependencies:
rasadyar_auth:
path: ./packages/auth
rasadyar_livestock:
path: ./packages/livestock
##code generation
@@ -38,6 +41,7 @@ dev_dependencies:
hive_ce_generator: ^1.9.1
freezed: ^3.0.6
json_serializable: ^6.9.4
flutter_gen_runner: ^5.10.0
##test
mocktail: ^1.0.4
@@ -56,7 +60,19 @@ flutter:
- assets/logos/
- assets/vec/
fonts:
- family: yekan
fonts:
- asset: fonts/iranyekanregularfanum.ttf
flutter_gen:
output: packages/core/lib/presentation/common
line_length: 120
# Optional
integrations:
image: true
flutter_svg: true
rive: false
lottie: false