register page updated

fix_authentication
Sultan Khan 4 years ago
parent b9b5797cbc
commit 0443a37886

@ -683,4 +683,5 @@ const Map<String, Map<String, String>> localizedValues = {
"Book": {"en": "Book", "ar": "احجز"},
"AppointmentLabel": {"en": "Appointment", "ar": "موعد"},
"BloodType": {"en": "Blood Type", "ar": "فصيلة الدم"},
"marital-status": {"en": "Marital status", "ar": "الحالة الإجتماعية"}
};

@ -6,6 +6,7 @@ import 'package:diplomaticquarterapp/models/Authentication/register_user_requet.
import 'package:diplomaticquarterapp/pages/login/login-type.dart';
import 'package:diplomaticquarterapp/services/authentication/auth_provider.dart';
import 'package:diplomaticquarterapp/uitl/app_shared_preferences.dart';
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
import 'package:diplomaticquarterapp/uitl/utils.dart';
import 'package:diplomaticquarterapp/widgets/buttons/defaultButton.dart';
@ -83,13 +84,29 @@ class _RegisterInfo extends State<RegisterInfo> {
top: 20, bottom: 20, left: 10, right: 10),
readOnly: true,
)),
AppText(TranslationBase.of(context).name),
AppText(TranslationBase.of(context).firstName),
Container(
margin: EdgeInsets.only(bottom: 10),
child: TextFields(
hintText: registerInfo.firstNameEn +
' ' +
registerInfo.lastNameEn,
hintText: registerInfo.firstNameEn,
padding: EdgeInsets.only(
top: 20, bottom: 20, left: 10, right: 10),
readOnly: true,
)),
AppText(TranslationBase.of(context).middleName),
Container(
margin: EdgeInsets.only(bottom: 10),
child: TextFields(
hintText: registerInfo.secondNameEn,
padding: EdgeInsets.only(
top: 20, bottom: 20, left: 10, right: 10),
readOnly: true,
)),
AppText(TranslationBase.of(context).lastName),
Container(
margin: EdgeInsets.only(bottom: 10),
child: TextFields(
hintText: registerInfo.lastNameEn,
padding: EdgeInsets.only(
top: 20, bottom: 20, left: 10, right: 10),
readOnly: true,
@ -107,6 +124,15 @@ class _RegisterInfo extends State<RegisterInfo> {
top: 20, bottom: 20, left: 10, right: 10),
readOnly: true,
)),
AppText(TranslationBase.of(context).maritalStatus),
Container(
margin: EdgeInsets.only(bottom: 10),
child: TextFields(
hintText: registerInfo.maritalStatus,
padding: EdgeInsets.only(
top: 20, bottom: 20, left: 10, right: 10),
readOnly: true,
)),
AppText(TranslationBase.of(context).nationality),
Container(
margin: EdgeInsets.only(bottom: 10),
@ -116,6 +142,15 @@ class _RegisterInfo extends State<RegisterInfo> {
top: 20, bottom: 20, left: 10, right: 10),
readOnly: true,
)),
AppText(TranslationBase.of(context).mobileNumber),
Container(
margin: EdgeInsets.only(bottom: 10),
child: TextFields(
hintText:registerd_data.patientMobileNumber,
padding: EdgeInsets.only(
top: 20, bottom: 20, left: 10, right: 10),
readOnly: true,
)),
AppText(TranslationBase.of(context).dob),
Container(
margin: EdgeInsets.only(bottom: 10),
@ -190,6 +225,7 @@ class _RegisterInfo extends State<RegisterInfo> {
child: TextFields(
onChanged: (value) {
this.email = value;
this.isValid();
},
padding: EdgeInsets.only(
top: 20, bottom: 20, left: 10, right: 10),
@ -211,7 +247,7 @@ class _RegisterInfo extends State<RegisterInfo> {
: TranslationBase.of(context).register,
() => {nextPage()},
textColor: Colors.white,
color: this.isValid() == false
color: this.isValid() == false && page == 2
? Colors.grey
: Colors.black,
))
@ -266,7 +302,8 @@ class _RegisterInfo extends State<RegisterInfo> {
"MiddleName": registerInfo.secondNameEn,
"LastName": registerInfo.lastNameEn,
"StrDateofBirth": registerInfo.dateOfBirth,
"DateofBirth": "/Date(1522098000000)/",
"DateofBirth":
DateUtil.convertISODateToJsonDate(registerInfo.dateOfBirth),
"Gender": registerInfo.gender,
"NationalityID": registerInfo.nationality,
"DateofBirthN": registerInfo.dateOfBirth,

@ -736,6 +736,8 @@ class TranslationBase {
String get loginToUseService =>
localizedValues['loginToUseService'][locale.languageCode];
String get maritalStatus =>
localizedValues['marital-status'][locale.languageCode];
}
class TranslationBaseDelegate extends LocalizationsDelegate<TranslationBase> {

Loading…
Cancel
Save