feat: actions and map page
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:rasadyar_core/core.dart';
|
||||
|
||||
import 'logic.dart';
|
||||
|
||||
class RootPage extends GetView<RootLogic> {
|
||||
@@ -7,14 +8,39 @@ class RootPage extends GetView<RootLogic> {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
body: ObxValue((data) {
|
||||
return IndexedStack(
|
||||
return ObxValue((currentIndex) {
|
||||
return Scaffold(
|
||||
body: IndexedStack(
|
||||
children: controller.pages,
|
||||
index: data.value,
|
||||
index: currentIndex.value,
|
||||
sizing: StackFit.expand,
|
||||
);
|
||||
}, controller.indexedPage),
|
||||
);
|
||||
),
|
||||
|
||||
bottomNavigationBar: BottomNavigation1(
|
||||
items: [
|
||||
BottomNavigation1Item(
|
||||
icon: Assets.vec.filterSvg.path,
|
||||
label: 'درخواستها',
|
||||
isSelected: currentIndex.value == 0,
|
||||
onTap: () => controller.changePage(0),
|
||||
),
|
||||
|
||||
BottomNavigation1Item(
|
||||
icon: Assets.vec.mapSvg.path,
|
||||
label: 'نقشه',
|
||||
isSelected: currentIndex.value == 1,
|
||||
onTap: () => controller.changePage(1),
|
||||
),
|
||||
|
||||
BottomNavigation1Item(
|
||||
icon: Assets.vec.profileUserSvg.path,
|
||||
label: 'پروفایل',
|
||||
isSelected: currentIndex.value == 2,
|
||||
onTap: () => controller.changePage(2),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}, controller.currentIndex);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user