Merge branch 'dev' of github.com:VinistanSS/FCSC into dev

This commit is contained in:
venbaittech 2024-12-17 13:18:37 +05:30
commit 4e3280f8c4
6 changed files with 774 additions and 372 deletions

View File

@ -304,7 +304,6 @@ import '../presentation/Screens/auth_verification/otp_verification.dart';
import '../presentation/Screens/profilepage.dart'; import '../presentation/Screens/profilepage.dart';
import '../presentation/routes/auth_routes/login_route.dart'; import '../presentation/routes/auth_routes/login_route.dart';
import '../presentation/routes/bottom_bar_routes/tab_routes/home_route.dart'; import '../presentation/routes/bottom_bar_routes/tab_routes/home_route.dart';
import '../presentation/routes/drawer_routes/Drawer Items/edit_profile.dart';
import '../presentation/routes/drawer_routes/Drawer Items/feedback.dart'; import '../presentation/routes/drawer_routes/Drawer Items/feedback.dart';
import '../presentation/routes/drawer_routes/Drawer Items/manage_users.dart'; import '../presentation/routes/drawer_routes/Drawer Items/manage_users.dart';
@ -313,7 +312,7 @@ final GoRouter router = GoRouter(
GoRoute( GoRoute(
path: '/', path: '/',
//builder: (context, state) => LoginRoute(), //builder: (context, state) => LoginRoute(),
builder: (context, state) => LoginRoute(), builder: (context, state) => MyHomePage(),
), ),
GoRoute( GoRoute(
path: '/myhomepage', path: '/myhomepage',
@ -330,11 +329,10 @@ final GoRouter router = GoRouter(
), ),
), ),
GoRoute( GoRoute(
path: '/changepassword/:userId', path: '/changepassword',
builder: (context, state) { builder: (context, state) => Changepassword(
final userId = state.pathParameters['userId']!; userId: '',
return Changepassword(userId: userId); ),
},
), ),
GoRoute( GoRoute(
path: '/createNewPw/:userId/:email', path: '/createNewPw/:userId/:email',
@ -358,11 +356,10 @@ final GoRouter router = GoRouter(
builder: (context, state) => FeedbackForm(), builder: (context, state) => FeedbackForm(),
), ),
GoRoute( GoRoute(
path: '/profile/:userId', path: '/profile',
builder: (context, state) { builder: (context, state) => ProfileScreen(
final userId = state.pathParameters['userId']!; userId: '',
return ProfileScreen(userId: userId); ),
},
), ),
// GoRoute( // GoRoute(
// path: '/manageuser', // path: '/manageuser',
@ -372,13 +369,10 @@ final GoRouter router = GoRouter(
// return ManageUserRouter(title: title); // return ManageUserRouter(title: title);
// }, // },
// ), // ),
GoRoute(
path: '/editProfile',
builder: (context, state) => EditProfile(),
),
GoRoute( GoRoute(
path: '/manageuser', path: '/manageuser',
builder: (context, state) => ManageUserRouter(), builder: (context, state) => ManageUserRouter(),
), ),
], ],
); );

View File

@ -58,7 +58,7 @@ class _ResetPasswordScreenState extends State<Changepassword> {
//print('userDetails ->: $userData'); //print('userDetails ->: $userData');
if (userData['items'].isNotEmpty) { if (userData['items'].isNotEmpty) {
// Email exists; retrieve user ID // Email exists; retrieve user ID
// final userId = userData['items'][0]['id']; final userId = userData['items'][0]['id'];
// Proceed with OTP request // Proceed with OTP request
final otpResponse = await http.post( final otpResponse = await http.post(
@ -87,15 +87,17 @@ class _ResetPasswordScreenState extends State<Changepassword> {
); );
// Navigate to the Email Verification screen // Navigate to the Email Verification screen
context.go( Navigator.push(
'/mailverification', context,
extra: { MaterialPageRoute(
'email': email, builder: (context) => EmailVerificationScreen(
'userId': widget.userId, // Pass user ID to the next screen email: email,
'otp': otp, userId: widget.userId, // Pass user ID to the next screen
'otpId': otpId, otp: otp,
'sendVerificationCode': sendVerificationCode, otpId: otpId,
}, sendVerificationCode: sendVerificationCode,
),
),
); );
} else { } else {
final error = final error =
@ -130,12 +132,6 @@ class _ResetPasswordScreenState extends State<Changepassword> {
} }
} }
@override
void initState() {
super.initState();
print(widget.userId);
}
@override @override
void dispose() { void dispose() {
_emailController.dispose(); _emailController.dispose();

View File

@ -275,7 +275,7 @@ class _RegisterScreenState extends State<RegisterScreen> {
buildIconContainer(Icons.report, Color(0xFF7DAFBC)), buildIconContainer(Icons.report, Color(0xFF7DAFBC)),
SizedBox(height: 20), SizedBox(height: 20),
Text( Text(
"Your registration is pending for verification", "Your registration is pending for Admin Approval.",
textAlign: TextAlign.center, textAlign: TextAlign.center,
style: TextStyle( style: TextStyle(
fontSize: 16, fontSize: 16,
@ -284,7 +284,7 @@ class _RegisterScreenState extends State<RegisterScreen> {
), ),
SizedBox(height: 10), SizedBox(height: 10),
Text( Text(
"Kindly verify your mail to proceed further.", "Access will be granted once your account is approved.",
textAlign: TextAlign.center, textAlign: TextAlign.center,
style: TextStyle( style: TextStyle(
fontSize: 14, fontSize: 14,
@ -293,11 +293,14 @@ class _RegisterScreenState extends State<RegisterScreen> {
), ),
SizedBox(height: 10), SizedBox(height: 10),
ElevatedButton( ElevatedButton(
onPressed: () { onPressed: () => {
Navigator.pushReplacement( Navigator.pushReplacement(
context, context,
MaterialPageRoute(builder: (context) => LoginRoute()), MaterialPageRoute(builder: (context) => LoginRoute()
);
//ProfileScreen(userId: userID)
),
),
}, },
child: Text( child: Text(
'Go to Login', 'Go to Login',
@ -452,8 +455,8 @@ class _RegisterScreenState extends State<RegisterScreen> {
suffixIcon: IconButton( suffixIcon: IconButton(
icon: Icon( icon: Icon(
_obscurePassword _obscurePassword
? Icons.visibility_off ? Icons.visibility
: Icons.visibility, : Icons.visibility_off,
color: Colors.blue, color: Colors.blue,
), ),
onPressed: () { onPressed: () {
@ -484,8 +487,8 @@ class _RegisterScreenState extends State<RegisterScreen> {
suffixIcon: IconButton( suffixIcon: IconButton(
icon: Icon( icon: Icon(
_obscureConfirmPassword _obscureConfirmPassword
? Icons.visibility_off ? Icons.visibility
: Icons.visibility, : Icons.visibility_off,
color: Colors.blue, color: Colors.blue,
), ),
onPressed: () { onPressed: () {

View File

@ -306,7 +306,7 @@ class _ProfileScreenState extends State<ProfileScreen> {
leading: IconButton( leading: IconButton(
icon: Icon(Icons.arrow_back_ios_new, color: Colors.black), icon: Icon(Icons.arrow_back_ios_new, color: Colors.black),
onPressed: () { onPressed: () {
print("Back Button"); context.go('/myhomepage');
}, },
), ),
title: Text( title: Text(

File diff suppressed because it is too large Load Diff

View File

@ -414,10 +414,10 @@ packages:
dependency: "direct dev" dependency: "direct dev"
description: description:
name: flutter_launcher_icons name: flutter_launcher_icons
sha256: "619817c4b65b322b5104b6bb6dfe6cda62d9729bd7ad4303ecc8b4e690a67a77" sha256: "31cd0885738e87c72d6f055564d37fabcdacee743b396b78c7636c169cac64f5"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "0.14.1" version: "0.14.2"
flutter_lints: flutter_lints:
dependency: "direct dev" dependency: "direct dev"
description: description:
@ -573,10 +573,10 @@ packages:
dependency: "direct main" dependency: "direct main"
description: description:
name: go_router name: go_router
sha256: "8660b74171fafae4aa8202100fa2e55349e078281dadc73a241eb8e758534d9d" sha256: "2fd11229f59e23e967b0775df8d5948a519cd7e1e8b6e849729e010587b46539"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "14.6.1" version: "14.6.2"
graphs: graphs:
dependency: transitive dependency: transitive
description: description:
@ -733,10 +733,10 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: io name: io
sha256: "2ec25704aba361659e10e3e5f5d672068d332fc8ac516421d483a11e5cbd061e" sha256: dfd5a80599cf0165756e3181807ed3e77daf6dd4137caaad72d0b7931597650b
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "1.0.4" version: "1.0.5"
js: js:
dependency: transitive dependency: transitive
description: description:
@ -821,10 +821,10 @@ packages:
dependency: "direct main" dependency: "direct main"
description: description:
name: mailer name: mailer
sha256: "21fde1497c79f402cb5fa7c50abd58927d360139e492546c941ee10767684fac" sha256: e907087cd00719898c493f720dd326af73b00b406ab4af8e79f15d7c5fc24035
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "6.2.0" version: "6.3.0"
marquee: marquee:
dependency: "direct main" dependency: "direct main"
description: description:
@ -861,10 +861,10 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: mime name: mime
sha256: "801fd0b26f14a4a58ccb09d5892c3fbdeff209594300a542492cf13fba9d247a" sha256: "41a20518f0cb1256669420fdba0cd90d21561e560ac240f26ef8322e45bb7ed6"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "1.0.6" version: "2.0.0"
nested: nested:
dependency: transitive dependency: transitive
description: description:
@ -877,10 +877,10 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: package_config name: package_config
sha256: "1c5b77ccc91e4823a5af61ee74e6b972db1ef98c2ff5a18d3161c982a55448bd" sha256: "92d4488434b520a62570293fbd33bb556c7d49230791c1b4bbd973baf6d2dc67"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "2.1.0" version: "2.1.1"
path: path:
dependency: transitive dependency: transitive
description: description:
@ -901,18 +901,18 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: path_provider_android name: path_provider_android
sha256: "8c4967f8b7cb46dc914e178daa29813d83ae502e0529d7b0478330616a691ef7" sha256: "4adf4fd5423ec60a29506c76581bc05854c55e3a0b72d35bb28d661c9686edf2"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "2.2.14" version: "2.2.15"
path_provider_foundation: path_provider_foundation:
dependency: transitive dependency: transitive
description: description:
name: path_provider_foundation name: path_provider_foundation
sha256: f234384a3fdd67f989b4d54a5d73ca2a6c422fa55ae694381ae0f4375cd1ea16 sha256: "4843174df4d288f5e29185bd6e72a6fbdf5a4a4602717eed565497429f179942"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "2.4.0" version: "2.4.1"
path_provider_linux: path_provider_linux:
dependency: transitive dependency: transitive
description: description:
@ -989,10 +989,10 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: pub_semver name: pub_semver
sha256: "40d3ab1bbd474c4c2328c91e3a7df8c6dd629b79ece4c4bd04bee496a224fb0c" sha256: "7b3cfbf654f3edd0c6298ecd5be782ce997ddf0e00531b9464b55245185bbbbd"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "2.1.4" version: "2.1.5"
pubspec_parse: pubspec_parse:
dependency: transitive dependency: transitive
description: description:
@ -1100,10 +1100,10 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: shared_preferences_android name: shared_preferences_android
sha256: "3b9febd815c9ca29c9e3520d50ec32f49157711e143b7a4ca039eb87e8ade5ab" sha256: "7f172d1b06de5da47b6264c2692ee2ead20bbbc246690427cdb4fc301cd0c549"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "2.3.3" version: "2.3.4"
shared_preferences_foundation: shared_preferences_foundation:
dependency: transitive dependency: transitive
description: description:
@ -1272,10 +1272,10 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: timing name: timing
sha256: "70a3b636575d4163c477e6de42f247a23b315ae20e86442bebe32d3cabf61c32" sha256: "62ee18aca144e4a9f29d212f5a4c6a053be252b895ab14b5821996cff4ed90fe"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "1.0.1" version: "1.0.2"
typed_data: typed_data:
dependency: transitive dependency: transitive
description: description:
@ -1360,10 +1360,10 @@ packages:
dependency: transitive dependency: transitive
description: description:
name: video_player_avfoundation name: video_player_avfoundation
sha256: "0b146e5d82e886ff43e5a46c6bcbe390761b802864a6e2503eb612d69a405dfa" sha256: "33224c19775fd244be2d6e3dbd8e1826ab162877bd61123bf71890772119a2b7"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "2.6.3" version: "2.6.5"
video_player_platform_interface: video_player_platform_interface:
dependency: transitive dependency: transitive
description: description: