feat : live stock module
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
|
import 'package:flutter/material.dart';
|
||||||
import 'package:rasadyar_core/core.dart';
|
import 'package:rasadyar_core/core.dart';
|
||||||
|
|
||||||
|
|
||||||
class ActionLogic extends GetxController with GetTickerProviderStateMixin {
|
class ActionLogic extends GetxController with GetTickerProviderStateMixin {
|
||||||
late Rx<SlidableController> slidController;
|
late Rx<SlidableController> slidController;
|
||||||
bool showSlideHint = true;
|
bool showSlideHint = true;
|
||||||
@@ -15,11 +15,11 @@ class ActionLogic extends GetxController with GetTickerProviderStateMixin {
|
|||||||
'خروج از سامانه',
|
'خروج از سامانه',
|
||||||
];
|
];
|
||||||
|
|
||||||
List<String> headersIcons = [
|
List<Widget> headersIcons = [
|
||||||
Assets.vecProfileUserSvg,
|
Assets.vec.profileUserSvg.svg(),
|
||||||
Assets.vecCalendarSearchSvg,
|
Assets.vec.calendarSearchSvg.svg(),
|
||||||
Assets.vecDiagramSvg,
|
Assets.vec.diagramSvg.svg(),
|
||||||
Assets.vecLogoutSvg,
|
Assets.vec.logoutSvg.svg(),
|
||||||
];
|
];
|
||||||
|
|
||||||
RxList<bool> supervisionHistoryList = [false, false, false, false].obs;
|
RxList<bool> supervisionHistoryList = [false, false, false, false].obs;
|
||||||
@@ -46,7 +46,6 @@ class ActionLogic extends GetxController with GetTickerProviderStateMixin {
|
|||||||
void onInit() {
|
void onInit() {
|
||||||
super.onInit();
|
super.onInit();
|
||||||
slidController = SlidableController(this).obs;
|
slidController = SlidableController(this).obs;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
@@ -69,9 +68,8 @@ class ActionLogic extends GetxController with GetTickerProviderStateMixin {
|
|||||||
showSlideHint = !showSlideHint;
|
showSlideHint = !showSlideHint;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void updateSelectedIndex(int index) {
|
void updateSelectedIndex(int index) {
|
||||||
if(index == selectedIndex.value) {
|
if (index == selectedIndex.value) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
previousIndex.value = selectedIndex.value;
|
previousIndex.value = selectedIndex.value;
|
||||||
|
|||||||
25
packages/livestock/lib/presentation/routes/app_pages.dart
Normal file
25
packages/livestock/lib/presentation/routes/app_pages.dart
Normal 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(() {
|
||||||
|
|
||||||
|
}),
|
||||||
|
),
|
||||||
|
|
||||||
|
|
||||||
|
];
|
||||||
|
}
|
||||||
|
|
||||||
@@ -0,0 +1,9 @@
|
|||||||
|
|
||||||
|
part of 'app_pages.dart';
|
||||||
|
|
||||||
|
sealed class LiveStockRoutes {
|
||||||
|
LiveStockRoutes._();
|
||||||
|
|
||||||
|
static const init = '/liveStockRoutesInit';
|
||||||
|
|
||||||
|
}
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
name: livestock
|
name: rasadyar_livestock
|
||||||
description: A starting point for Dart libraries or applications.
|
description: A starting point for Dart libraries or applications.
|
||||||
version: 1.0.0
|
version: 1.0.0
|
||||||
publish_to: 'none'
|
publish_to: 'none'
|
||||||
@@ -9,9 +9,12 @@ environment:
|
|||||||
|
|
||||||
|
|
||||||
dependencies:
|
dependencies:
|
||||||
|
flutter:
|
||||||
|
sdk: flutter
|
||||||
rasadyar_core:
|
rasadyar_core:
|
||||||
path: ../core
|
path: ../core
|
||||||
|
rasadyar_auth:
|
||||||
|
path: ../auth
|
||||||
##code generation
|
##code generation
|
||||||
freezed_annotation: ^3.0.0
|
freezed_annotation: ^3.0.0
|
||||||
json_annotation: ^4.9.0
|
json_annotation: ^4.9.0
|
||||||
@@ -31,7 +34,4 @@ dev_dependencies:
|
|||||||
mocktail: ^1.0.4
|
mocktail: ^1.0.4
|
||||||
get_test: ^4.0.1
|
get_test: ^4.0.1
|
||||||
|
|
||||||
flutter:
|
|
||||||
uses-material-design: true
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
import 'package:livestock/livestock.dart';
|
|
||||||
import 'package:test/test.dart';
|
|
||||||
|
|
||||||
void main() {
|
void main() {
|
||||||
|
|
||||||
|
|||||||
16
pubspec.yaml
16
pubspec.yaml
@@ -24,6 +24,9 @@ dependencies:
|
|||||||
rasadyar_auth:
|
rasadyar_auth:
|
||||||
path: ./packages/auth
|
path: ./packages/auth
|
||||||
|
|
||||||
|
rasadyar_livestock:
|
||||||
|
path: ./packages/livestock
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
##code generation
|
##code generation
|
||||||
@@ -38,6 +41,7 @@ dev_dependencies:
|
|||||||
hive_ce_generator: ^1.9.1
|
hive_ce_generator: ^1.9.1
|
||||||
freezed: ^3.0.6
|
freezed: ^3.0.6
|
||||||
json_serializable: ^6.9.4
|
json_serializable: ^6.9.4
|
||||||
|
flutter_gen_runner: ^5.10.0
|
||||||
|
|
||||||
##test
|
##test
|
||||||
mocktail: ^1.0.4
|
mocktail: ^1.0.4
|
||||||
@@ -56,7 +60,19 @@ flutter:
|
|||||||
- assets/logos/
|
- assets/logos/
|
||||||
- assets/vec/
|
- assets/vec/
|
||||||
|
|
||||||
|
|
||||||
fonts:
|
fonts:
|
||||||
- family: yekan
|
- family: yekan
|
||||||
fonts:
|
fonts:
|
||||||
- asset: fonts/iranyekanregularfanum.ttf
|
- 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
|
||||||
|
|||||||
Reference in New Issue
Block a user