diff --git a/lib/Screens/userManagement/create_traveller_agent/personalDetailsTravelAgent.dart b/lib/Screens/userManagement/create_traveller_agent/personalDetailsTravelAgent.dart index 28a6e02..c7c9e09 100644 --- a/lib/Screens/userManagement/create_traveller_agent/personalDetailsTravelAgent.dart +++ b/lib/Screens/userManagement/create_traveller_agent/personalDetailsTravelAgent.dart @@ -557,7 +557,7 @@ class PersonalDetailsState extends State { case 'train': return Icons.train_outlined; case 'bus': - return Icons.bus_alert_outlined; + return Icons.directions_bus; case 'taxi': return Icons.local_taxi_outlined; case 'accomodation': diff --git a/lib/Screens/userManagement/create_user/create_user.dart b/lib/Screens/userManagement/create_user/create_user.dart index b3033fc..6465d1d 100644 --- a/lib/Screens/userManagement/create_user/create_user.dart +++ b/lib/Screens/userManagement/create_user/create_user.dart @@ -1604,6 +1604,7 @@ class _CreateUserFormDetialsState extends State { personalDetailsKey: personalDetailsKey, isDesktop: isDesktop, // pass isDesktop as a named argument isViewMode: isViewMode, + isEditProfile: isEditProfile, userIdApi: userIdApi, controllers: controllers, errorMessages: errorMessages, @@ -1706,6 +1707,7 @@ class _CreateUserFormDetialsState extends State { personalDetailsKey: personalDetailsKey, isDesktop: isDesktop, // pass isDesktop as a named argument isViewMode: isViewMode, + isEditProfile: isEditProfile, userIdApi: userIdApi, controllers: controllers, errorMessages: errorMessages, diff --git a/lib/Screens/userManagement/create_user/office_details.dart b/lib/Screens/userManagement/create_user/office_details.dart index c0271e5..e7ea1db 100644 --- a/lib/Screens/userManagement/create_user/office_details.dart +++ b/lib/Screens/userManagement/create_user/office_details.dart @@ -380,6 +380,7 @@ class OfficeDetailsState extends State { @override Widget build(BuildContext context) { return Container( + height: MediaQuery.of(context).size.height * 0.8, decoration: BoxDecoration( border: Border( top: BorderSide( diff --git a/lib/Screens/userManagement/create_user/personal_details.dart b/lib/Screens/userManagement/create_user/personal_details.dart index 2a19bc8..47e7ed6 100644 --- a/lib/Screens/userManagement/create_user/personal_details.dart +++ b/lib/Screens/userManagement/create_user/personal_details.dart @@ -22,6 +22,7 @@ class PersonalDetails extends StatefulWidget { final bool isDesktop; final bool isViewMode; final bool apiselectedUser; + final bool isEditProfile; final Function(List>)? onServiceIdsChanged; @@ -57,6 +58,7 @@ class PersonalDetails extends StatefulWidget { this.onRoleChanged, this.onUserTypeChanged, this.userIdApi, + required this.isEditProfile, }) : super(key: key); @override @@ -102,6 +104,7 @@ class PersonalDetailsState extends State { bool _countryFocus = false; bool _postalCodeFocus = false; bool _roleIdFocus = false; + bool iseditRole = true; late bool isTravelAgent = false; @@ -164,6 +167,10 @@ class PersonalDetailsState extends State { super.initState(); WidgetsBinding.instance.addPostFrameCallback((_) { loadInitialData(); + print("EDITP1- ${widget.isEditProfile}"); + print("EDITP2- ${widget.isViewMode}"); + + // iseditRole = ; }); apiCountryData = null; @@ -609,7 +616,7 @@ class PersonalDetailsState extends State { case 'train': return Icons.train_outlined; case 'bus': - return Icons.bus_alert_outlined; + return Icons.directions_bus; case 'taxi': return Icons.local_taxi_outlined; case 'accomodation': @@ -1827,7 +1834,7 @@ class PersonalDetailsState extends State { child: DropdownSearch( selectedItem: selectedRole != null ? roleMap[selectedRole] : null, - enabled: !widget.isViewMode, + enabled: !widget.isEditProfile, popupProps: PopupProps.menu( showSearchBox: true, fit: FlexFit.loose, @@ -1902,7 +1909,7 @@ class PersonalDetailsState extends State { ), ), onChanged: - widget.isViewMode + !widget.isEditProfile ? null : (String? newValue) { widget.errorMessages.remove("role_id"); diff --git a/lib/app.dart b/lib/app.dart index 8c9d363..7235458 100644 --- a/lib/app.dart +++ b/lib/app.dart @@ -2,7 +2,7 @@ import 'dart:convert'; import 'package:flutter/foundation.dart'; import 'package:flutter/material.dart'; -// import 'package:flutter/rendering.dart'; +import 'package:flutter/rendering.dart'; import 'dart:html' as html; import 'package:frontend/config/apiUrl.dart'; // 1 newly added import 'package:frontend/services/apiService.dart'; @@ -34,8 +34,8 @@ class _MyAppState extends State { @override void initState() { super.initState(); - // SemanticsBinding.instance - // .ensureSemantics(); // Safe here -only for testing uncomment, Otherwise Email Template wont allow to type + SemanticsBinding.instance + .ensureSemantics(); // -only for testing uncomment, Otherwise Email Template wont allow to type if (kIsWeb) { final uri = Uri.parse(html.window.location.href); print("URI - $uri");