aamir_dev
Aamir 11 months ago
parent 2fcc2792a3
commit 803ade0b9d

@ -33,25 +33,21 @@ class _CompleteProfilePageState extends State<CompleteProfilePage> {
confirmPassword = "";
late String password = "";
bool isChecked = false;
late UserVM userVM;
DropValue? city;
DropValue? gender;
@override
void initState() {
userVM = Provider.of<UserVM>(context, listen: false);
getcities();
super.initState();
}
getcities() async {
print("Country ID = " + AppState().getUserRegisterCountrySelection.id.toString());
await userVM.getAllCitiesForUser(AppState().getUserRegisterCountrySelection.id);
}
@override
Widget build(BuildContext context) {
return Consumer(builder: (BuildContext context, UserVM userVM, Widget? child) {
print("Country ID = " + AppState().getUserRegisterCountrySelection.id.toString());
userVM.getAllCitiesForUser(AppState().getUserRegisterCountrySelection.id);
return Scaffold(
appBar: CustomAppBar(
isRemoveBackButton: widget.user.data!.roleId == 7 ? false : true,
@ -271,4 +267,6 @@ class _CompleteProfilePageState extends State<CompleteProfilePage> {
),
);
}
);
}
}

@ -1,3 +1,4 @@
import 'package:mc_common_app/classes/app_state.dart';
import 'package:mc_common_app/extensions/int_extensions.dart';
import 'package:mc_common_app/extensions/string_extensions.dart';
import 'package:mc_common_app/generated/locale_keys.g.dart';
@ -78,8 +79,9 @@ class _RegisterPageState extends State<RegisterCustomerPage> {
DropdownField(
dropdownValue: selectedDrop,
(DropValue value) {
print("========");
selectedDrop = value;
AppState().setUserRegisterCountrySelection = value;
setState(() {
countryCode = value.subValue;
countryId = value.id;

Loading…
Cancel
Save