Merge branch 'sultan_new_design' into 'development_new_design_2.0'

Sultan new design

See merge request Cloud_Solution/diplomatic-quarter!417
merge-update-with-lab-changes
Sultan khan 4 years ago
commit 23d11c2160

@ -178,7 +178,8 @@ class _NewHomeHealthCareStepThreePageState extends State<NewHomeHealthCareStepTh
context,
widget.model.orderId.toString(),
onClick: () {
Navigator.popUntil(context, (route) => Utils.route(route, equalsTo: HomeHealthCarePage));
Navigator.pop(context);
Navigator.push(context, FadePage(page: HomeHealthCarePage()));
},
);
}

@ -162,11 +162,15 @@ class _NewHomeHealthCarePageState extends State<NewHomeHealthCarePage> with Tick
TranslationBase.of(context).serviceName + ": ",
style: TextStyle(fontSize: 12, fontWeight: FontWeight.w600, color: Color(0xff575757), letterSpacing: -0.4, height: 16 / 10),
),
Column(
children: [
...List.generate(
widget.model.hhcAllOrderDetail.length,
(index) => Container(
child: Texts(
projectViewModel.isArabic ? widget.model.hhcAllOrderDetail[index].descriptionN : widget.model.hhcAllOrderDetail[index].description.capitalize(),
projectViewModel.isArabic
? widget.model.hhcAllOrderDetail[index].descriptionN
: widget.model.hhcAllOrderDetail[index].description.capitalize(),
fontSize: 13,
bold: false,
),
@ -175,6 +179,8 @@ class _NewHomeHealthCarePageState extends State<NewHomeHealthCarePage> with Tick
],
)
],
)
],
),
),
Column(

@ -121,7 +121,7 @@ class OrdersLogDetailsPage extends StatelessWidget {
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
TranslationBase.of(context).serviceName + ": ",
TranslationBase.of(context).hospital + ": ",
style: TextStyle(fontSize: 12, fontWeight: FontWeight.w600, color: Color(0xff575757), letterSpacing: -0.4, height: 16 / 10),
),
Expanded(

@ -51,6 +51,8 @@ class _AddMember extends State<AddMember> {
return AppScaffold(
appBarTitle: TranslationBase.of(context).myFamilyFiles,
isShowAppBar: true,
showNewAppBar: true,
showNewAppBarTitle: true,
body: isLoading == true
? AppCircularProgressIndicator()
: SingleChildScrollView(
@ -69,7 +71,7 @@ class _AddMember extends State<AddMember> {
Expanded(
flex: 4,
child: Column(
mainAxisAlignment: MainAxisAlignment.spaceEvenly,
// mainAxisAlignment: MainAxisAlignment.spaceEvenly,
children: <Widget>[
PhoneNumberSelectorWidget(onNumberChange: (value) => {mobileNo = value, validateForm()}, onCountryChange: (value) => countryCode = value),
//MobileNo(onNumberChange: (value) => {mobileNo = value, validateForm()}, onCountryChange: (value) => countryCode = value),
@ -88,24 +90,24 @@ class _AddMember extends State<AddMember> {
],
),
),
// Expanded(
// flex: 3,
// child: Column(
// mainAxisAlignment: MainAxisAlignment.end,
// children: <Widget>[
// Row(
// children: <Widget>[
// Expanded(
// child: DefaultButton(
// TranslationBase.of(context).add,
// () => {this.addMember()},
// color: isButtonDisabled == true ? Colors.grey : Colors.grey[900],
// textColor: Colors.white,
// ))
// ],
// ),
// ],
// ))
Expanded(
flex: 3,
child: Column(
mainAxisAlignment: MainAxisAlignment.end,
children: <Widget>[
Row(
children: <Widget>[
Expanded(
child: DefaultButton(
TranslationBase.of(context).add,
() => {this.addMember()},
color: isButtonDisabled == true ? Colors.grey : Colors.red[600],
textColor: Colors.white,
))
],
),
],
))
]),
)));
}

@ -6,6 +6,8 @@ import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
import 'package:diplomaticquarterapp/widgets/text/app_texts_widget.dart';
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:flutter_svg/svg.dart';
import 'package:diplomaticquarterapp/widgets/habib_logo_widget.dart';
class AddFamilyMemberType extends StatelessWidget {
static int loginType = 0;
@ -14,139 +16,204 @@ class AddFamilyMemberType extends StatelessWidget {
return AppScaffold(
appBarTitle: TranslationBase.of(context).myFamilyFiles,
isShowAppBar: true,
showNewAppBar: true,
showNewAppBarTitle: true,
body: Padding(
padding: EdgeInsets.all(20),
child: Column(
children: <Widget>[
Expanded(
flex: 6,
child: Column(
// mainAxisAlignment: MainAxisAlignment.spaceBetween,
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
Image.asset(
'assets/images/habib-logo.png',
height: 80,
width: 80,
),
Padding(
padding: EdgeInsets.all(20),
child: AppText(
TranslationBase.of(context).registerInfoFamily,
fontSize: SizeConfig.textMultiplier * 3.5,
textAlign: TextAlign.left,
),
),
Padding(
padding: EdgeInsets.all(20),
child: Row(
mainAxisAlignment: MainAxisAlignment.center,
children: <Widget>[
padding: EdgeInsets.only(bottom: 20, left: 21, right: 21),
child: Column(children: [
Expanded(
child: InkWell(
onTap: () => {
AddFamilyMemberType.loginType = 1,
Navigator.of(context)
.pushNamed(ADD_FAMILY_MEMBER)
},
child: RoundedContainer(
borderColor: Colors.grey,
showBorder: true,
child: Padding(
padding: EdgeInsets.fromLTRB(
20, 10, 20, 10),
child: Column(
mainAxisAlignment:
MainAxisAlignment.center,
children: <Widget>[
Image.asset(
'assets/images/id_card_icon.png',
height: SizeConfig
.imageSizeMultiplier *
12,
width: SizeConfig
.imageSizeMultiplier *
15,
),
SizedBox(
height: 20,
child: ListView(
padding: EdgeInsets.zero,
physics: BouncingScrollPhysics(),
children: [
SizedBox(height: 12),
HabibLogoWidget(),
SizedBox(height: 50),
Text(
TranslationBase.of(context).logintypeRadio,
style: TextStyle(fontSize: 16, fontWeight: FontWeight.w600, color: Color(0xff2B353E), letterSpacing: -0.64, height: 23 / 16),
),
AppText(
TranslationBase.of(context)
.idNo,
fontSize: SizeConfig
.textMultiplier *
2,
)
GridView(
gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(crossAxisCount: 2, crossAxisSpacing: 13, mainAxisSpacing: 9),
physics: NeverScrollableScrollPhysics(),
padding: EdgeInsets.only(top: 25),
shrinkWrap: true,
children: [
getButton(context, TranslationBase.of(context).nationalIdNumber, 'assets/images/new/national_id.svg', 1),
getButton(context, TranslationBase.of(context).medicalFileNumber, 'assets/images/new/medical_file.svg', 2),
],
),
)))),
Expanded(
child: InkWell(
onTap: () => {
AddFamilyMemberType.loginType = 2,
Navigator.of(context)
.pushNamed(ADD_FAMILY_MEMBER)
},
child: RoundedContainer(
borderColor: Colors.grey,
showBorder: true,
child: Padding(
padding: EdgeInsets.fromLTRB(
25, 10, 25, 10),
child: Column(
children: <Widget>[
Image.asset(
'assets/images/my_file_white_icon.png',
height: SizeConfig
.imageSizeMultiplier *
12,
width: SizeConfig
.imageSizeMultiplier *
15,
),
SizedBox(
height: 20,
),
AppText(
TranslationBase.of(context)
.fileNo,
fontSize: SizeConfig
.textMultiplier *
2,
)
SizedBox(height: 20),
// RichText(
// text: TextSpan(
// text: TranslationBase.of(context).forgotPassword,
// style: TextStyle(decoration: TextDecoration.underline, fontSize: 12, fontWeight: FontWeight.w600, color: Color(0xffC9272B), letterSpacing: -0.48, height: 18 / 12),
// recognizer: TapGestureRecognizer()..onTap = () => Navigator.of(context).push(FadePage(page: ForgotPassword())),
// ),
// ),
],
),
))))
],
)),
Divider(
color: Colors.grey,
height: 2,
),
// SizedBox(
// height: 43,
// width: double.infinity,
// child: FlatButton(
// onPressed: () {},
// child: Text(
// TranslationBase.of(context).registerNow,
// style: TextStyle(fontSize: 16, fontWeight: FontWeight.w600, color: Colors.white, letterSpacing: -0.48),
// ),
// color: Color(0xffD02127),
// shape: RoundedRectangleBorder(
// borderRadius: BorderRadius.circular(6),
// ),
// ),
// ),
]),
),
));
// body: Padding(
// padding: EdgeInsets.all(20),
// child: Column(
// children: <Widget>[
// Expanded(
// flex: 2,
// flex: 6,
// child: Column(
// mainAxisAlignment: MainAxisAlignment.end,
// // mainAxisAlignment: MainAxisAlignment.spaceBetween,
// crossAxisAlignment: CrossAxisAlignment.start,
// children: <Widget>[
// Row(
// Image.asset(
// 'assets/images/habib-logo.png',
// height: 80,
// width: 80,
// ),
// Padding(
// padding: EdgeInsets.all(20),
// child: AppText(
// TranslationBase.of(context).registerInfoFamily,
// fontSize: SizeConfig.textMultiplier * 3.5,
// textAlign: TextAlign.left,
// ),
// ),
// Padding(
// padding: EdgeInsets.all(20),
// child: Row(
// mainAxisAlignment: MainAxisAlignment.center,
// children: <Widget>[
// Expanded(
// child: DefaultButton(
// TranslationBase.of(context).registerNow,
// () => {
// Navigator.of(context).pushNamed(
// REGISTER,
// child: InkWell(
// onTap: () => {AddFamilyMemberType.loginType = 1, Navigator.of(context).pushNamed(ADD_FAMILY_MEMBER)},
// child: RoundedContainer(
// borderColor: Colors.grey,
// showBorder: true,
// child: Padding(
// padding: EdgeInsets.fromLTRB(20, 10, 20, 10),
// child: Column(
// mainAxisAlignment: MainAxisAlignment.center,
// children: <Widget>[
// Image.asset(
// 'assets/images/id_card_icon.png',
// height: SizeConfig.imageSizeMultiplier * 12,
// width: SizeConfig.imageSizeMultiplier * 15,
// ),
// SizedBox(
// height: 20,
// ),
// AppText(
// TranslationBase.of(context).idNo,
// fontSize: SizeConfig.textMultiplier * 2,
// )
// ],
// ),
// )))),
// Expanded(
// child: InkWell(
// onTap: () => {AddFamilyMemberType.loginType = 2, Navigator.of(context).pushNamed(ADD_FAMILY_MEMBER)},
// child: RoundedContainer(
// borderColor: Colors.grey,
// showBorder: true,
// child: Padding(
// padding: EdgeInsets.fromLTRB(25, 10, 25, 10),
// child: Column(
// children: <Widget>[
// Image.asset(
// 'assets/images/my_file_white_icon.png',
// height: SizeConfig.imageSizeMultiplier * 12,
// width: SizeConfig.imageSizeMultiplier * 15,
// ),
// SizedBox(
// height: 20,
// ),
// AppText(
// TranslationBase.of(context).fileNo,
// fontSize: SizeConfig.textMultiplier * 2,
// )
// },
// ))
// ],
// ),
// ))))
// ],
// ))
// )),
// Divider(
// color: Colors.grey,
// height: 2,
// ),
// ]),
// ),
// // Expanded(
// // flex: 2,
// // child: Column(
// // mainAxisAlignment: MainAxisAlignment.end,
// // children: <Widget>[
// // Row(
// // children: <Widget>[
// // Expanded(
// // child: DefaultButton(
// // TranslationBase.of(context).registerNow,
// // () => {
// // Navigator.of(context).pushNamed(
// // REGISTER,
// // )
// // },
// // ))
// // ],
// // ),
// // ],
// // ))
// ],
// )));
}
Widget getButton(BuildContext _context, String _title, String _icon, int _flag) {
return InkWell(
onTap: () {
AddFamilyMemberType.loginType = _flag;
Navigator.of(_context).pushNamed(ADD_FAMILY_MEMBER);
},
child: Container(
padding: EdgeInsets.only(left: 20, right: 20, bottom: 15, top: 28),
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(15),
color: Colors.white,
border: Border.all(
color: Color(0xffefefef),
width: 1,
),
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: <Widget>[
SvgPicture.asset(
_icon,
height: 38,
width: 38,
),
Text(
_title,
style: TextStyle(fontSize: 16, fontWeight: FontWeight.w600, color: Color(0xff2B353E), letterSpacing: -0.48, height: 20 / 16),
),
],
)));
),
),
);
}
}

@ -80,6 +80,8 @@ class _MyFamily extends State<MyFamily> with TickerProviderStateMixin {
appBarTitle: TranslationBase.of(context).myFamilyFiles,
isShowAppBar: widget.isAppbarVisible,
imagesInfo: imagesInfo,
showNewAppBar: true,
showNewAppBarTitle: true,
icon: "assets/images/new/bottom_nav/family_files.svg",
description: TranslationBase.of(context).familyInfo,
body: Scaffold(
@ -527,28 +529,31 @@ class _MyFamily extends State<MyFamily> with TickerProviderStateMixin {
var currentLang = await sharedPref.getString(APP_LANGUAGE);
Provider.of<ProjectViewModel>(context, listen: false).setPrivilege(privilegeList: result, isLoginChild: true);
result = list.CheckActivationCode.fromJson(result);
var familyFile = await sharedPref.getObject(FAMILY_FILE);
result = list.CheckActivationCode.fromJson(result);
var mainUser = await sharedPref.getObject(MAIN_USER);
var bloodType = await sharedPref.getString(BLOOD_TYPE);
var loginType = await sharedPref.getInt(LAST_LOGIN);
this.sharedPref.clear();
if (mainUser["PatientID"] != result.list.patientID) {
result.list.isFamily = true;
}
this.sharedPref.setString(APP_LANGUAGE, currentLang);
this.sharedPref.setInt(LAST_LOGIN, loginType);
this.sharedPref.setObject(MAIN_USER, mainUser);
this.sharedPref.setObject(USER_PROFILE, result.list);
this.sharedPref.setObject(FAMILY_FILE, familyFile);
this.sharedPref.setObject(LOGIN_TOKEN_ID, result.logInTokenID);
this.sharedPref.setString(TOKEN, result.authenticationTokenID);
await authenticatedUserObject.getUser(getUser: true);
Provider.of<ProjectViewModel>(context, listen: false).user = authenticatedUserObject.user;
Provider.of<ProjectViewModel>(context, listen: false).setUser(authenticatedUserObject.user);
await pharmacyModuleViewModel.generatePharmacyToken().then((value) async {
if (pharmacyModuleViewModel.error.isNotEmpty) await pharmacyModuleViewModel.createUser();
});
// await pharmacyModuleViewModel.generatePharmacyToken().then((value) async {
// if (pharmacyModuleViewModel.error.isNotEmpty) await pharmacyModuleViewModel.createUser();
// });
appointmentRateViewModel
.getIsLastAppointmentRatedList()

@ -207,6 +207,6 @@ class RRTPlaceOrderPage extends StatelessWidget {
}
gotoRRTRoot() {
Navigator.popUntil(_context, (route) => Utils.route(route, equalsTo: ErOptions));
Navigator.popUntil(_context, (route) => Utils.route(route, equalsTo: RRTMainScreen));
}
}

@ -190,6 +190,7 @@ class RRTRequestPageState extends State<RRTRequestPage> {
else
AppToast.showErrorToast(message: TranslationBase.of(context).pleaseAcceptTerms);
},
color: acceptTerms ? Colors.red[600] : Colors.grey,
),
),
],

@ -392,13 +392,11 @@ class _ConfirmLogin extends State<ConfirmLogin> {
loginWithFingurePrintFace(type, int isActive) async {
if (isActive == 1 || isActive == 0) {
const iosStrings =
const IOSAuthMessages(cancelButton: 'cancel', goToSettingsButton: 'settings', goToSettingsDescription: 'Please set up your Touch ID.', lockOut: 'Please reenable your Touch ID');
try {
authenticated = await auth.authenticateWithBiometrics(localizedReason: 'Scan your fingerprint to authenticate', useErrorDialogs: true, stickyAuth: true, iOSAuthStrings: iosStrings);
} on PlatformException catch (e) {
GifLoaderDialogUtils.hideDialog(context);
AppToast.showErrorToast(message: 'Please enable your Touch or Face ID');
@ -689,36 +687,36 @@ class _ConfirmLogin extends State<ConfirmLogin> {
),
);
return InkWell(
onTap: () {
if (_flag == 0) {
setState(() {
isMoreOption = true;
});
} else {
authenticateUser(4, isActive: _loginIndex);
}
},
child: RoundedContainer(
height: 150,
borderColor: Colors.grey,
showBorder: true,
child: Padding(
padding: EdgeInsets.fromLTRB(30, 15, 30, 15),
child: Column(
children: <Widget>[
Image.asset(
_icon,
height: SizeConfig.imageSizeMultiplier * 13,
width: SizeConfig.imageSizeMultiplier * 16,
),
SizedBox(
height: 20,
),
Texts(_title, fontSize: SizeConfig.textMultiplier * 2, color: Colors.black)
],
),
)));
// return InkWell(
// onTap: () {
// if (_flag == 0) {
// setState(() {
// isMoreOption = true;
// });
// } else {
// authenticateUser(4, isActive: _loginIndex);
// }
// },
// child: RoundedContainer(
// height: 150,
// borderColor: Colors.grey,
// showBorder: true,
// child: Padding(
// padding: EdgeInsets.fromLTRB(30, 15, 30, 15),
// child: Column(
// children: <Widget>[
// Image.asset(
// _icon,
// height: SizeConfig.imageSizeMultiplier * 13,
// width: SizeConfig.imageSizeMultiplier * 16,
// ),
// SizedBox(
// height: 20,
// ),
// Texts(_title, fontSize: SizeConfig.textMultiplier * 2, color: Colors.black)
// ],
// ),
// )));
}
// todo 'sikander' optimize this after knowing usage

@ -59,8 +59,7 @@ class LoginType extends StatelessWidget {
RichText(
text: TextSpan(
text: TranslationBase.of(context).forgotPassword,
style: TextStyle(
decoration: TextDecoration.underline, fontSize: 12, fontWeight: FontWeight.w600, color: Color(0xffC9272B), letterSpacing: -0.48, height: 18 / 12),
style: TextStyle(decoration: TextDecoration.underline, fontSize: 12, fontWeight: FontWeight.w600, color: Color(0xffC9272B), letterSpacing: -0.48, height: 18 / 12),
recognizer: TapGestureRecognizer()..onTap = () => Navigator.of(context).push(FadePage(page: ForgotPassword())),
),
),
@ -88,141 +87,141 @@ class LoginType extends StatelessWidget {
),
);
AppScaffold(
appBarTitle: TranslationBase.of(context).login,
isShowAppBar: true,
isShowDecPage: false,
body: SingleChildScrollView(
child: Container(
padding: EdgeInsets.only(top: 10, left: 20, right: 20, bottom: 30),
height: SizeConfig.realScreenHeight * .9,
width: SizeConfig.realScreenWidth,
child: Column(
children: <Widget>[
Expanded(
flex: 4,
child: Column(
// mainAxisAlignment: MainAxisAlignment.spaceEvenly,
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
Image.asset(
'assets/images/DQ/logo.png',
height: 90,
width: 90,
),
AppText(
TranslationBase.of(context).logintypeRadio,
fontSize: SizeConfig.textMultiplier * 3.5,
textAlign: TextAlign.start,
marginBottom: 20.0,
marginTop: 20.0,
),
Row(
mainAxisAlignment: MainAxisAlignment.center,
children: <Widget>[
Expanded(
child: InkWell(
onTap: () => {
LoginType.loginType = 1,
Navigator.of(context).push(FadePage(page: Login())),
},
child: RoundedContainer(
borderColor: Colors.grey,
showBorder: true,
child: Padding(
padding: EdgeInsets.fromLTRB(20, 10, 20, 10),
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: <Widget>[
Image.asset(
'assets/images/id_card_icon.png',
height: SizeConfig.imageSizeMultiplier * 12,
width: SizeConfig.imageSizeMultiplier * 15,
),
SizedBox(
height: 20,
),
AppText(
TranslationBase.of(context).idNo,
fontSize: SizeConfig.textMultiplier * 2,
fontWeight: FontWeight.bold,
)
],
),
)))),
Expanded(
child: InkWell(
onTap: () => {
LoginType.loginType = 2,
Navigator.of(context).push(FadePage(page: Login())),
},
child: RoundedContainer(
borderColor: Colors.grey,
showBorder: true,
child: Padding(
padding: EdgeInsets.fromLTRB(25, 10, 25, 10),
child: Column(
children: <Widget>[
Image.asset(
'assets/images/my_file_white_icon.png',
height: SizeConfig.imageSizeMultiplier * 12,
width: SizeConfig.imageSizeMultiplier * 15,
),
SizedBox(
height: 20,
),
AppText(
TranslationBase.of(context).fileNo,
fontSize: SizeConfig.textMultiplier * 2,
fontWeight: FontWeight.bold,
)
],
),
))))
],
),
SizedBox(
height: 25,
),
Divider(
color: Colors.grey,
height: 2,
),
Center(
child: InkWell(
onTap: () => {
Navigator.of(context).push(FadePage(page: ForgotPassword())),
},
child: AppText(TranslationBase.of(context).forgotPassword, fontSize: SizeConfig.textMultiplier * 2.5, marginTop: 20.0, underline: true)))
]),
),
Expanded(
flex: 1,
child: Column(
mainAxisAlignment: MainAxisAlignment.end,
children: <Widget>[
Divider(
color: Colors.grey,
height: 2,
),
SizedBox(
height: 10,
),
Row(
children: <Widget>[
Expanded(
child: DefaultButton(
TranslationBase.of(context).registerNow,
() => {
Navigator.of(context).push(FadePage(page: Register())),
},
)),
],
),
],
))
],
))));
// AppScaffold(
// appBarTitle: TranslationBase.of(context).login,
// isShowAppBar: true,
// isShowDecPage: false,
// body: SingleChildScrollView(
// child: Container(
// padding: EdgeInsets.only(top: 10, left: 20, right: 20, bottom: 30),
// height: SizeConfig.realScreenHeight * .9,
// width: SizeConfig.realScreenWidth,
// child: Column(
// children: <Widget>[
// Expanded(
// flex: 4,
// child: Column(
// // mainAxisAlignment: MainAxisAlignment.spaceEvenly,
// crossAxisAlignment: CrossAxisAlignment.start,
// children: <Widget>[
// Image.asset(
// 'assets/images/DQ/logo.png',
// height: 90,
// width: 90,
// ),
// AppText(
// TranslationBase.of(context).logintypeRadio,
// fontSize: SizeConfig.textMultiplier * 3.5,
// textAlign: TextAlign.start,
// marginBottom: 20.0,
// marginTop: 20.0,
// ),
// Row(
// mainAxisAlignment: MainAxisAlignment.center,
// children: <Widget>[
// Expanded(
// child: InkWell(
// onTap: () => {
// LoginType.loginType = 1,
// Navigator.of(context).push(FadePage(page: Login())),
// },
// child: RoundedContainer(
// borderColor: Colors.grey,
// showBorder: true,
// child: Padding(
// padding: EdgeInsets.fromLTRB(20, 10, 20, 10),
// child: Column(
// mainAxisAlignment: MainAxisAlignment.center,
// children: <Widget>[
// Image.asset(
// 'assets/images/id_card_icon.png',
// height: SizeConfig.imageSizeMultiplier * 12,
// width: SizeConfig.imageSizeMultiplier * 15,
// ),
// SizedBox(
// height: 20,
// ),
// AppText(
// TranslationBase.of(context).idNo,
// fontSize: SizeConfig.textMultiplier * 2,
// fontWeight: FontWeight.bold,
// )
// ],
// ),
// )))),
// Expanded(
// child: InkWell(
// onTap: () => {
// LoginType.loginType = 2,
// Navigator.of(context).push(FadePage(page: Login())),
// },
// child: RoundedContainer(
// borderColor: Colors.grey,
// showBorder: true,
// child: Padding(
// padding: EdgeInsets.fromLTRB(25, 10, 25, 10),
// child: Column(
// children: <Widget>[
// Image.asset(
// 'assets/images/my_file_white_icon.png',
// height: SizeConfig.imageSizeMultiplier * 12,
// width: SizeConfig.imageSizeMultiplier * 15,
// ),
// SizedBox(
// height: 20,
// ),
// AppText(
// TranslationBase.of(context).fileNo,
// fontSize: SizeConfig.textMultiplier * 2,
// fontWeight: FontWeight.bold,
// )
// ],
// ),
// ))))
// ],
// ),
// SizedBox(
// height: 25,
// ),
// Divider(
// color: Colors.grey,
// height: 2,
// ),
// Center(
// child: InkWell(
// onTap: () => {
// Navigator.of(context).push(FadePage(page: ForgotPassword())),
// },
// child: AppText(TranslationBase.of(context).forgotPassword, fontSize: SizeConfig.textMultiplier * 2.5, marginTop: 20.0, underline: true)))
// ]),
// ),
// Expanded(
// flex: 1,
// child: Column(
// mainAxisAlignment: MainAxisAlignment.end,
// children: <Widget>[
// Divider(
// color: Colors.grey,
// height: 2,
// ),
// SizedBox(
// height: 10,
// ),
// Row(
// children: <Widget>[
// Expanded(
// child: DefaultButton(
// TranslationBase.of(context).registerNow,
// () => {
// Navigator.of(context).push(FadePage(page: Register())),
// },
// )),
// ],
// ),
// ],
// ))
// ],
// ))));
}
Widget getButton(BuildContext _context, String _title, String _icon, int _flag) {

@ -232,7 +232,7 @@ class FamilyFilesProvider with ChangeNotifier {
var currentUser = AuthenticatedUser.fromJson(await sharedPref.getObject(MAIN_USER));
request['PatientOutSA'] = currentUser.outSA; //? 1 : 0;
request['LoginType'] = await sharedPref.getInt(LAST_LOGIN);
request['LoginType'] = await sharedPref.getInt(LAST_LOGIN) ?? 1;
request['MobileNo'] = currentUser.mobileNumber[0].toString() == "0" ? currentUser.mobileNumber.toString() : '0' + currentUser.mobileNumber.toString();
request['PatientMobileNumber'] = currentUser.mobileNumber; //['MobileNumber'];
request['SearchType'] = 2;

Loading…
Cancel
Save