Merge branch 'sultan-patientapp' into 'development'

Sultan patientapp

See merge request Cloud_Solution/diplomatic-quarter!295
merge-update-with-lab-changes
Mohammad Aljammal 5 years ago
commit f2c5c93e2a

@ -18,10 +18,9 @@ class WeatherService extends BaseService {
var long = await sharedPref.getDouble(USER_LONG); var long = await sharedPref.getDouble(USER_LONG);
body['Latitude'] = lat ?? 0; body['Latitude'] = lat ?? 0;
body['Longitude'] = long ?? 0; body['Longitude'] = long ?? 0;
weatherIndicatorData = [];
await baseAppClient.post(WEATHER_INDICATOR, await baseAppClient.post(WEATHER_INDICATOR,
onSuccess: (dynamic response, int statusCode) { onSuccess: (dynamic response, int statusCode) {
weatherIndicatorData = [];
response['GetCityInfo_List'].forEach((data) { response['GetCityInfo_List'].forEach((data) {
weatherIndicatorData.add(GetCityInfoList.fromJson(data)); weatherIndicatorData.add(GetCityInfoList.fromJson(data));
}); });

@ -1,6 +1,7 @@
import 'package:diplomaticquarterapp/core/viewModels/ancillary_orders_view_model.dart'; import 'package:diplomaticquarterapp/core/viewModels/ancillary_orders_view_model.dart';
import 'package:diplomaticquarterapp/pages/base/base_view.dart'; import 'package:diplomaticquarterapp/pages/base/base_view.dart';
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart'; import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
import 'package:diplomaticquarterapp/widgets/buttons/button.dart';
import 'package:diplomaticquarterapp/widgets/data_display/text.dart'; import 'package:diplomaticquarterapp/widgets/data_display/text.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart'; import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
@ -42,7 +43,31 @@ class _AnicllaryOrdersState extends State<AnicllaryOrdersDetails>
getPatientInfo(model), getPatientInfo(model),
getInvoiceDetails(model), getInvoiceDetails(model),
getInsuranceDetails(model), getInsuranceDetails(model),
getAncillaryDetails(model) getAncillaryDetails(model),
Row(
mainAxisAlignment: MainAxisAlignment.spaceAround,
children: [
Texts(
TranslationBase.of(context).total,
fontSize: 20,
fontWeight: FontWeight.bold,
),
Texts(
getTotalValue(model),
fontSize: 20,
fontWeight: FontWeight.bold,
)
],
),
Row(
mainAxisAlignment: MainAxisAlignment.end,
children: [
Button(
label: TranslationBase.of(context).payNow,
onTap: () {},
)
],
)
]) ])
: SizedBox()))); : SizedBox())));
} }
@ -208,7 +233,9 @@ class _AnicllaryOrdersState extends State<AnicllaryOrdersDetails>
); );
list.add(Row( list.add(Row(
mainAxisAlignment: MainAxisAlignment.start, mainAxisAlignment: MainAxisAlignment.start,
children: [getLabDetails(value)], children: [
getLabDetails(value),
],
)); ));
}); });
@ -218,6 +245,13 @@ class _AnicllaryOrdersState extends State<AnicllaryOrdersDetails>
); );
} }
String getTotalValue(value) {
double total = 0.0;
value.ancillaryListsDetails[0].ancillaryOrderProcList
.forEach((result) => {total += result.companyShareWithTax});
return total.toStringAsFixed(2);
}
getLabDetails(value) { getLabDetails(value) {
return Column( return Column(
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,

@ -660,14 +660,15 @@ class _MyFamily extends State<MyFamily> with TickerProviderStateMixin {
okText: TranslationBase.of(context).confirm, okText: TranslationBase.of(context).confirm,
cancelText: TranslationBase.of(context).cancel_nocaps, cancelText: TranslationBase.of(context).cancel_nocaps,
okFunction: () => { okFunction: () => {
removeFamily(family, context), ConfirmDialog.closeAlertDialog(context),
ConfirmDialog.closeAlertDialog(context) removeFamily(family, context)
}, },
cancelFunction: () => {}); cancelFunction: () => {});
dialog.showAlertDialog(context); dialog.showAlertDialog(context);
} }
removeFamily(GetAllSharedRecordsByStatusList family, context) { removeFamily(GetAllSharedRecordsByStatusList family, context) {
GifLoaderDialogUtils.showMyDialog(context);
this.userID = family.iD; this.userID = family.iD;
Map<String, dynamic> request = {}; Map<String, dynamic> request = {};
request['ID'] = this.userID; request['ID'] = this.userID;
@ -679,7 +680,7 @@ class _MyFamily extends State<MyFamily> with TickerProviderStateMixin {
} }
refreshFamily(context) { refreshFamily(context) {
//sharedPref.remove(FAMILY_FILE); GifLoaderDialogUtils.hideDialog(context);
setState(() { setState(() {
sharedPref.remove(FAMILY_FILE); sharedPref.remove(FAMILY_FILE);
}); });

@ -5,6 +5,7 @@ import 'package:diplomaticquarterapp/routes.dart';
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart'; import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
import 'package:diplomaticquarterapp/widgets/buttons/defaultButton.dart'; import 'package:diplomaticquarterapp/widgets/buttons/defaultButton.dart';
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart'; import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
import 'package:diplomaticquarterapp/widgets/text/app_texts_widget.dart';
import 'package:diplomaticquarterapp/widgets/transitions/fade_page.dart'; import 'package:diplomaticquarterapp/widgets/transitions/fade_page.dart';
import 'package:flutter/cupertino.dart'; import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
@ -41,20 +42,19 @@ class _WelcomeLogin extends State<WelcomeLogin> {
children: <Widget>[ children: <Widget>[
Image.asset('assets/images/DQ/logo.png', Image.asset('assets/images/DQ/logo.png',
height: 90, width: 90), height: 90, width: 90),
Text( AppText(
TranslationBase.of(context).welcome, TranslationBase.of(context).welcome,
style: TextStyle( fontSize: 30,
fontSize: 30, fontWeight: FontWeight.bold), fontWeight: FontWeight.bold,
textAlign: TextAlign.start,
), ),
Text( AppText(
TranslationBase.of(context).welcomeText, TranslationBase.of(context).welcomeText,
style: TextStyle(fontSize: 24), fontSize: 24,
textAlign: TextAlign.start, textAlign: TextAlign.start,
), ),
Text( AppText(
TranslationBase.of(context).welcomeText2, TranslationBase.of(context).welcomeText2,
style: TextStyle(fontSize: 24), fontSize: 24,
textAlign: TextAlign.start, textAlign: TextAlign.start,
), ),
SizedBox( SizedBox(

@ -378,24 +378,24 @@ class AuthProvider with ChangeNotifier {
Future<Map> sendPatientIDSMS(mobileNo, context) async { Future<Map> sendPatientIDSMS(mobileNo, context) async {
Map<String, dynamic> request; Map<String, dynamic> request;
var languageID = // var languageID =
await sharedPref.getStringWithDefaultValue(APP_LANGUAGE, 'ar'); // await sharedPref.getStringWithDefaultValue(APP_LANGUAGE, 'ar');
Request req = appGlobal.getPublicRequest(); Request req = appGlobal.getPublicRequest();
request = { request = {
"LanguageID": languageID == 'ar' ? 1 : 2, // "LanguageID": languageID == 'ar' ? 1 : 2,
"IPAdress": "10.20.10.20", // "IPAdress": "10.20.10.20",
"VersionID": req.VersionID, // "VersionID": req.VersionID,
"Channel": req.Channel, // "Channel": req.Channel,
"generalid": 'Cs2020@2016\$2958', // "generalid": 'Cs2020@2016\$2958',
"PatientOutSA": 0, // "PatientOutSA": 0,
"PatientID": 0, // "PatientID": 0,
"TokenID": "", // "TokenID": "",
"PatientMobileNumber": mobileNo, "PatientMobileNumber": mobileNo,
"SearchType": 2, "SearchType": 2,
"ZipCode": "966", // "ZipCode": "966",
"PatientIdentificationID": "", // "PatientIdentificationID": "",
"DeviceTypeID": req.DeviceTypeID, "DeviceTypeID": req.DeviceTypeID,
"SessionID": null // "SessionID": null
}; };
dynamic localRes; dynamic localRes;

@ -195,6 +195,7 @@ class _AppDrawerState extends State<AppDrawer> {
sideArrow: true, sideArrow: true,
), ),
onTap: () { onTap: () {
Navigator.of(context).pop();
Navigator.of(context).pushNamed( Navigator.of(context).pushNamed(
MY_FAMILIY, MY_FAMILIY,
); );

Loading…
Cancel
Save