| @@ -12,7 +12,7 @@ class Account { | |||
| String lastName; | |||
| String midleName; | |||
| String fullName; | |||
| String telephone; | |||
| String phone; | |||
| String address; | |||
| String avartar; | |||
| num vaiTroId; | |||
| @@ -14,7 +14,7 @@ Account _$AccountFromJson(Map<String, dynamic> json) { | |||
| ..lastName = json['lastName'] as String | |||
| ..midleName = json['midleName'] as String | |||
| ..fullName = json['fullName'] as String | |||
| ..telephone = json['telephone'] as String | |||
| ..phone = json['phone'] as String | |||
| ..address = json['address'] as String | |||
| ..avartar = json['avartar'] as String | |||
| ..vaiTroId = json['vaiTroId'] as num | |||
| @@ -42,7 +42,7 @@ Map<String, dynamic> _$AccountToJson(Account instance) => <String, dynamic>{ | |||
| 'lastName': instance.lastName, | |||
| 'midleName': instance.midleName, | |||
| 'fullName': instance.fullName, | |||
| 'telephone': instance.telephone, | |||
| 'phone': instance.phone, | |||
| 'address': instance.address, | |||
| 'avartar': instance.avartar, | |||
| 'vaiTroId': instance.vaiTroId, | |||
| @@ -83,6 +83,10 @@ class _UpdateProfileScreenState extends State<UpdateProfileScreen> { | |||
| _validateInputs() async { | |||
| if (_formKey.currentState.validate()) { | |||
| _formKey.currentState.save(); | |||
| _account.countryId = checkChangeLocation.currentCountry.id; | |||
| _account.cityId = checkChangeLocation.currentProvince.id; | |||
| _account.districtId = checkChangeLocation.currentDistrict.id; | |||
| _account.wardId = checkChangeLocation.currentWard.id; | |||
| LoadingDialog.showLoadingDialog(_scaffoldKey.currentContext); | |||
| _repository.updateProfile(_account).then((value) { | |||
| LoadingDialog.hideLoadingDialog(_scaffoldKey.currentContext); | |||