update
This commit is contained in:
parent
b6b7ab6e84
commit
3e6781a0bd
5 changed files with 17 additions and 6 deletions
6
.fvmrc
Normal file
6
.fvmrc
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
"flutter": "3.27.3",
|
||||
"runPubGetOnSdkChanges": true,
|
||||
"updateVscodeSettings": true,
|
||||
"updateGitIgnore": true
|
||||
}
|
||||
3
.gitignore
vendored
3
.gitignore
vendored
|
|
@ -43,3 +43,6 @@ app.*.map.json
|
|||
/android/app/debug
|
||||
/android/app/profile
|
||||
/android/app/release
|
||||
|
||||
# FVM Version Cache
|
||||
.fvm/
|
||||
3
.vscode/settings.json
vendored
Normal file
3
.vscode/settings.json
vendored
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
{
|
||||
"dart.flutterSdkPath": ".fvm/versions/3.27.3"
|
||||
}
|
||||
|
|
@ -1,6 +1,6 @@
|
|||
import 'package:flutter/material.dart';
|
||||
import 'package:pharmacy_mobile/auth/auth_gate.dart';
|
||||
// import 'package:pharmacy_mobile/pages/index_page.dart';
|
||||
// import 'package:pharmacy_mobile/auth/auth_gate.dart';
|
||||
import 'package:pharmacy_mobile/pages/index_page.dart';
|
||||
import 'package:pharmacy_mobile/pages/login_page.dart';
|
||||
import 'package:go_router/go_router.dart';
|
||||
import 'package:pharmacy_mobile/pages/main_page.dart';
|
||||
|
|
@ -26,15 +26,13 @@ Future<void> main() async {
|
|||
runApp(MyApp());
|
||||
}
|
||||
|
||||
final supabase = Supabase.instance.client;
|
||||
|
||||
final _router = GoRouter(
|
||||
initialLocation: '/',
|
||||
routes: [
|
||||
GoRoute(
|
||||
name: 'index', // Optional, add name to your routes. Allows you navigate by name instead of path
|
||||
path: '/',
|
||||
builder: (context, state) => AuthGate(),
|
||||
builder: (context, state) => IndexPage(),
|
||||
),
|
||||
GoRoute(
|
||||
name: 'login',
|
||||
|
|
@ -61,6 +59,7 @@ class MyApp extends StatelessWidget {
|
|||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return MaterialApp.router(
|
||||
debugShowCheckedModeBanner: false,
|
||||
// initialRoute: '/',
|
||||
// routes: {
|
||||
// '/': (context) => const IndexPage(),
|
||||
|
|
|
|||
|
|
@ -54,7 +54,7 @@ class MainPage extends StatelessWidget {
|
|||
const Gap(16),
|
||||
MenuWidget(
|
||||
icon: FontAwesomeIcons.squarePlus,
|
||||
text: 'Add Medicine',
|
||||
text: 'Add Generics',
|
||||
),
|
||||
TextButton(onPressed: () => {signOut()}, child: const Text('Logout'))
|
||||
],
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue