Merge branches 'Stepper_header' and 'development' of https://gitlab.com/Cloud_Solution/doctor_app_flutter into Stepper_header

 Conflicts:
	lib/widgets/patients/profile/soap_update/update_plan_page.dart
merge-requests/473/head
Elham Rababah 4 years ago
commit 9a8ca00eec

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 453 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 453 B

@ -322,4 +322,4 @@ SPEC CHECKSUMS:
PODFILE CHECKSUM: 649616dc336b3659ac6b2b25159d8e488e042b69
COCOAPODS: 1.10.0.rc.1
COCOAPODS: 1.10.1

@ -43,7 +43,7 @@ const Map<String, Map<String, String>> localizedValues = {
'notArrived': {'en': 'Not Arrived', 'ar': 'لم يصل'},
'radiology': {'en': 'Radiology', 'ar': 'الأشعة'},
'service': {'en': 'Service', 'ar': 'خدمة'},
'referral': {'en': 'Referral', 'ar': 'االإحالة'},
'referral': {'en': 'Referral', 'ar': 'الإحالة'},
'inPatient': {'en': 'In Patient', 'ar': 'المريض الداخلي'},
'operations': {'en': 'Operations', 'ar': 'عمليات'},
'patientServices': {'en': 'Patient Services', 'ar': 'خدمات المرضى'},
@ -51,7 +51,7 @@ const Map<String, Map<String, String>> localizedValues = {
'myReferralPatient': {'en': 'My Referral Patient', 'ar': 'مرضى الاحالة'},
'referPatient': {'en': 'Referral Patient', 'ar': 'إحالة مريض'},
'myReferral': {'en': 'My Referral', 'ar': 'إحالة'},
'myReferredPatient': {'en': 'My Referred Patient', 'ar': 'مرضاي المحالين'},
'myReferredPatient': {'en': 'Referred', 'ar': 'المحالين'},
'referredPatient': {'en': 'Referred Patient', 'ar': 'المرضى المحالين'},
'referredOn': {'en': 'referred On : ', 'ar': ' : تمت الإحالة في'},
'firstName': {'en': 'First Name', 'ar': 'الاسم الاول'},
@ -843,6 +843,10 @@ const Map<String, Map<String, String>> localizedValues = {
"en": "Step",
"ar": "خطوة"
},
"fieldRequired": {
"en": "This field is required",
"ar": "هذه الخانة مطلوبه"
},
"applyOrRescheduleLeave": {
"en": "Apply Or Reschedule Leave",
"ar": "التقدم بطلب أو إعادة جدولة الإجازة"

@ -19,7 +19,7 @@ class MedicalFileViewModel extends BaseViewModel {
await _medicalFileService.getMedicalFile(mrn: mrn);
if (_medicalFileService.hasError) {
error = _medicalFileService.error;
setState(ViewState.ErrorLocal);
setState(ViewState.Error);
} else
setState(ViewState.Idle);
}

@ -46,7 +46,7 @@ class MyApp extends StatelessWidget {
child: Consumer<ProjectViewModel>(
builder: (context, projectProvider, child) => MaterialApp(
showSemanticsDebugger: false,
title: 'Flutter Demo',
title: 'Doctors App',
locale: projectProvider.appLocal,
localizationsDelegates: [
TranslationBaseDelegate(),

@ -119,7 +119,7 @@ class _LoginsreenState extends State<Loginsreen> {
children: <Widget>[
AuthHeader(loginType.knownUser),
SizedBox(
height: 60,
height: 40,
),
LoginForm(
changeLoadingStata: changeLoadingStata,

@ -131,181 +131,6 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
),
);
// return Padding(
// padding: EdgeInsets.symmetric(
// horizontal: 12.0, vertical: 8.0),
// child: InkWell(
// child: Container(
// width: double.infinity,
// margin: EdgeInsets.only(
// top: 10, left: 10, right: 10),
// padding: EdgeInsets.all(8.0),
// decoration: BoxDecoration(
// color: Colors.white,
// borderRadius: BorderRadius.all(
// Radius.circular(10.0),
// ),
// border: Border.all(
// color: Colors.grey[200], width: 0.5),
// ),
// child: Column(
// children: [
// Row(
// mainAxisAlignment:
// MainAxisAlignment.spaceBetween,
// children: [
// Row(
// children: [
// AppText(
// model
// .medicalFileList[0]
// .entityList[0]
// .timelines[index]
// .doctorName,
// fontWeight: FontWeight.w700,
// fontSize: 17.0,
// fontFamily: 'Poppins',
// )
// ],
// ),
// Row(
// children: [
// AppText(
// Helpers.convertStringToDate(model
// .medicalFileList[0]
// .entityList[0]
// .timelines[index]
// .date)
// .day
// .toString() +
// "/",
// ),
// AppText(
// Helpers.convertStringToDate(model
// .medicalFileList[0]
// .entityList[0]
// .timelines[index]
// .date)
// .month
// .toString() +
// "/",
// ),
// AppText(
// Helpers.convertStringToDate(
// model
// .medicalFileList[0]
// .entityList[0]
// .timelines[index]
// .date)
// .year
// .toString(),
// ),
// ],
// )
// ],
// ),
// Row(
// mainAxisAlignment:
// MainAxisAlignment.start,
// children: [
// Padding(
// padding: const EdgeInsets.all(8.0),
// child: Column(
// children: [
// ClipRRect(
// borderRadius:
// BorderRadius.all(
// Radius.circular(30)),
// child: Image.network(
// 'https://previews.123rf.com/images/yupiramos/yupiramos1705/yupiramos170524444/78443570-a-female-doctor-avatar-character-vector-illustration-design.jpg',
// fit: BoxFit.cover,
// width: 60,
// height: 70,
// ),
// ),
// ],
// ),
// ),
// Column(
// crossAxisAlignment:
// CrossAxisAlignment.start,
// children: [
// Row(
// children: [
// AppText(
// TranslationBase.of(context)
// .clinic +
// ": ",
// ),
// AppText(
// model
// .medicalFileList[0]
// .entityList[0]
// .timelines[index]
// .clinicName,
// fontWeight: FontWeight.w600,
// ),
// ],
// ),
// Row(
// mainAxisAlignment:
// MainAxisAlignment
// .spaceBetween,
// children: [
// AppText(
// TranslationBase.of(context)
// .branch +
// ": ",
// ),
// AppText(
// model
// .medicalFileList[0]
// .entityList[0]
// .timelines[index]
// .projectName,
// fontWeight: FontWeight.w600,
// ),
// ],
// ),
// ],
// ),
// ],
// ),
// Row(
// mainAxisAlignment:
// MainAxisAlignment.end,
// children: [
// Column(
// children: [
// Icon(
// Icons.remove_red_eye,
// size: 30.0,
// )
// ],
// )
// ],
// ),
// ],
// ),
// ),
// onTap: () {
// Navigator.push(
// context,
// MaterialPageRoute(
// builder: (context) =>
// MedicalFileDetails(
// age: patient.age,
// firstName: patient.firstName,
// lastName: patient.lastName,
// gender: patient.genderDescription,
// encounterNumber: index,
// pp: patient.patientId,
// patient: patient,
// )),
// );
// },
// ),
// );
})
: Column(
children: [

@ -8,10 +8,12 @@ import 'package:doctor_app_flutter/models/SOAP/master_key_model.dart';
import 'package:doctor_app_flutter/models/SOAP/order-procedure.dart';
import 'package:doctor_app_flutter/models/patient/patiant_info_model.dart';
import 'package:doctor_app_flutter/screens/base/base_view.dart';
import 'package:doctor_app_flutter/screens/patients/profile/UCAF/page-stepper-widget.dart';
import 'package:doctor_app_flutter/util/dr_app_toast_msg.dart';
import 'package:doctor_app_flutter/util/helpers.dart';
import 'package:doctor_app_flutter/util/translations_delegate_base.dart';
import 'package:doctor_app_flutter/widgets/patients/profile/PatientHeaderWidgetNoAvatar.dart';
import 'package:doctor_app_flutter/widgets/patients/profile/patient-profile-header-new-design-app-bar.dart';
import 'package:doctor_app_flutter/widgets/shared/app_scaffold_widget.dart';
import 'package:doctor_app_flutter/widgets/shared/app_texts_widget.dart';
import 'package:doctor_app_flutter/widgets/shared/borderedButton.dart';
@ -45,6 +47,9 @@ class _UcafDetailScreenState extends State<UcafDetailScreen> {
},
builder: (_, model, w) => AppScaffold(
baseViewModel: model,
isShowAppBar: true,
appBar: PatientProfileHeaderNewDesignAppBar(
patient, patientType, arrivalType),
appBarTitle: TranslationBase.of(context).ucaf,
body: Column(
children: [
@ -54,7 +59,32 @@ class _UcafDetailScreenState extends State<UcafDetailScreen> {
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
PatientHeaderWidgetNoAvatar(patient),
// PatientHeaderWidgetNoAvatar(patient),
Container(
margin: EdgeInsets.all(16.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
AppText(
"${TranslationBase.of(context).patient}",
fontFamily: 'Poppins',
fontSize: SizeConfig.textMultiplier * 1.6,
fontWeight: FontWeight.w600,
),
AppText(
"${TranslationBase.of(context).ucaf}",
fontFamily: 'Poppins',
fontSize: SizeConfig.textMultiplier * 3,
fontWeight: FontWeight.bold,
)
],
),
),
PageStepperWidget(
stepsCount: 2,
currentStepIndex: 2,
screenSize: screenSize,
),
SizedBox(
height: 10,
),
@ -80,48 +110,60 @@ class _UcafDetailScreenState extends State<UcafDetailScreen> {
),
Container(
margin: EdgeInsets.symmetric(vertical: 8, horizontal: 16),
child: BorderedButton(
TranslationBase.of(context).save,
hasBorder: true,
vPadding: 8,
hPadding: 8,
borderColor: HexColor("#B8382B"),
backgroundColor: HexColor("#B8382B"),
textColor: Colors.white,
fontSize: SizeConfig.textMultiplier * 2.0,
handler: () async {
await model.postUCAF(patient);
if (model.state == ViewState.Idle) {
DrAppToastMsg.showSuccesToast(
TranslationBase.of(context).postUcafSuccessMsg);
Navigator.of(context).popUntil((route) {
return route.settings.name == PATIENTS_PROFILE;
});
} else {
DrAppToastMsg.showErrorToast(model.error);
}
},
),
),
Container(
margin: EdgeInsets.only(
left: 16, right: 16, top: 0.0, bottom: 8),
child: BorderedButton(
TranslationBase.of(context).cancel,
hasBorder: true,
vPadding: 8,
hPadding: 8,
borderColor: Colors.white,
backgroundColor: Colors.white,
textColor: HexColor("#B8382B"),
fontSize: SizeConfig.textMultiplier * 2.2,
handler: () {
Navigator.of(context).popUntil((route) {
return route.settings.name == PATIENTS_PROFILE;
});
},
child: Row(
children: [
Expanded(
child: Container(
child: BorderedButton(
TranslationBase.of(context).cancel,
hasBorder: true,
vPadding: 8,
hPadding: 8,
borderColor: Colors.white,
backgroundColor: Colors.white,
textColor: HexColor("#B8382B"),
fontSize: SizeConfig.textMultiplier * 2.2,
handler: () {
Navigator.of(context).popUntil((route) {
return route.settings.name == PATIENTS_PROFILE;
});
},
),
),
),
SizedBox(
width: 8,
),
Expanded(
child: Container(
child: BorderedButton(
TranslationBase.of(context).save,
hasBorder: true,
vPadding: 8,
hPadding: 8,
borderColor: HexColor("#B8382B"),
backgroundColor: HexColor("#B8382B"),
textColor: Colors.white,
fontSize: SizeConfig.textMultiplier * 2.0,
handler: () async {
await model.postUCAF(patient);
if (model.state == ViewState.Idle) {
DrAppToastMsg.showSuccesToast(
TranslationBase.of(context).postUcafSuccessMsg);
Navigator.of(context).popUntil((route) {
return route.settings.name == PATIENTS_PROFILE;
});
} else {
DrAppToastMsg.showErrorToast(model.error);
}
},
),
),
),
],
),
),
],
),
));

@ -1,6 +1,7 @@
import 'package:doctor_app_flutter/config/config.dart';
import 'package:doctor_app_flutter/config/size_config.dart';
import 'package:doctor_app_flutter/core/viewModel/patient-ucaf-viewmodel.dart';
import 'package:doctor_app_flutter/icons_app/doctor_app_icons.dart';
import 'package:doctor_app_flutter/models/patient/patiant_info_model.dart';
import 'package:doctor_app_flutter/screens/base/base_view.dart';
import 'package:doctor_app_flutter/screens/patients/profile/UCAF/page-stepper-widget.dart';
@ -115,7 +116,8 @@ class _UCAFInputScreenState extends State<UCAFInputScreen> {
title: AppText(
TranslationBase.of(context).inPatient,
fontWeight: FontWeight.normal,
fontSize: SizeConfig.textMultiplier * 2.1,
fontFamily: 'Poppins',
fontSize: SizeConfig.textMultiplier * 2.2,
),
value: _inPatient,
onChanged: (newValue) {
@ -123,6 +125,7 @@ class _UCAFInputScreenState extends State<UCAFInputScreen> {
_inPatient = newValue;
});
},
activeColor: HexColor("#D02127"),
controlAffinity:
ListTileControlAffinity.leading,
contentPadding: EdgeInsets.all(0),
@ -131,7 +134,8 @@ class _UCAFInputScreenState extends State<UCAFInputScreen> {
title: AppText(
TranslationBase.of(context).emergencyCase,
fontWeight: FontWeight.normal,
fontSize: SizeConfig.textMultiplier * 2.1,
fontFamily: 'Poppins',
fontSize: SizeConfig.textMultiplier * 2.2,
),
value: _emergencyCase,
onChanged: (newValue) {
@ -139,14 +143,14 @@ class _UCAFInputScreenState extends State<UCAFInputScreen> {
_emergencyCase = newValue;
});
},
activeColor: HexColor("#D02127"),
controlAffinity:
ListTileControlAffinity.leading,
contentPadding: EdgeInsets.all(0),
),
AppTextFieldCustom(
height: screenSize.height * 0.075,
hintText:
TranslationBase.of(context).durationOfIllness,
hintText: TranslationBase.of(context)
.durationOfIllness,
dropDownText: "3",
inputType: TextInputType.number,
inputFormatters: [
@ -163,6 +167,14 @@ class _UCAFInputScreenState extends State<UCAFInputScreen> {
children: [
Row(
children: [
Icon(
DoctorApp.warning,
size: 20,
color: Color(0xFFCC9B14),
),
SizedBox(
width: 8,
),
AppText(
"BP (H/L)",
fontSize:
@ -183,7 +195,7 @@ class _UCAFInputScreenState extends State<UCAFInputScreen> {
],
),
SizedBox(
width: 4,
width: 6,
),
Expanded(
child: Row(
@ -196,7 +208,7 @@ class _UCAFInputScreenState extends State<UCAFInputScreen> {
fontWeight: FontWeight.normal,
),
SizedBox(
width: 8,
width: 4,
),
Expanded(
child: AppText(
@ -213,7 +225,7 @@ class _UCAFInputScreenState extends State<UCAFInputScreen> {
],
),
SizedBox(
height: 4,
height: 2,
),
Row(
mainAxisAlignment:
@ -222,14 +234,14 @@ class _UCAFInputScreenState extends State<UCAFInputScreen> {
Row(
children: [
AppText(
"${TranslationBase.of(context).pulseBeats} :",
"${TranslationBase.of(context).pulseBeats}:",
fontSize:
SizeConfig.textMultiplier * 1.8,
color: Colors.black,
fontWeight: FontWeight.normal,
),
SizedBox(
width: 8,
width: 4,
),
AppText(
"${model.patientVitalSigns.pulseBeatPerMinute}",
@ -246,10 +258,12 @@ class _UCAFInputScreenState extends State<UCAFInputScreen> {
height: 16,
),
AppText(
TranslationBase.of(context).chiefComplaintsAndSymptoms,
TranslationBase.of(context)
.chiefComplaintsAndSymptoms,
fontFamily: 'Poppins',
fontSize: SizeConfig.textMultiplier * 2.1,
fontSize: SizeConfig.textMultiplier * 2.2,
fontWeight: FontWeight.w700,
color: Color(0xFF2E303A),
),
SizedBox(
height: 4,
@ -259,13 +273,15 @@ class _UCAFInputScreenState extends State<UCAFInputScreen> {
.patientFeelsPainInHisBackAndCough,
fontFamily: 'Poppins',
fontWeight: FontWeight.normal,
color: Color(0xFF575757),
fontSize: SizeConfig.textMultiplier * 1.8,
),
SizedBox(
height: 8,
),
AppTextFieldCustom(
hintText: TranslationBase.of(context).instruction,
hintText:
TranslationBase.of(context).instruction,
dropDownText: helpers.parseHtmlString(model
.patientChiefComplaintList[0]
.chiefComplaint),
@ -281,16 +297,18 @@ class _UCAFInputScreenState extends State<UCAFInputScreen> {
AppText(
TranslationBase.of(context).otherConditions,
fontWeight: FontWeight.bold,
fontSize: SizeConfig.textMultiplier * 2.0,
fontSize: SizeConfig.textMultiplier * 2.1,
color: Color(0xFF2E303A),
),
...List.generate(
conditionsData.length,
(index) => CheckboxListTile(
title: AppText(
conditionsData[index]['name'],
fontWeight: FontWeight.bold,
fontWeight: FontWeight.normal,
fontSize:
SizeConfig.textMultiplier * 2.1,
fontFamily: 'Poppins',
),
value: conditionsData[index]
['isChecked'],
@ -307,115 +325,76 @@ class _UCAFInputScreenState extends State<UCAFInputScreen> {
SizedBox(
height: 8,
),
Container(
height: screenSize.height * 0.070,
child: TextField(
decoration:
Helpers.textFieldSelectorDecoration(
TranslationBase.of(context).other,
null,
false),
enabled: true,
controller: _otherController,
keyboardType: TextInputType.text,
)),
AppTextFieldCustom(
hintText: TranslationBase.of(context).other,
dropDownText: "None",
enabled: false,
),
SizedBox(
height: 8,
),
Container(
height: screenSize.height * 0.070,
child: TextField(
decoration:
Helpers.textFieldSelectorDecoration(
TranslationBase.of(context).how,
null,
false),
enabled: true,
controller: _howController,
keyboardType: TextInputType.text,
)),
AppTextFieldCustom(
hintText: TranslationBase.of(context).how,
dropDownText: "None",
enabled: false,
),
SizedBox(
height: 8,
),
Row(
children: [
Expanded(
child: Container(
height: screenSize.height * 0.070,
child: TextField(
decoration: Helpers
.textFieldSelectorDecoration(
TranslationBase.of(context)
.when,
null,
false),
enabled: true,
controller: _whenController,
keyboardType: TextInputType.text,
)),
child: AppTextFieldCustom(
hintText:
TranslationBase.of(context).when,
dropDownText: "None",
enabled: false,
),
),
SizedBox(
width: 4,
),
Expanded(
child: Container(
height: screenSize.height * 0.070,
child: TextField(
decoration: Helpers
.textFieldSelectorDecoration(
TranslationBase.of(context)
.where,
null,
false),
enabled: true,
controller: _whereController,
keyboardType: TextInputType.text,
)),
child: AppTextFieldCustom(
hintText:
TranslationBase.of(context).where,
dropDownText: "None",
enabled: false,
),
),
],
),
SizedBox(
height: 8,
),
Container(
child: TextField(
decoration:
Helpers.textFieldSelectorDecoration(
TranslationBase.of(context)
.specifyPossibleLineManagement,
null,
false),
enabled: true,
controller: _managementsLineController,
keyboardType: TextInputType.text,
AppTextFieldCustom(
height: screenSize.height * 0.1,
hintText: TranslationBase.of(context)
.specifyPossibleLineManagement,
dropDownText: "None",
enabled: false,
minLines: 4,
maxLines: 6,
)),
),
SizedBox(
height: 16,
height: 26,
),
AppText(
TranslationBase.of(context).significantSigns,
fontWeight: FontWeight.bold,
fontSize: SizeConfig.textMultiplier * 2.0,
fontFamily: 'Poppins',
fontSize: SizeConfig.textMultiplier * 2.2,
),
SizedBox(
height: 8,
),
Container(
child: TextField(
decoration:
Helpers.textFieldSelectorDecoration(
TranslationBase.of(context)
.backAbdomen,
null,
false),
enabled: true,
controller: _signsController,
keyboardType: TextInputType.multiline,
minLines: null,
maxLines: null,
)),
AppTextFieldCustom(
height: screenSize.height * 0.1,
hintText:
TranslationBase.of(context).backAbdomen,
dropDownText: "BackLNeck",
enabled: false,
),
],
),
),
@ -430,7 +409,11 @@ class _UCAFInputScreenState extends State<UCAFInputScreen> {
color: HexColor("#D02127"),
onPressed: () {
Navigator.of(context).pushNamed(PATIENT_UCAF_DETAIL,
arguments: {'patient': patient});
arguments: {
'patient': patient,
'patientType': patientType,
'arrivalType': arrivalType
});
},
),
),

@ -4,6 +4,15 @@ import 'package:doctor_app_flutter/widgets/shared/app_texts_widget.dart';
import 'package:flutter/material.dart';
import 'package:hexcolor/hexcolor.dart';
/// *
/// By Mousa Zaid Mousa Abuzaid
/// At 13/4/2021
/*
All hex value from 100% to 0% alpha: used in line 122
https://gist.github.com/lopspower/03fb1cc0ac9f32ef38f4
*/
class PageStepperWidget extends StatelessWidget {
final int stepsCount;
final int currentStepIndex;
@ -38,6 +47,7 @@ class PageStepperWidget extends StatelessWidget {
}
class StepWidget extends StatelessWidget {
final int index;
final bool isInProgress;
final bool isFinalStep;
@ -68,27 +78,28 @@ class StepWidget extends StatelessWidget {
Container(
padding: EdgeInsets.all(0.0),
margin: EdgeInsets.symmetric(horizontal: 1),
width: 25,
height: 25,
width: 30,
height: 30,
decoration: BoxDecoration(
color: isInProgress ? Color(0xFFCC9B14) : Color(0xFFC9C9C9),
color: status == StepStatus.InProgress ? Color(0xFFCC9B14) : status == StepStatus.Locked ? Color(0xFFE3E3E3) : Color(0xFF359846),
shape: BoxShape.circle,
border: Border.all(
color: isInProgress ? Color(0xFFCC9B14) : Color(0xFFC9C9C9),
color: status == StepStatus.InProgress ? Color(0xFFCC9B14) : status == StepStatus.Locked ? Color(0xFFE3E3E3) : Color(0xFF359846),
width: 1),
),
child: Center(
child: Icon(
Icons.check,
size: 20,
color: status == StepStatus.InProgress ? Colors.white : status == StepStatus.Locked ? Colors.grey.shade800 : Color(0xFF359846),
color: status == StepStatus.Locked ? Color(0xFF969696) : Colors.white,
)),
),
if (!isFinalStep)
Container(
margin: EdgeInsets.symmetric(horizontal: 4),
width: dividerWidth,
height: 2,
color: Colors.grey,
color: status == StepStatus.Completed ? Color(0xFF359846) : Color(0xFFCCCCCC),
),
],
),
@ -98,23 +109,27 @@ class StepWidget extends StatelessWidget {
AppText(
"${TranslationBase.of(context).step} $index",
fontWeight: FontWeight.bold,
color: status == StepStatus.InProgress ? Colors.black : status == StepStatus.Locked ? Colors.grey : Color(0xFF359846),
color: status == StepStatus.Locked ? Color(0xFF969696) : Colors.black,
fontFamily: 'Poppins',
fontSize: SizeConfig.textMultiplier * 1.6,
),
Container(
margin: EdgeInsets.symmetric(vertical: 4),
padding: EdgeInsets.symmetric(horizontal: 4, vertical: 2),
padding: EdgeInsets.symmetric(horizontal: 12, vertical: 4),
decoration: BoxDecoration(
color: status == StepStatus.InProgress
? Color(0xFFF1E9D3)
: status == StepStatus.Locked
? Color(0xFFD8E8DB)
: Color(0xFFCCCCCC),
? Color(0x29797979)
: Color(0xFFD8E8D8),
borderRadius: BorderRadius.all(
Radius.circular(8.0),
Radius.circular(4.0),
),
border: Border.all(color: HexColor('#707070'), width: 0.30),
border: Border.all(color: status == StepStatus.InProgress
? Color(0xFFF1E9D3)
: status == StepStatus.Locked
? Color(0x29797979)
: Color(0xFFD8E8D8), width: 0.30),
),
child: AppText(
status == StepStatus.InProgress

@ -118,14 +118,14 @@ class _AdmissionRequestThirdScreenState
hintText: TranslationBase.of(context).clinic,
isDropDown: true,
dropDownText: _selectedClinic != null
? _selectedClinic['clinicGroupName']
? projectViewModel.isArabic? _selectedClinic['clinicNameArabic'] : _selectedClinic['clinicNameEnglish']
: null,
enabled: false,
onClick: model.clinicList != null &&
model.clinicList.length > 0
? () {
openListDialogField(
'clinicGroupName',
projectViewModel.isArabic? 'clinicNameArabic' : 'clinicNameEnglish',
'clinicID',
model.clinicList, (selectedValue) {
setState(() {
@ -142,7 +142,7 @@ class _AdmissionRequestThirdScreenState
if (model.state == ViewState.Idle &&
model.clinicList.length > 0) {
openListDialogField(
'clinicGroupName',
projectViewModel.isArabic? 'clinicNameArabic' : 'clinicNameEnglish',
'clinicID',
model.clinicList, (selectedValue) {
setState(() {

@ -43,6 +43,8 @@ class _LaboratoryResultPageState extends State<LaboratoryResultPage> {
orderNo: widget.patientLabOrders.orderNo,
appointmentDate:widget.patientLabOrders.orderDate,
doctorName: widget.patientLabOrders.doctorName,
branch: widget.patientLabOrders.projectName,
clinic: widget.patientLabOrders.clinicDescription,
profileUrl: widget.patientLabOrders.doctorImageURL,
invoiceNO: widget.patientLabOrders.invoiceNo,
),

@ -36,7 +36,8 @@ class LabsHomePage extends StatelessWidget {
builder: (context, ProcedureViewModel model, widget) => AppScaffold(
baseViewModel: model,
isShowAppBar: true,
appBar: PatientProfileHeaderNewDesignAppBar(patient, patient.patientType.toString() ?? '0', patientType),
appBar: PatientProfileHeaderNewDesignAppBar(
patient, patient.patientType.toString() ?? '0', patientType),
body: SingleChildScrollView(
physics: BouncingScrollPhysics(),
child: FractionallySizedBox(
@ -66,11 +67,24 @@ class LabsHomePage extends StatelessWidget {
],
),
),
if (patientType != null && patientType == '7' && patient.patientStatusType == 43)
if (patientType != null &&
patientType == '7' &&
patient.patientStatusType == 43)
InkWell(
onTap: () {
addSelectedLabOrder(context, model, patient);
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => AddSelectedLabOrder(
patient: patient,
model: model,
)),
);
},
// () {
// addSelectedLabOrder(context, model, patient);
// },
child: Container(
width: double.maxFinite,
height: 140,
@ -136,6 +150,7 @@ class LabsHomePage extends StatelessWidget {
invoiceNO: ' ${labOrder.invoiceNo}',
profileUrl: labOrder.doctorImageURL,
branch: labOrder.projectName,
clinic: labOrder.clinicDescription,
appointmentDate: labOrder.orderDate,
orderNo: labOrder.orderNo,
);

@ -43,6 +43,8 @@ class RadiologyDetailsPage extends StatelessWidget {
arrivalType: arrivalType ?? "0",
appointmentDate: finalRadiology.orderDate,
doctorName: finalRadiology.doctorName,
clinic: finalRadiology.clinicDescription,
branch: finalRadiology.projectName,
profileUrl: finalRadiology.doctorImageURL,
invoiceNO: finalRadiology.invoiceNo.toString(),
),
@ -54,6 +56,7 @@ class RadiologyDetailsPage extends StatelessWidget {
crossAxisAlignment: CrossAxisAlignment.center,
children: <Widget>[
Container(
width: double.maxFinite,
margin: EdgeInsets.all(8),
decoration: BoxDecoration(
color: Colors.white,

@ -33,7 +33,8 @@ class RadiologyHomePage extends StatelessWidget {
builder: (_, model, widget) => AppScaffold(
isShowAppBar: true,
// appBarTitle: TranslationBase.of(context).radiology,
appBar: PatientProfileHeaderNewDesignAppBar(patient, patient.patientType.toString() ?? '0', arrivalType),
appBar: PatientProfileHeaderNewDesignAppBar(
patient, patient.patientType.toString() ?? '0', arrivalType),
baseViewModel: model,
body: FractionallySizedBox(
widthFactor: 1.0,
@ -62,11 +63,23 @@ class RadiologyHomePage extends StatelessWidget {
],
),
),
if (patientType != null && patientType == '7' && patient.patientStatusType == 43)
if (patientType != null &&
patientType == '7' &&
patient.patientStatusType == 43)
InkWell(
onTap: () {
addSelectedRadiologyOrder(context, model, patient);
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => AddSelectedRadiologyOrder(
patient: patient,
model: model,
)),
);
},
// () {
// addSelectedRadiologyOrder(context, model, patient);
// },
child: Container(
width: double.maxFinite,
height: 140,
@ -108,25 +121,27 @@ class RadiologyHomePage extends StatelessWidget {
),
),
),
...List.generate(model.radiologyList.length, (index) => InkWell(
onTap: () => Navigator.push(
context,
FadePage(
page: RadiologyDetailsPage(
finalRadiology: model.radiologyList[index],
patient: patient,
),
),
),
child: DoctorCard(
doctorName: model.radiologyList[index].doctorName,
profileUrl: model.radiologyList[index].doctorImageURL,
invoiceNO: '${model.radiologyList[index].invoiceNo}',
branch: '${model.radiologyList[index].projectName}',
...List.generate(
model.radiologyList.length,
(index) => InkWell(
onTap: () => Navigator.push(
context,
FadePage(
page: RadiologyDetailsPage(
finalRadiology: model.radiologyList[index],
patient: patient,
),
),
),
child: DoctorCard(
doctorName: model.radiologyList[index].doctorName,
profileUrl: model.radiologyList[index].doctorImageURL,
invoiceNO: '${model.radiologyList[index].invoiceNo}',
branch: '${model.radiologyList[index].projectName}',
clinic: model.radiologyList[index].clinicDescription,
appointmentDate: model.radiologyList[index].orderDate,
),
)),
],
),
),

@ -44,12 +44,12 @@ class _PatientReferralScreen extends State<PatientReferralScreen>
child: Container(
height: 60.0,
// margin: EdgeInsets.only(top: 10.0),
width: MediaQuery.of(context).size.width * 0.92, // 0.9,
width: MediaQuery.of(context).size.width * 1, // 0.92,
decoration: BoxDecoration(
border: Border(
bottom: BorderSide(
color: Theme.of(context).dividerColor,
width: 0.9), //width: 0.7
width: 1), //width: 0.7
),
color: Colors.white),
child: Center(
@ -68,7 +68,7 @@ class _PatientReferralScreen extends State<PatientReferralScreen>
width: MediaQuery.of(context).size.width * 0.30,
child: Center(
child:
AppText(TranslationBase.of(context).myReferral),
AppText(TranslationBase.of(context).referral),
),
),
Container(

@ -10,6 +10,7 @@ import 'package:doctor_app_flutter/util/helpers.dart';
import 'package:doctor_app_flutter/util/translations_delegate_base.dart';
import 'package:doctor_app_flutter/widgets/patients/patient-referral-item-widget.dart';
import 'package:doctor_app_flutter/widgets/patients/profile/patient-page-header-widget.dart';
import 'package:doctor_app_flutter/widgets/patients/profile/patient-profile-header-new-design-app-bar.dart';
import 'package:doctor_app_flutter/widgets/patients/profile/patient-profile-header-new-design.dart';
import 'package:doctor_app_flutter/widgets/shared/app-textfield-custom.dart';
import 'package:doctor_app_flutter/widgets/shared/app_buttons_widget.dart';
@ -38,6 +39,11 @@ class _PatientMakeReferralScreenState extends State<PatientMakeReferralScreen> {
DateTime appointmentDate;
final _remarksController = TextEditingController();
String branchError = null;
String hospitalError = null;
String clinicError = null;
String doctorError = null;
@override
void initState() {
super.initState();
@ -71,7 +77,9 @@ class _PatientMakeReferralScreenState extends State<PatientMakeReferralScreen> {
builder: (_, model, w) => AppScaffold(
baseViewModel: model,
appBarTitle: TranslationBase.of(context).referPatient,
isShowAppBar: false,
isShowAppBar: true,
appBar: PatientProfileHeaderNewDesignAppBar(
patient, patientType, arrivalType),
body: SingleChildScrollView(
child: Container(
child: Column(
@ -80,8 +88,8 @@ class _PatientMakeReferralScreenState extends State<PatientMakeReferralScreen> {
Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
PatientProfileHeaderNewDesign(
patient, patientType, arrivalType),
/*PatientProfileHeaderNewDesign(
patient, patientType, arrivalType),*/
Container(
margin: EdgeInsets.all(16.0),
child: Column(
@ -145,6 +153,28 @@ class _PatientMakeReferralScreenState extends State<PatientMakeReferralScreen> {
fontWeight: FontWeight.w700,
color: HexColor("#359846"),
onPressed: () {
setState(() {
if(_referTo == null){
branchError = TranslationBase.of(context).fieldRequired;
}else {
branchError = null;
}
if(_selectedBranch == null){
hospitalError = TranslationBase.of(context).fieldRequired;
}else {
hospitalError = null;
}
if(_selectedClinic == null){
clinicError = TranslationBase.of(context).fieldRequired;
}else {
clinicError = null;
}
if(_selectedDoctor == null){
doctorError = TranslationBase.of(context).fieldRequired;
}else {
doctorError = null;
}
});
if (appointmentDate == null ||
_selectedBranch == null ||
_selectedClinic == null ||
@ -186,6 +216,7 @@ class _PatientMakeReferralScreenState extends State<PatientMakeReferralScreen> {
dropDownText: _referTo != null ? _referTo['name'] : null,
enabled: false,
isDropDown: true,
validationError: branchError,
onClick: referToList != null
? () {
ListSelectDialog dialog = ListSelectDialog(
@ -238,6 +269,7 @@ class _PatientMakeReferralScreenState extends State<PatientMakeReferralScreen> {
: null,
enabled: false,
isDropDown: true,
validationError: hospitalError,
onClick: model.branchesList != null &&
model.branchesList.length > 0 &&
_referTo != null &&
@ -285,6 +317,7 @@ class _PatientMakeReferralScreenState extends State<PatientMakeReferralScreen> {
: null,
enabled: false,
isDropDown: true,
validationError: clinicError,
onClick: _selectedBranch != null &&
model.clinicsList != null &&
model.clinicsList.length > 0
@ -332,6 +365,7 @@ class _PatientMakeReferralScreenState extends State<PatientMakeReferralScreen> {
_selectedDoctor != null ? _selectedDoctor['DoctorName'] : null,
enabled: false,
isDropDown: true,
validationError: doctorError,
onClick: _selectedClinic != null &&
model.doctorsList != null &&
model.doctorsList.length > 0
@ -357,7 +391,13 @@ class _PatientMakeReferralScreenState extends State<PatientMakeReferralScreen> {
},
);
}
: null,
: (){
if(_selectedClinic == null){
DrAppToastMsg.showErrorToast("You need to select a clinic first");
} else if(model.doctorsList == null || model.doctorsList.length == 0){
DrAppToastMsg.showErrorToast("There is no doctors for this clinic");
}
},
),
SizedBox(
height: 10,

@ -90,10 +90,10 @@ class LineChartCurvedBloodPressure extends StatelessWidget {
height: 20,
decoration: BoxDecoration(
shape: BoxShape.rectangle,
color: Colors.grey),
color: Colors.red),
),
SizedBox(width: 5,),
AppText(TranslationBase.of(context).diastolicLng)
AppText(TranslationBase.of(context).diastolicLng,)
],
),
],
@ -248,7 +248,7 @@ class LineChartCurvedBloodPressure extends StatelessWidget {
final LineChartBarData lineChartBarData2 = LineChartBarData(
spots: spots2,
isCurved: true,
colors: [Colors.grey],
colors: [Colors.red],
barWidth: 5,
isStrokeCapRound: true,
dotData: FlDotData(

@ -51,7 +51,7 @@ class VitalSignItem extends StatelessWidget {
"$lastVal",
fontFamily: 'Poppins',
fontSize: SizeConfig.textMultiplier * 1.4,
fontWeight: FontWeight.w800,
fontWeight: FontWeight.bold,
margin: 0,
),
Expanded(
@ -88,7 +88,7 @@ class VitalSignItem extends StatelessWidget {
"$des",
fontFamily: 'Poppins',
fontSize: SizeConfig.textMultiplier * 1.3,
fontWeight: FontWeight.w600,
fontWeight: FontWeight.bold,
),
),
),

File diff suppressed because it is too large Load Diff

@ -36,6 +36,7 @@ class PrescriptionItemsPage extends StatelessWidget {
patientType: patientType??"0",
arrivalType: arrivalType??"0",
clinic: prescriptions.clinicDescription,
branch: prescriptions.name,
isPrescriptions: true,
appointmentDate: DateUtils.getDateTimeFromServerFormat(prescriptions.appointmentDate),
doctorName: prescriptions.doctorName,

@ -1,5 +1,6 @@
import 'package:doctor_app_flutter/core/model/procedure/get_ordered_procedure_model.dart';
import 'package:doctor_app_flutter/core/viewModel/project_view_model.dart';
import 'package:doctor_app_flutter/icons_app/doctor_app_icons.dart';
import 'package:doctor_app_flutter/util/date-utils.dart';
import 'package:doctor_app_flutter/util/translations_delegate_base.dart';
import 'package:doctor_app_flutter/widgets/shared/Text.dart';
@ -147,7 +148,7 @@ class ProcedureCard extends StatelessWidget {
color: Colors.grey,
),
Texts(
entityList.clinicDescription.toString(),
entityList.clinicDescription??"",
bold: true,
fontSize: 12,
),
@ -163,7 +164,7 @@ class ProcedureCard extends StatelessWidget {
if (entityList.categoryID == 2 ||
entityList.categoryID == 4)
InkWell(
child: Icon(Icons.edit),
child: Icon(DoctorApp.edit),
onTap: onTap,
)
],

@ -343,6 +343,8 @@ class _AddSelectedProcedureState extends State<AddSelectedProcedure> {
AppButton(
title: TranslationBase.of(context)
.addSelectedProcedures,
color: Color(0xff359846),
fontWeight: FontWeight.w700,
onPressed: () {
//print(entityList.toString());
onPressed:

@ -12,6 +12,7 @@ import 'package:doctor_app_flutter/util/dr_app_toast_msg.dart';
import 'package:doctor_app_flutter/util/translations_delegate_base.dart';
import 'package:doctor_app_flutter/widgets/shared/TextFields.dart';
import 'package:doctor_app_flutter/widgets/shared/app_buttons_widget.dart';
import 'package:doctor_app_flutter/widgets/shared/app_scaffold_widget.dart';
import 'package:doctor_app_flutter/widgets/shared/app_texts_widget.dart';
import 'package:doctor_app_flutter/widgets/shared/dialogs/dailog-list-select.dart';
import 'package:doctor_app_flutter/widgets/shared/network_base_view.dart';
@ -142,157 +143,158 @@ class _AddSelectedLabOrderState extends State<AddSelectedLabOrder> {
onModelReady: (model) => model.getProcedureCategory(
categoryName: "Laboratory", categoryID: "02"),
builder: (BuildContext context, ProcedureViewModel model, Widget child) =>
NetworkBaseView(
baseViewModel: model,
child: DraggableScrollableSheet(
minChildSize: 0.90,
initialChildSize: 0.95,
maxChildSize: 1.0,
builder: (BuildContext context, ScrollController scrollController) {
return SingleChildScrollView(
child: Container(
height: MediaQuery.of(context).size.height * 1.20,
child: Padding(
padding: EdgeInsets.all(12.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Column(
children: [
Row(
children: [
InkWell(
child: Icon(
Icons.close,
size: 24.0,
),
onTap: () {
Navigator.pop(context);
},
),
],
),
Row(
children: [
AppText(
'New Lab Order',
fontWeight: FontWeight.w700,
fontSize: 20,
AppScaffold(
isShowAppBar: false,
body: NetworkBaseView(
baseViewModel: model,
child: DraggableScrollableSheet(
minChildSize: 0.90,
initialChildSize: 0.95,
maxChildSize: 1.0,
builder:
(BuildContext context, ScrollController scrollController) {
return SingleChildScrollView(
child: Container(
height: MediaQuery.of(context).size.height * 1.0,
child: Padding(
padding: EdgeInsets.all(12.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Row(
children: [
AppText(
'New Lab Order',
fontWeight: FontWeight.w700,
fontSize: 20,
),
SizedBox(
width: MediaQuery.of(context).size.width * 0.48,
),
InkWell(
child: Icon(
Icons.close,
size: 28.0,
),
],
),
],
),
SizedBox(
height: 10.0,
),
if (widget.model.categoriesList.length != 0)
NetworkBaseView(
baseViewModel: model,
child: EntityListCheckboxSearchWidget(
model: widget.model,
masterList:
widget.model.categoriesList[0].entityList,
removeHistory: (item) {
setState(() {
entityList.remove(item);
});
},
addHistory: (history) {
setState(() {
entityList.add(history);
});
},
addSelectedHistories: () {
//TODO build your fun herr
// widget.addSelectedHistories();
onTap: () {
Navigator.pop(context);
},
isEntityListSelected: (master) =>
isEntityListSelected(master),
)),
SizedBox(
height: 15.0,
),
Column(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
// Container(
// child: Row(
// children: [
// AppText(
// TranslationBase.of(context).orderType),
// Radio(
// activeColor: Color(0xFFB9382C),
// value: 1,
// groupValue: selectedType,
// onChanged: (value) {
// setSelectedType(value);
// },
// ),
// Text('routine'),
// Radio(
// activeColor: Color(0xFFB9382C),
// groupValue: selectedType,
// value: 0,
// onChanged: (value) {
// setSelectedType(value);
// },
// ),
// Text(TranslationBase.of(context).urgent),
// ],
// ),
// ),
// SizedBox(
// height: 15.0,
// ),
// TextFields(
// hintText: TranslationBase.of(context).remarks,
// controller: remarksController,
// minLines: 3,
// maxLines: 5,
// ),
SizedBox(
height: 100.0,
),
Container(
margin: EdgeInsets.all(
SizeConfig.widthMultiplier * 5),
child: Wrap(
alignment: WrapAlignment.center,
children: <Widget>[
AppButton(
title: TranslationBase.of(context)
.addSelectedProcedures,
color: Color(0xff359846),
onPressed: () {
//print(entityList.toString());
onPressed:
if (entityList.isEmpty == true) {
DrAppToastMsg.showErrorToast(
"Fill the mandatory procedure details");
return;
}
),
],
),
SizedBox(
height: 10.0,
),
if (widget.model.categoriesList.length != 0)
NetworkBaseView(
baseViewModel: model,
child: EntityListCheckboxSearchWidget(
model: widget.model,
masterList:
widget.model.categoriesList[0].entityList,
removeHistory: (item) {
setState(() {
entityList.remove(item);
});
},
addHistory: (history) {
setState(() {
entityList.add(history);
});
},
addSelectedHistories: () {
//TODO build your fun herr
// widget.addSelectedHistories();
},
isEntityListSelected: (master) =>
isEntityListSelected(master),
)),
SizedBox(
height: 15.0,
),
Column(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
// Container(
// child: Row(
// children: [
// AppText(
// TranslationBase.of(context).orderType),
// Radio(
// activeColor: Color(0xFFB9382C),
// value: 1,
// groupValue: selectedType,
// onChanged: (value) {
// setSelectedType(value);
// },
// ),
// Text('routine'),
// Radio(
// activeColor: Color(0xFFB9382C),
// groupValue: selectedType,
// value: 0,
// onChanged: (value) {
// setSelectedType(value);
// },
// ),
// Text(TranslationBase.of(context).urgent),
// ],
// ),
// ),
// SizedBox(
// height: 15.0,
// ),
// TextFields(
// hintText: TranslationBase.of(context).remarks,
// controller: remarksController,
// minLines: 3,
// maxLines: 5,
// ),
SizedBox(
height: 100.0,
),
Container(
margin: EdgeInsets.all(
SizeConfig.widthMultiplier * 5),
child: Wrap(
alignment: WrapAlignment.center,
children: <Widget>[
AppButton(
title:
"Add Lab Order", //TranslationBase.of(context)
fontWeight: FontWeight.w700,
//.addSelectedProcedures,
color: Color(0xff359846),
onPressed: () {
//print(entityList.toString());
onPressed:
if (entityList.isEmpty == true) {
DrAppToastMsg.showErrorToast(
"Fill the mandatory procedure details");
return;
}
Navigator.pop(context);
postProcedure(
orderType: selectedType.toString(),
entityList: entityList,
patient: patient,
model: widget.model,
remarks: remarksController.text);
},
),
],
Navigator.pop(context);
postProcedure(
orderType: selectedType.toString(),
entityList: entityList,
patient: patient,
model: widget.model,
remarks: remarksController.text);
},
),
],
),
),
),
],
)
],
],
)
],
),
),
),
),
);
}),
);
}),
),
),
);
}

@ -12,6 +12,7 @@ import 'package:doctor_app_flutter/util/dr_app_toast_msg.dart';
import 'package:doctor_app_flutter/util/translations_delegate_base.dart';
import 'package:doctor_app_flutter/widgets/shared/TextFields.dart';
import 'package:doctor_app_flutter/widgets/shared/app_buttons_widget.dart';
import 'package:doctor_app_flutter/widgets/shared/app_scaffold_widget.dart';
import 'package:doctor_app_flutter/widgets/shared/app_texts_widget.dart';
import 'package:doctor_app_flutter/widgets/shared/dialogs/dailog-list-select.dart';
import 'package:doctor_app_flutter/widgets/shared/network_base_view.dart';
@ -142,157 +143,156 @@ class _AddSelectedRadiologyOrderState extends State<AddSelectedRadiologyOrder> {
onModelReady: (model) => model.getProcedureCategory(
categoryName: "Radiology", categoryID: "03"),
builder: (BuildContext context, ProcedureViewModel model, Widget child) =>
NetworkBaseView(
baseViewModel: model,
child: DraggableScrollableSheet(
minChildSize: 0.90,
initialChildSize: 0.95,
maxChildSize: 1.0,
builder: (BuildContext context, ScrollController scrollController) {
return SingleChildScrollView(
child: Container(
height: MediaQuery.of(context).size.height * 1.20,
child: Padding(
padding: EdgeInsets.all(12.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Column(
children: [
Row(
children: [
InkWell(
child: Icon(
Icons.close,
size: 24.0,
),
onTap: () {
Navigator.pop(context);
},
),
],
),
Row(
children: [
AppText(
'New Radiology Order',
fontWeight: FontWeight.w700,
fontSize: 20,
AppScaffold(
isShowAppBar: false,
body: NetworkBaseView(
baseViewModel: model,
child: DraggableScrollableSheet(
minChildSize: 0.90,
initialChildSize: 0.95,
maxChildSize: 1.0,
builder:
(BuildContext context, ScrollController scrollController) {
return SingleChildScrollView(
child: Container(
height: MediaQuery.of(context).size.height * 1.0,
child: Padding(
padding: EdgeInsets.all(12.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Row(
children: [
AppText(
'New Radiology Order',
fontWeight: FontWeight.w700,
fontSize: 20,
),
SizedBox(
width: MediaQuery.of(context).size.width * 0.48,
),
InkWell(
child: Icon(
Icons.close,
size: 28.0,
),
],
),
],
),
SizedBox(
height: 10.0,
),
if (widget.model.categoriesList.length != 0)
NetworkBaseView(
baseViewModel: model,
child: EntityListCheckboxSearchWidget(
model: widget.model,
masterList:
widget.model.categoriesList[0].entityList,
removeHistory: (item) {
setState(() {
entityList.remove(item);
});
},
addHistory: (history) {
setState(() {
entityList.add(history);
});
},
addSelectedHistories: () {
//TODO build your fun herr
// widget.addSelectedHistories();
onTap: () {
Navigator.pop(context);
},
isEntityListSelected: (master) =>
isEntityListSelected(master),
)),
SizedBox(
height: 15.0,
),
Column(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
// Container(
// child: Row(
// children: [
// AppText(
// TranslationBase.of(context).orderType),
// Radio(
// activeColor: Color(0xFFB9382C),
// value: 1,
// groupValue: selectedType,
// onChanged: (value) {
// setSelectedType(value);
// },
// ),
// Text('routine'),
// Radio(
// activeColor: Color(0xFFB9382C),
// groupValue: selectedType,
// value: 0,
// onChanged: (value) {
// setSelectedType(value);
// },
// ),
// Text(TranslationBase.of(context).urgent),
// ],
// ),
// ),
// SizedBox(
// height: 15.0,
// ),
// TextFields(
// hintText: TranslationBase.of(context).remarks,
// controller: remarksController,
// minLines: 3,
// maxLines: 5,
// ),
SizedBox(
height: 100.0,
),
Container(
margin: EdgeInsets.all(
SizeConfig.widthMultiplier * 5),
child: Wrap(
alignment: WrapAlignment.center,
children: <Widget>[
AppButton(
title: TranslationBase.of(context)
.addSelectedProcedures,
color: Color(0xff359846),
onPressed: () {
//print(entityList.toString());
onPressed:
if (entityList.isEmpty == true) {
DrAppToastMsg.showErrorToast(
"Fill the mandatory procedure details");
return;
}
),
],
),
SizedBox(
height: 10.0,
),
if (widget.model.categoriesList.length != 0)
NetworkBaseView(
baseViewModel: model,
child: EntityListCheckboxSearchWidget(
model: widget.model,
masterList:
widget.model.categoriesList[0].entityList,
removeHistory: (item) {
setState(() {
entityList.remove(item);
});
},
addHistory: (history) {
setState(() {
entityList.add(history);
});
},
addSelectedHistories: () {
//TODO build your fun herr
// widget.addSelectedHistories();
},
isEntityListSelected: (master) =>
isEntityListSelected(master),
)),
SizedBox(
height: 15.0,
),
Column(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
// Container(
// child: Row(
// children: [
// AppText(
// TranslationBase.of(context).orderType),
// Radio(
// activeColor: Color(0xFFB9382C),
// value: 1,
// groupValue: selectedType,
// onChanged: (value) {
// setSelectedType(value);
// },
// ),
// Text('routine'),
// Radio(
// activeColor: Color(0xFFB9382C),
// groupValue: selectedType,
// value: 0,
// onChanged: (value) {
// setSelectedType(value);
// },
// ),
// Text(TranslationBase.of(context).urgent),
// ],
// ),
// ),
// SizedBox(
// height: 15.0,
// ),
// TextFields(
// hintText: TranslationBase.of(context).remarks,
// controller: remarksController,
// minLines: 3,
// maxLines: 5,
// ),
SizedBox(
height: 100.0,
),
Container(
margin: EdgeInsets.all(
SizeConfig.widthMultiplier * 5),
child: Wrap(
alignment: WrapAlignment.center,
children: <Widget>[
AppButton(
title: 'Add Radiology Order',
color: Color(0xff359846),
fontWeight: FontWeight.w700,
onPressed: () {
//print(entityList.toString());
onPressed:
if (entityList.isEmpty == true) {
DrAppToastMsg.showErrorToast(
"Fill the mandatory procedure details");
return;
}
Navigator.pop(context);
postProcedure(
orderType: selectedType.toString(),
entityList: entityList,
patient: patient,
model: widget.model,
remarks: remarksController.text);
},
),
],
Navigator.pop(context);
postProcedure(
orderType: selectedType.toString(),
entityList: entityList,
patient: patient,
model: widget.model,
remarks: remarksController.text);
},
),
],
),
),
),
],
)
],
],
)
],
),
),
),
),
);
}),
);
}),
),
),
);
}

@ -74,16 +74,18 @@ class _EntityListCheckboxSearchWidgetState
child: Container(
margin: EdgeInsets.only(top: 15),
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(12),
borderRadius: BorderRadius.circular(8),
color: Colors.white),
child: ListView(
children: [
TextFields(
hintText: TranslationBase.of(context).searchProcedures,
suffixIcon: EvaIcons.search,
suffixIconColor: Color(0xff2B353E),
onChanged: (value) {
filterSearchResults(value);
},
hasBorder: false,
),
SizedBox(
height: 15,
@ -99,7 +101,7 @@ class _EntityListCheckboxSearchWidgetState
Checkbox(
value: widget.isEntityListSelected(
historyInfo),
activeColor: Colors.red[800],
activeColor: Color(0xffD02127),
onChanged: (bool newValue) {
setState(() {
if (widget.isEntityListSelected(
@ -118,6 +120,7 @@ class _EntityListCheckboxSearchWidgetState
horizontal: 10, vertical: 0),
child: Texts(
historyInfo.procedureName,
fontSize: 14.0,
variant: "bodyText",
bold: true,
color: Color(0xff575757)),
@ -130,50 +133,80 @@ class _EntityListCheckboxSearchWidgetState
child: Padding(
padding: EdgeInsets.symmetric(
horizontal: 12),
child: Row(
child: Column(
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
AppText(
TranslationBase.of(context)
.orderType),
Radio(
activeColor: Color(0xFFB9382C),
value: 0,
groupValue: selectedType,
onChanged: (value) {
historyInfo.type =
setSelectedType(value)
.toString();
historyInfo.type =
value.toString();
},
Row(
children: [
Padding(
padding: const EdgeInsets
.symmetric(
horizontal: 11),
child: AppText(
TranslationBase.of(
context)
.orderType,
fontWeight:
FontWeight.w700,
color: Color(0xff2B353E),
),
),
],
),
Text('routine'),
Radio(
activeColor: Color(0xFFB9382C),
groupValue: selectedType,
value: 1,
onChanged: (value) {
historyInfo.type =
setSelectedType(value)
.toString();
Row(
children: [
Radio(
activeColor:
Color(0xFFD02127),
value: 0,
groupValue: selectedType,
onChanged: (value) {
historyInfo.type =
setSelectedType(value)
.toString();
historyInfo.type =
value.toString();
},
),
AppText(
'routine',
color: Color(0xff575757),
fontWeight: FontWeight.w600,
),
Radio(
activeColor:
Color(0xFFD02127),
groupValue: selectedType,
value: 1,
onChanged: (value) {
historyInfo.type =
setSelectedType(value)
.toString();
historyInfo.type =
value.toString();
},
historyInfo.type =
value.toString();
},
),
AppText(
TranslationBase.of(context)
.urgent,
color: Color(0xff575757),
fontWeight: FontWeight.w600,
),
],
),
Text(TranslationBase.of(context)
.urgent),
],
),
),
),
SizedBox(
height: 15.0,
height: 2.0,
),
Padding(
padding: EdgeInsets.symmetric(
horizontal: 12),
horizontal: 12, vertical: 12.0),
child: TextFields(
hintText: TranslationBase.of(context)
.remarks,
@ -183,11 +216,13 @@ class _EntityListCheckboxSearchWidgetState
},
minLines: 3,
maxLines: 5,
borderWidth: 0.5,
borderColor: Colors.grey[500],
),
),
DividerWithSpacesAround(),
],
),
DividerWithSpacesAround(),
],
);
}).toList(),

@ -29,122 +29,119 @@ class ProcedureScreen extends StatelessWidget {
builder: (BuildContext context, ProcedureViewModel model, Widget child) =>
AppScaffold(
isShowAppBar: true,
baseViewModel: model,
appBar: PatientProfileHeaderNewDesignAppBar(
patient, arrivalType ?? '0', patientType),
body: NetworkBaseView(
baseViewModel: model,
child: SingleChildScrollView(
child: Container(
color: Colors.white,
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
SizedBox(
height: 12,
),
Padding(
padding: const EdgeInsets.all(8.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Texts(
'Order Test or',
style: "caption2",
color: Colors.black,
fontSize: 13,
),
Texts(
'Procedure',
bold: true,
fontSize: 22,
),
],
),
body: SingleChildScrollView(
child: Container(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
SizedBox(
height: 12,
),
Padding(
padding: const EdgeInsets.all(8.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Texts(
'Order Test or',
style: "caption2",
color: Colors.black,
fontSize: 13,
),
Texts(
'Procedure',
bold: true,
fontSize: 22,
),
],
),
if (patientType != null && patientType == '7' && patient.patientStatusType == 43)
InkWell(
onTap: () {
addSelectedProcedure(context, model, patient);
},
child: Container(
width: double.maxFinite,
height: 140,
margin: EdgeInsets.all(10),
decoration: BoxDecoration(
color: Colors.grey[300],
borderRadius: BorderRadius.circular(10),
),
child: Center(
child: Container(
height: 90,
child: Column(
children: [
Container(
height: 40,
width: 40,
decoration: BoxDecoration(
color: Colors.grey[600],
borderRadius: BorderRadius.circular(10),
),
child: Center(
child: Icon(
Icons.add,
color: Colors.white,
),
),
),
if (patientType != null && patientType == '7' && patient.patientStatusType == 43)
InkWell(
onTap: () {
addSelectedProcedure(context, model, patient);
},
child: Container(
width: double.maxFinite,
height: 140,
margin: EdgeInsets.all(10),
decoration: BoxDecoration(
color: Colors.grey[300],
borderRadius: BorderRadius.circular(10),
),
child: Center(
child: Container(
height: 90,
child: Column(
children: [
Container(
height: 40,
width: 40,
decoration: BoxDecoration(
color: Colors.grey[600],
borderRadius: BorderRadius.circular(10),
),
SizedBox(
height: 10,
child: Center(
child: Icon(
Icons.add,
color: Colors.white,
),
),
Texts(
'Add More Procedure',
color: Colors.grey[600],
fontWeight: FontWeight.w600,
)
],
),
),
SizedBox(
height: 10,
),
Texts(
'Add More Procedure',
color: Colors.grey[600],
fontWeight: FontWeight.w600,
)
],
),
),
),
),
if (model.procedureList.isNotEmpty)
...List.generate(
model.procedureList[0].rowcount,
(index) => ProcedureCard(
categoryID:
model.procedureList[0].entityList[index].categoryID,
entityList: model.procedureList[0].entityList[index],
onTap: () {
if (model.procedureList[0].entityList[index].categoryID ==
2 ||
model.procedureList[0].entityList[index].categoryID == 4)
updateProcedureForm(context,
model: model,
patient: patient,
remarks: model
.procedureList[0].entityList[index].remarks,
orderType: model.procedureList[0]
.entityList[index].orderType
.toString(),
orderNo: model
.procedureList[0].entityList[index].orderNo,
procedureName: model.procedureList[0]
.entityList[index].procedureName,
categoreId: model.procedureList[0]
.entityList[index].categoryID
.toString(),
procedureId: model.procedureList[0]
.entityList[index].procedureId,
limetNo: model.procedureList[0]
.entityList[index].lineItemNo);
// } else
// helpers.showErrorToast(
// 'You Cant Update This Procedure');
},
),
),
if (model.procedureList.isNotEmpty)
...List.generate(
model.procedureList[0].rowcount,
(index) => ProcedureCard(
categoryID:
model.procedureList[0].entityList[index].categoryID,
entityList: model.procedureList[0].entityList[index],
onTap: () {
if (model.procedureList[0].entityList[index].categoryID ==
2 ||
model.procedureList[0].entityList[index].categoryID == 4)
updateProcedureForm(context,
model: model,
patient: patient,
remarks: model
.procedureList[0].entityList[index].remarks,
orderType: model.procedureList[0]
.entityList[index].orderType
.toString(),
orderNo: model
.procedureList[0].entityList[index].orderNo,
procedureName: model.procedureList[0]
.entityList[index].procedureName,
categoreId: model.procedureList[0]
.entityList[index].categoryID
.toString(),
procedureId: model.procedureList[0]
.entityList[index].procedureId,
limetNo: model.procedureList[0]
.entityList[index].lineItemNo);
// } else
// helpers.showErrorToast(
// 'You Cant Update This Procedure');
},
),
],
),
),
],
),
),
),

@ -1216,7 +1216,7 @@ class TranslationBase {
String get remove => localizedValues['remove'][locale.languageCode];
String get step => localizedValues['step'][locale.languageCode];
String get fieldRequired => localizedValues['fieldRequired'][locale.languageCode];
String get noSickLeave => localizedValues['no-sickleve'][locale.languageCode];
String get changeOfSchedule =>
localizedValues['changeOfSchedule'][locale.languageCode];

@ -319,7 +319,7 @@ class _KnownUserLoginState extends State<KnownUserLogin> {
}
navigateToHome() {
Navigator.of(context).pushNamed(HOME);
Navigator.of(context).pushReplacementNamed(HOME);
}
showErorrMsg(localMsg) {

@ -69,220 +69,232 @@ class _LoginFormState extends State<LoginForm> {
return Form(
key: loginFormKey,
child: Container(
width: SizeConfig.realScreenWidth * 0.90,
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
buildSizedBox(),
Padding(
child: AppText(
TranslationBase.of(context).enterCredentials,
fontSize: 18,
fontWeight: FontWeight.w600,
),
padding: EdgeInsets.only(top: 10, bottom: 10)),
Container(
decoration: BoxDecoration(
borderRadius: BorderRadius.all(Radius.circular(6.0)),
border: Border.all(
width: 1.0,
color: HexColor("#CCCCCC"),
),
color: Colors.white),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Padding(
padding: EdgeInsets.only(left: 10, top: 10),
child: AppText(
TranslationBase.of(context).enterId,
fontWeight: FontWeight.w600,
)),
AppTextFormField(
labelText: '',
borderColor: Colors.white,
// keyboardType: TextInputType.number,
textInputAction: TextInputAction.next,
// decoration: buildInputDecoration(
// context,
// TranslationBase.of(context).enterId,
// 'assets/images/user_id_icon.png'),
validator: (value) {
if (value != null && value.isEmpty) {
return TranslationBase.of(context)
.pleaseEnterYourID;
}
return null;
},
onSaved: (value) {
if (value != null) userInfo.userID = value.trim();
},
onChanged: (value) {
if (value != null) userInfo.userID = value.trim();
},
onFieldSubmitted: (_) {
focusPass.nextFocus();
},
// onEditingComplete: () {},
// autofocus: false,
)
])),
buildSizedBox(),
Container(
decoration: BoxDecoration(
borderRadius: BorderRadius.all(Radius.circular(6.0)),
border: Border.all(
width: 1.0,
color: HexColor("#CCCCCC"),
),
color: Colors.white),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Padding(
padding: EdgeInsets.only(left: 10, top: 10),
child: AppText(
TranslationBase.of(context).enterPassword,
fontWeight: FontWeight.w600,
)),
AppTextFormField(
focusNode: focusPass,
obscureText: true,
borderColor: Colors.white,
textInputAction: TextInputAction.next,
// decoration: buildInputDecoration(
// context,
// TranslationBase.of(context).enterPassword,
// 'assets/images/password_icon.png'),
validator: (value) {
if (value != null && value.isEmpty) {
return TranslationBase.of(context)
.pleaseEnterPassword;
}
return null;
},
onSaved: (value) {
userInfo.password = value;
},
onFieldSubmitted: (_) {
focusPass.nextFocus();
helpers.showCupertinoPicker(context, projectsList,
'facilityName', onSelectProject);
},
onTap: () {
this.getProjects(userInfo.userID);
},
)
])),
buildSizedBox(),
projectsList.length > 0
? Container(
decoration: BoxDecoration(
borderRadius: BorderRadius.all(Radius.circular(6.0)),
border: Border.all(
width: 1.0,
color: HexColor("#CCCCCC"),
),
color: Colors.white),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Padding(
padding: EdgeInsets.only(left: 10, top: 10),
child: AppText(
TranslationBase.of(context).selectYourProject,
fontWeight: FontWeight.w600,
)),
AppTextFormField(
focusNode: focusProject,
controller: projectIdController,
borderColor: Colors.white,
onTap: () {
helpers.showCupertinoPicker(
context,
projectsList,
'facilityName',
onSelectProject);
},
// showCursor: false,
// //readOnly: true,
// decoration: buildInputDecoration(
// context,
// TranslationBase.of(context).selectYourProject,
// 'assets/images/password_icon.png'),
validator: (value) {
if (value != null && value.isEmpty) {
return TranslationBase.of(context)
.pleaseEnterYourProject;
}
return null;
})
]))
: Container(
decoration: BoxDecoration(
borderRadius: BorderRadius.all(Radius.circular(6.0)),
border: Border.all(
width: 1.0,
color: HexColor("#CCCCCC"),
),
color: Colors.white),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Padding(
padding: EdgeInsets.only(left: 10, top: 10),
child: AppText(
TranslationBase.of(context).selectYourProject,
fontWeight: FontWeight.w600,
)),
AppTextFormField(
readOnly: true, borderColor: Colors.white
child: Column(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: <Widget>[
Container(
width: SizeConfig.realScreenWidth * 0.90,
height: SizeConfig.realScreenHeight * 0.65,
child:
Column(crossAxisAlignment: CrossAxisAlignment.start, children: [
buildSizedBox(),
Padding(
child: AppText(
TranslationBase.of(context).enterCredentials,
fontSize: 18,
fontWeight: FontWeight.bold,
),
padding: EdgeInsets.only(top: 10, bottom: 10)),
Container(
decoration: BoxDecoration(
borderRadius: BorderRadius.all(Radius.circular(6.0)),
border: Border.all(
width: 1.0,
color: HexColor("#CCCCCC"),
),
color: Colors.white),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Padding(
padding: EdgeInsets.only(left: 10, top: 10),
child: AppText(
TranslationBase.of(context).enterId,
fontWeight: FontWeight.w800,
fontSize: 14,
)),
AppTextFormField(
labelText: '',
borderColor: Colors.white,
// keyboardType: TextInputType.number,
textInputAction: TextInputAction.next,
// decoration: buildInputDecoration(
// context,
// TranslationBase.of(context).enterId,
// 'assets/images/user_id_icon.png'),
validator: (value) {
if (value != null && value.isEmpty) {
return TranslationBase.of(context)
.pleaseEnterYourID;
}
return null;
},
onSaved: (value) {
if (value != null) userInfo.userID = value.trim();
},
onChanged: (value) {
if (value != null) userInfo.userID = value.trim();
},
onFieldSubmitted: (_) {
focusPass.nextFocus();
},
// onEditingComplete: () {},
// autofocus: false,
)
])),
buildSizedBox(),
Container(
decoration: BoxDecoration(
borderRadius: BorderRadius.all(Radius.circular(6.0)),
border: Border.all(
width: 1.0,
color: HexColor("#CCCCCC"),
),
color: Colors.white),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Padding(
padding: EdgeInsets.only(left: 10, top: 10),
child: AppText(
TranslationBase.of(context).enterPassword,
fontWeight: FontWeight.w800,
fontSize: 14,
)),
AppTextFormField(
focusNode: focusPass,
obscureText: true,
borderColor: Colors.white,
textInputAction: TextInputAction.next,
// decoration: buildInputDecoration(
// context,
// TranslationBase.of(context).enterPassword,
// 'assets/images/password_icon.png'),
validator: (value) {
if (value != null && value.isEmpty) {
return TranslationBase.of(context)
.pleaseEnterPassword;
}
return null;
},
onSaved: (value) {
userInfo.password = value;
},
onFieldSubmitted: (_) {
focusPass.nextFocus();
helpers.showCupertinoPicker(context, projectsList,
'facilityName', onSelectProject);
},
onTap: () {
this.getProjects(userInfo.userID);
},
)
])),
buildSizedBox(),
projectsList.length > 0
? Container(
decoration: BoxDecoration(
borderRadius: BorderRadius.all(Radius.circular(6.0)),
border: Border.all(
width: 1.0,
color: HexColor("#CCCCCC"),
),
color: Colors.white),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Padding(
padding: EdgeInsets.only(left: 10, top: 10),
child: AppText(
TranslationBase.of(context).selectYourProject,
fontWeight: FontWeight.w600,
)),
AppTextFormField(
focusNode: focusProject,
controller: projectIdController,
borderColor: Colors.white,
suffixIcon: Icons.arrow_drop_down,
onTap: () {
helpers.showCupertinoPicker(
context,
projectsList,
'facilityName',
onSelectProject);
},
// showCursor: false,
// //readOnly: true,
// decoration: buildInputDecoration(
// context,
// TranslationBase.of(context).selectYourProject,
// 'assets/images/password_icon.png'),
validator: (value) {
if (value != null && value.isEmpty) {
return TranslationBase.of(context)
.pleaseEnterYourProject;
}
return null;
})
]))
: Container(
decoration: BoxDecoration(
borderRadius: BorderRadius.all(Radius.circular(6.0)),
border: Border.all(
width: 1.0,
color: HexColor("#CCCCCC"),
),
color: Colors.white),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Padding(
padding: EdgeInsets.only(left: 10, top: 10),
child: AppText(
TranslationBase.of(context).selectYourProject,
fontWeight: FontWeight.w800,
fontSize: 14,
)),
AppTextFormField(
readOnly: true, borderColor: Colors.white,
prefix: IconButton(
icon: Icon(Icons.arrow_drop_down),
iconSize: 30,
padding: EdgeInsets.only(bottom: 30),
),
// decoration: buildInputDecoration(
// context,
// TranslationBase.of(context)
// .pleaseEnterYourProject,
// 'assets/images/password_icon.png')
)
])),
buildSizedBox(),
Row(
children: <Widget>[
Expanded(
child: Button(
title: TranslationBase.of(context).login,
color: Colors.red[700],
onTap: () {
login(context, authProv, widget.changeLoadingStata);
},
)),
],
)
// Row(
// mainAxisAlignment: MainAxisAlignment.end,
// children: <Widget>[
// RaisedButton(
// onPressed: () {
// login(context, authProv, widget.changeLoadingStata);
// },
// textColor: Colors.white,
// elevation: 0.0,
// padding: const EdgeInsets.all(0.0),
// shape: RoundedRectangleBorder(
// borderRadius: BorderRadius.circular(10),
// side: BorderSide(width: 0.5, color: HexColor('#CCCCCC'))),
// child: Container(
// padding: const EdgeInsets.all(10.0),
// height: 50,
// width: SizeConfig.realScreenWidth * 0.35,
// child: ),
// )
// ],
// ),
],
),
)
])),
]),
),
Row(
mainAxisAlignment: MainAxisAlignment.end,
children: <Widget>[
Expanded(
child: Button(
title: TranslationBase.of(context).login,
color: HexColor('#D02127'),
onTap: () {
login(context, authProv, widget.changeLoadingStata);
},
)),
],
)
// Row(
// mainAxisAlignment: MainAxisAlignment.end,
// children: <Widget>[
// RaisedButton(
// onPressed: () {
// login(context, authProv, widget.changeLoadingStata);
// },
// textColor: Colors.white,
// elevation: 0.0,
// padding: const EdgeInsets.all(0.0),
// shape: RoundedRectangleBorder(
// borderRadius: BorderRadius.circular(10),
// side: BorderSide(width: 0.5, color: HexColor('#CCCCCC'))),
// child: Container(
// padding: const EdgeInsets.all(10.0),
// height: 50,
// width: SizeConfig.realScreenWidth * 0.35,
// child: ),
// )
// ],
// ),
],
),
);
}

@ -155,7 +155,7 @@ class _VerificationMethodsState extends State<VerificationMethods> {
child: Row(
children: <Widget>[
Flexible(
flex: 4,
flex: 3,
child: ListTile(
title: Text(
TranslationBase.of(
@ -164,15 +164,17 @@ class _VerificationMethodsState extends State<VerificationMethods> {
overflow: TextOverflow
.ellipsis,
style: TextStyle(
fontFamily: 'Poppins',
fontWeight:
FontWeight.w600,
),
fontFamily:
'Poppins',
fontWeight:
FontWeight.w800,
fontSize: 14),
),
subtitle: AppText(
getType(
user.logInTypeID,
context),
fontSize: 14,
)
// Text(
// user.editedOn != null
@ -208,6 +210,9 @@ class _VerificationMethodsState extends State<VerificationMethods> {
: '--',
textAlign:
TextAlign.right,
fontSize: 14,
fontWeight:
FontWeight.w800,
),
subtitle: AppText(
user.editedOn != null
@ -223,6 +228,7 @@ class _VerificationMethodsState extends State<VerificationMethods> {
: '--',
textAlign:
TextAlign.right,
fontSize: 14,
),
))
],
@ -487,8 +493,8 @@ class _VerificationMethodsState extends State<VerificationMethods> {
children: [
Image.asset(
'assets/images/verify-whtsapp.png',
height: SizeConfig.imageSizeMultiplier * 13,
width: SizeConfig.imageSizeMultiplier * 16,
height: 60,
width: 60,
),
],
),
@ -497,7 +503,8 @@ class _VerificationMethodsState extends State<VerificationMethods> {
),
AppText(
TranslationBase.of(context).verifyWhatsApp,
fontSize: SizeConfig.textMultiplier * 2.2,
fontSize: 14,
fontWeight: FontWeight.w600,
)
],
),
@ -520,8 +527,8 @@ class _VerificationMethodsState extends State<VerificationMethods> {
children: <Widget>[
Image.asset(
'assets/images/verify-sms.png',
height: SizeConfig.imageSizeMultiplier * 13,
width: SizeConfig.imageSizeMultiplier * 16,
height: 60,
width: 60,
),
projectsProvider.isArabic
? SizedBox(
@ -532,9 +539,8 @@ class _VerificationMethodsState extends State<VerificationMethods> {
),
AppText(
TranslationBase.of(context).verifySMS,
fontSize: projectsProvider.isArabic
? SizeConfig.textMultiplier * 1.8
: SizeConfig.textMultiplier * 2.2,
fontSize: 14,
fontWeight: FontWeight.w600,
)
],
),
@ -560,15 +566,16 @@ class _VerificationMethodsState extends State<VerificationMethods> {
children: <Widget>[
Image.asset(
'assets/images/verification_fingerprint_icon.png',
height: SizeConfig.imageSizeMultiplier * 13,
width: SizeConfig.imageSizeMultiplier * 16,
height: 60,
width: 60,
),
SizedBox(
height: 20,
),
AppText(
TranslationBase.of(context).verifyFingerprint,
fontSize: SizeConfig.textMultiplier * 2.2,
fontSize: 14,
fontWeight: FontWeight.w600,
)
],
),
@ -602,15 +609,16 @@ class _VerificationMethodsState extends State<VerificationMethods> {
children: <Widget>[
Image.asset(
'assets/images/verification_faceid_icon.png',
height: SizeConfig.imageSizeMultiplier * 13,
width: SizeConfig.imageSizeMultiplier * 16,
height: 60,
width: 60,
),
SizedBox(
height: 20,
),
AppText(
TranslationBase.of(context).verifyFaceID,
fontSize: SizeConfig.textMultiplier * 2.2,
fontSize: 14,
fontWeight: FontWeight.w600,
)
],
),
@ -640,8 +648,8 @@ class _VerificationMethodsState extends State<VerificationMethods> {
children: <Widget>[
Image.asset(
'assets/images/login/more_icon.png',
height: SizeConfig.imageSizeMultiplier * 13,
width: SizeConfig.imageSizeMultiplier * 16,
height: 60,
width: 60,
),
projectsProvider.isArabic
? SizedBox(
@ -652,7 +660,8 @@ class _VerificationMethodsState extends State<VerificationMethods> {
),
AppText(
TranslationBase.of(context).moreVerification,
fontSize: SizeConfig.textMultiplier * 2.2,
fontSize: 14,
fontWeight: FontWeight.w600,
// textAlign: TextAlign.center,
)
],

@ -60,20 +60,8 @@ class SMSOTP {
builder: (context) {
projectProvider = Provider.of(context);
return AlertDialog(
contentPadding: EdgeInsets.fromLTRB(24.0, 20.0, 0.0, 24.0),
title: Row(
mainAxisAlignment: MainAxisAlignment.end,
children: <Widget>[
IconButton(
icon: Icon(Icons.close),
onPressed: () {
this.isClosed = true;
Navigator.pop(context);
this.onFailure();
},
)
],
),
contentPadding: EdgeInsets.fromLTRB(24.0, 0.0, 0.0, 24.0),
// shape: RoundedRectangleBorder(
// borderRadius: BorderRadius.all(Radius.circular(10.0))),
content: StatefulBuilder(builder: (context, setState) {
@ -89,21 +77,44 @@ class SMSOTP {
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
type == 1
? Padding(
child: Icon(
DoctorApp.verify_sms_1,
size: 40,
),
padding: EdgeInsets.only(bottom: 20),
)
: Padding(
child: Icon(
DoctorApp.verify_whtsapp,
size: 40,
),
padding: EdgeInsets.only(bottom: 20),
),
Padding(
padding: EdgeInsets.all(10),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
type == 1
? Padding(
child: Icon(
DoctorApp.verify_sms_1,
size: 40,
),
padding: EdgeInsets.only(bottom: 20),
)
: Padding(
child: Icon(
DoctorApp.verify_whtsapp,
size: 40,
),
padding: EdgeInsets.only(bottom: 20),
),
Row(
mainAxisAlignment: MainAxisAlignment.end,
children: <Widget>[
Padding(
padding: EdgeInsets.only(
left: 10, right: 10, bottom: 20),
child: IconButton(
icon: Icon(Icons.close),
iconSize: 40,
onPressed: () {
this.isClosed = true;
Navigator.pop(context);
this.onFailure();
},
))
],
)
])),
Padding(
padding: EdgeInsets.only(top: 5),
child: AppText(
@ -122,7 +133,7 @@ class SMSOTP {
child: Directionality(
textDirection: TextDirection.ltr,
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceAround,
mainAxisAlignment: MainAxisAlignment.spaceEvenly,
children: <Widget>[
Container(
width: SizeConfig.realScreenWidth * 0.15,
@ -233,22 +244,23 @@ class SMSOTP {
)),
),
),
Padding(
padding: EdgeInsets.only(top: 10),
child: Row(children: [
Expanded(
child: AppText(
TranslationBase.of(context).validationMessage + ' ',
fontWeight: FontWeight.w600,
),
Column(
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
AppText(
TranslationBase.of(context).validationMessage + ' ',
fontWeight: FontWeight.w600,
fontSize: 14,
),
AppText(
displayTime,
color: Colors.red,
textAlign: TextAlign.center,
textAlign: TextAlign.start,
fontWeight: FontWeight.bold,
fontSize: 14,
)
]))
])
],
))),
);

@ -282,48 +282,38 @@ class PatientReferralItemWidget extends StatelessWidget {
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
RichText(
text: new TextSpan(
style: new TextStyle(
fontSize: 2.0 * SizeConfig.textMultiplier,
color: Colors.black),
children: <TextSpan>[
new TextSpan(
text: referralStatus != null
? referralStatus
: "",
style: TextStyle(
color: referralStatus != null
? referralStatus == 'Pending'
? Color(0xffc4aa54)
: referralStatus == 'Accepted'
? Colors.green[700]
: Colors.red[700]
: Colors.grey[500],
fontWeight: FontWeight.w700,
fontFamily: 'Poppins',
fontSize:
2.0 * SizeConfig.textMultiplier)),
],
),
AppText(
referralStatus != null ? referralStatus : "",
fontFamily: 'Poppins',
fontSize: 1.9 * SizeConfig.textMultiplier,
fontWeight: FontWeight.w700,
color: referralStatus != null
? referralStatus == 'Pending'
? Color(0xffc4aa54)
: referralStatus == 'Accepted'
? Colors.green[700]
: Colors.red[700]
: Colors.grey[500],
),
//TODO :ask backend to return in the standard format
AppText(
referredOn,
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
fontSize: 2.1 * SizeConfig.textMultiplier,
fontSize: 2.0 * SizeConfig.textMultiplier,
color: Color(0XFF28353E),
)
],
),
Row(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Expanded(
child: AppText(
patientInfo.patientName,
fontSize: SizeConfig.textMultiplier * 2.5,
fontSize: SizeConfig.textMultiplier * 2.2,
fontWeight: FontWeight.bold,
backGroundcolor: Colors.white,
color: Colors.black,
fontFamily: 'Poppins',
),
),
@ -339,64 +329,68 @@ class PatientReferralItemWidget extends StatelessWidget {
DoctorApp.female_1,
color: Colors.pink,
),
SizedBox(
width: 4,
),
AppText(
referredOn,
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
fontSize: 1.8 * SizeConfig.textMultiplier,
color: Color(0XFF575757),
)
],
),
SizedBox(
width: 10,
),
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Column(
children: [
RichText(
text: new TextSpan(
style: new TextStyle(
fontSize: 2.0 * SizeConfig.textMultiplier,
color: Colors.black),
children: <TextSpan>[
new TextSpan(
text: TranslationBase.of(context)
.fileNumber,
style: TextStyle(
fontSize: 14, fontFamily: 'Poppins')),
new TextSpan(
text: patientInfo.patientID.toString(),
style: TextStyle(
fontWeight: FontWeight.w700,
fontFamily: 'Poppins',
fontSize: 15)),
Expanded(
child: Column(
children: [
Row(
mainAxisAlignment: MainAxisAlignment.start,
children: [
AppText(
TranslationBase.of(context).fileNumber,
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
fontSize: 1.7 * SizeConfig.textMultiplier,
color: Color(0XFF575757),
),
AppText(
patientInfo.patientID.toString(),
fontFamily: 'Poppins',
fontWeight: FontWeight.w700,
fontSize: 1.8 * SizeConfig.textMultiplier,
color: Color(0XFF2E303A),
),
],
),
),
Container(
child: RichText(
text: new TextSpan(
style: new TextStyle(
fontSize: 2.0 * SizeConfig.textMultiplier,
color: Colors.black),
children: <TextSpan>[
new TextSpan(
text: TranslationBase.of(context)
.referredFrom,
style: TextStyle(
fontSize: 14,
fontFamily: 'Poppins')),
new TextSpan(
text: isSameBranch
? TranslationBase.of(context)
.sameBranch
: TranslationBase.of(context)
.otherBranch,
style: TextStyle(
fontWeight: FontWeight.w700,
fontFamily: 'Poppins',
fontSize: 15)),
],
),
Row(
mainAxisAlignment: MainAxisAlignment.start,
children: [
AppText(
TranslationBase.of(context).referredFrom,
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
fontSize: 1.7 * SizeConfig.textMultiplier,
color: Color(0XFF575757),
),
AppText(
isSameBranch
? TranslationBase.of(context).sameBranch
: TranslationBase.of(context)
.otherBranch,
fontFamily: 'Poppins',
fontWeight: FontWeight.w700,
fontSize: 1.8 * SizeConfig.textMultiplier,
color: Color(0XFF2E303A),
),
],
),
),
],
],
),
),
Row(
children: [
@ -405,7 +399,8 @@ class PatientReferralItemWidget extends StatelessWidget {
patient.nationality*/
"Saudi",
fontWeight: FontWeight.bold,
fontSize: 12,
color: Color(0xFF2E303A),
fontSize: 1.4 * SizeConfig.textMultiplier,
),
/* patient.nationality != null
? ClipRRect(
@ -434,48 +429,51 @@ class PatientReferralItemWidget extends StatelessWidget {
)
],
),
Container(
child: RichText(
text: new TextSpan(
style: new TextStyle(
fontSize: 2.0 * SizeConfig.textMultiplier,
color: Colors.black),
children: <TextSpan>[
new TextSpan(
text:
TranslationBase.of(context).remarks + " : ",
style: TextStyle(
fontSize: 14, fontFamily: 'Poppins')),
new TextSpan(
text: patientInfo.remarksFromSource,
style: TextStyle(
fontWeight: FontWeight.w700,
fontFamily: 'Poppins',
fontSize: 15)),
],
Row(
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
AppText(
TranslationBase.of(context).remarks + " : ",
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
fontSize: 1.7 * SizeConfig.textMultiplier,
color: Color(0XFF575757),
),
),
Expanded(
child: AppText(
patientInfo.remarksFromSource,
fontFamily: 'Poppins',
fontWeight: FontWeight.w700,
fontSize: 1.8 * SizeConfig.textMultiplier,
color: Color(0XFF2E303A),
),
),
],
),
Row(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Container(
width: 30,
height: 30,
margin: EdgeInsets.only(left: 10, right: 0),
child: Image.asset(
infoIcon != null ? 'assets/images/patient/ic_ref_arrow_up.png' : 'assets/images/patient/ic_ref_arrow_left.png',
height: 50,
width: 30,
),
),
Container(
margin: EdgeInsets.only(
left:
projectViewModel.isArabic ? 10 : 10 /*10:85*/,
right:
projectViewModel.isArabic ? 10 : 10 /*85:10*/,
top: 5),
decoration: BoxDecoration(
shape: BoxShape.rectangle,
border: Border(
bottom: BorderSide(
color: Colors.grey[400], width: 2.5),
left: BorderSide(
color: Colors.grey[400], width: 2.5),
)),
left: 0, top: 25, right: 0, bottom: 0),
padding: EdgeInsets.only(left: 4.0, right: 4.0),
child: Container(
width: 40,
height: 40,
child: Image.asset(
'assets/images/female_avatar.png',
fit: BoxFit.cover,
),
),
),
Expanded(
flex: 4,

@ -171,7 +171,7 @@ class PatientProfileHeaderNewDesignAppBar extends StatelessWidget
Container(
child: AppText(
convertDateFormat2(
patient.appointmentDate.toString() ?? ''),
patient.appointmentDate ?? ''),
fontSize: 1.5 * SizeConfig.textMultiplier,
fontWeight: FontWeight.bold,
),
@ -281,7 +281,7 @@ class PatientProfileHeaderNewDesignAppBar extends StatelessWidget
date.day.toString().padLeft(2, '0');
}
return newDate.toString();
return newDate??'';
}
isToday(date) {

@ -380,7 +380,7 @@ class PatientProfileHeaderWhitAppointmentAppBar extends StatelessWidget with Pre
fontWeight: FontWeight.w600,
fontSize: 12,
),
if (orderNo != null && !isPrescriptions)
if (orderNo != null )
Row(
children: <Widget>[
Texts(
@ -393,7 +393,7 @@ class PatientProfileHeaderWhitAppointmentAppBar extends StatelessWidget with Pre
)
],
),
if (invoiceNO != null && !isPrescriptions)
if (invoiceNO != null )
Row(
children: <Widget>[
Texts(
@ -407,7 +407,7 @@ class PatientProfileHeaderWhitAppointmentAppBar extends StatelessWidget with Pre
)
],
),
if(isPrescriptions && branch!=null)
if( branch!=null)
Row(
children: [
Texts(
@ -421,7 +421,7 @@ class PatientProfileHeaderWhitAppointmentAppBar extends StatelessWidget with Pre
)
],
),
if(isPrescriptions)
if(clinic!=null)
Row(
children: [
Texts(

@ -57,7 +57,7 @@ class ProfileWelcomeWidget extends StatelessWidget {
CircleAvatar(
// radius: (52)
child: ClipRRect(
borderRadius: BorderRadius.circular(10),
borderRadius: BorderRadius.circular(20),
child: Image.network(
authProvider.doctorProfile.doctorImageURL,
fit: BoxFit.fill,

@ -2,6 +2,7 @@ import 'package:doctor_app_flutter/config/shared_pref_kay.dart';
import 'package:doctor_app_flutter/core/enum/viewstate.dart';
import 'package:doctor_app_flutter/core/viewModel/SOAP_view_model.dart';
import 'package:doctor_app_flutter/core/viewModel/project_view_model.dart';
import 'package:doctor_app_flutter/icons_app/doctor_app_icons.dart';
import 'package:doctor_app_flutter/models/SOAP/GetGetProgressNoteReqModel.dart';
import 'package:doctor_app_flutter/models/SOAP/GetGetProgressNoteResModel.dart';
import 'package:doctor_app_flutter/models/SOAP/post_progress_note_request_model.dart';
@ -44,8 +45,7 @@ class UpdatePlanPage extends StatefulWidget {
}
class _UpdatePlanPageState extends State<UpdatePlanPage> {
bool isProgressNoteExpand = false;
bool isAddProgress = true;
TextEditingController progressNoteController =
TextEditingController(text: null);
@ -62,7 +62,17 @@ class _UpdatePlanPageState extends State<UpdatePlanPage> {
)),
);
}
TextEditingController typeController = TextEditingController();
@override
void initState() {
super.initState();
if(widget.patientProgressNote.planNote !=null ){
setState(() {
isAddProgress = false;
});
}
}
@override
Widget build(BuildContext context) {
@ -83,7 +93,9 @@ class _UpdatePlanPageState extends State<UpdatePlanPage> {
widget.patientProgressNote.createdOn = model.patientProgressNoteList[0].createdOn;
widget.patientProgressNote.editedOn = model.patientProgressNoteList[0].editedOn;
widget.patientProgressNote.editedByName = model.patientProgressNoteList[0].editedByName;
setState(() {
isAddProgress = false;
});
}
widget.changeLoadingState(false);
},
@ -117,46 +129,15 @@ class _UpdatePlanPageState extends State<UpdatePlanPage> {
mainAxisAlignment: MainAxisAlignment.start,
children: [
SizedBox(
height: 10,
),
HeaderBodyExpandableNotifier(
headerWidget: Row(
mainAxisAlignment: MainAxisAlignment.spaceAround,
Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Row(
children: [
Texts(TranslationBase
Container(
margin: EdgeInsets.only(left: 5, right: 5),
child: Texts(TranslationBase
.of(context)
.progressNoteSOAP,
variant: isProgressNoteExpand ? "bodyText" : '',
bold: isProgressNoteExpand ? true : false,
color: Colors.black),
Icon(
FontAwesomeIcons.asterisk,
color: Colors.black,
size: 12,
)
],
),
InkWell(
onTap: () {
setState(() {
isProgressNoteExpand = !isProgressNoteExpand;
});
},
child: Icon(isProgressNoteExpand
? Icons.keyboard_arrow_up
: Icons.keyboard_arrow_down))
],
),
bodyWidget: Column(children: [
SizedBox(
height: 2,
),
Column(
children: [
if(widget.patientProgressNote.planNote == null)
.progressNote)),
if(isAddProgress)
Container(
margin:
EdgeInsets.only(left: 10, right: 10, top: 15),
@ -168,115 +149,90 @@ class _UpdatePlanPageState extends State<UpdatePlanPage> {
maxLines: 4,
inputType: TextInputType.multiline,
onChanged: (value){
// examination.remark = value;
widget.patientProgressNote.planNote = value;
},
),
),
SizedBox(
height: 20,
height: 9,
),
if ( widget.patientProgressNote.planNote != null)
if ( widget.patientProgressNote.planNote != null&& !isAddProgress)
Container(
margin:
EdgeInsets.only(left: 5, right: 5, top: 15),
EdgeInsets.only(left: 5, right: 5, ),
child: Column(
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
SizedBox(
height: 8,
),
Row(
mainAxisAlignment: MainAxisAlignment.spaceAround,
mainAxisAlignment: MainAxisAlignment.spaceBetween,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Row(
children: [
Texts('Appointment No: '),
Texts(widget.patientProgressNote.appointmentNo.toString()),
Texts('Appointment No: ',fontSize: 12,),
Texts(widget.patientProgressNote.appointmentNo??'',fontWeight: FontWeight.w600,),
],
),
AppText(
Texts(
widget.patientProgressNote.createdOn !=null?DateUtils.getDayMonthYearDateFormatted(DateTime.parse(widget.patientProgressNote.createdOn)):DateUtils.getDayMonthYearDateFormatted(DateTime.now()),
fontWeight: FontWeight
.bold,
fontSize: 16,
.w600,
fontSize: 14,
)
],
),
Row(
children: [
Texts('Condition: '),
Texts(widget.patientProgressNote.mName.toString()),
],
),
if(widget.patientProgressNote.createdByName !=null)
Row(
mainAxisAlignment:
MainAxisAlignment.start,
children: [
AppText(
TranslationBase.of(context).createdBy,
fontWeight: FontWeight.bold,
fontSize: 16,
),
AppText(
widget.patientProgressNote.createdByName??"",
fontSize: 10,
color: Colors.grey,
),
],
),
if(widget.patientProgressNote.editedByName !=null)
Row(
mainAxisAlignment:
MainAxisAlignment.start,
MainAxisAlignment.spaceBetween,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
AppText(
TranslationBase.of(context).editedBy,
fontWeight: FontWeight.bold,
fontSize: 16,
),
AppText(
widget.patientProgressNote.editedByName??"",
fontSize: 10,
color: Colors.grey,
),
],
Row(
children: [
Texts('Condition: ',
fontSize: 12,),
Texts(
widget.patientProgressNote.mName??'',fontWeight: FontWeight.w600),
],
),
Texts(
widget.patientProgressNote.createdOn !=null?DateUtils.getHour(DateTime.parse(widget.patientProgressNote.createdOn)):DateUtils.getHour(DateTime.now()),
fontWeight: FontWeight.w600,
fontSize: 14,
)
],
),
SizedBox(height: 8,
),
Row(
mainAxisAlignment:
MainAxisAlignment.start,
children: [
SizedBox(
height: 6,
),
Padding(
padding: const EdgeInsets.all(0.0),
child: Container(
width: MediaQuery.of(context)
.size
.width *
0.6,
Expanded(
child: Texts(
progressNoteController.text,
fontSize: 10,
color: Colors.grey,
),
),
),
],
),
],
),
),
)
InkWell(
onTap: (){
setState(() {
isAddProgress = true;
widget.changePageViewIndex(3,isChangeState:false);
});
},
child: Icon(DoctorApp.edit,size: 18,))
],
)
]),
isExpand: isProgressNoteExpand,
),
],
),
)
],
),
],
@ -289,56 +245,62 @@ class _UpdatePlanPageState extends State<UpdatePlanPage> {
),
bottomSheet: Container(
width: double.maxFinite,
height: 70,
child: Container(
margin: EdgeInsets.all(6),
child: Column(
children: [
Row(
children: [
Expanded(
child: AppButton(
title: 'Previous',
color: Colors.white38,
fontColor: Colors.black,
fontWeight: FontWeight.w700,
loading: model.state == ViewState.BusyLocal,
onPressed: () async {
setState(() {
widget.changePageViewIndex(2);
});
},
height: 90,
child: Padding(
padding: const EdgeInsets.all(8.0),
child: Container(
margin: EdgeInsets.all(6),
child: Column(
children: [
Row(
children: [
Expanded(
child: AppButton(
title: 'Previous',
color: Colors.grey[300],
fontColor: Colors.black,
fontWeight: FontWeight.w400,
loading: model.state == ViewState.BusyLocal,
onPressed: () async {
setState(() {
widget.changePageViewIndex(2);
});
},
),
),
),
SizedBox(width: 5,),
Expanded(
child: AppButton(
title: TranslationBase.of(context).next,
fontWeight: FontWeight.w700,
loading: model.state == ViewState.BusyLocal,
disabled: progressNoteController.text.isEmpty,
onPressed: () async {
if(widget.patientProgressNote.planNote.isEmpty) {
Map profile = await sharedPref.getObj(DOCTOR_PROFILE);
DoctorProfileModel doctorProfile = DoctorProfileModel.fromJson(profile);
setState(() {
widget.patientProgressNote.createdByName = widget.patientProgressNote.createdByName ?? doctorProfile.doctorName;
widget.patientProgressNote.editedByName = doctorProfile.doctorName;
widget.patientProgressNote.createdOn = DateTime.now().toString();
widget.patientProgressNote.planNote = progressNoteController.text;
});
} else
submitPlan(model);
},
SizedBox(width: 5,),
Expanded(
child: AppButton(
title: isAddProgress? TranslationBase.of(context).next: "Finish",
fontWeight: FontWeight.w400,
loading: model.state == ViewState.BusyLocal,
color: Colors.red[700],
disabled: progressNoteController.text.isEmpty,
onPressed: () async {
if(isAddProgress) {
Map profile = await sharedPref.getObj(DOCTOR_PROFILE);
DoctorProfileModel doctorProfile = DoctorProfileModel.fromJson(profile);
setState(() {
widget.patientProgressNote.createdByName = widget.patientProgressNote.createdByName ?? doctorProfile.doctorName;
widget.patientProgressNote.editedByName = doctorProfile.doctorName;
widget.patientProgressNote.createdOn = DateTime.now().toString();
widget.patientProgressNote.planNote = progressNoteController.text;
isAddProgress = !isAddProgress;
});
submitPlan(model);
} else{
Navigator.of(context).pop();
}
},
),
),
),
],
),
],
),
],
],
),
),
),
),
@ -369,7 +331,7 @@ class _UpdatePlanPageState extends State<UpdatePlanPage> {
if (model.state == ViewState.ErrorLocal) {
helpers.showErrorToast(model.error);
} else {
Navigator.of(context).pop();
widget.changePageViewIndex(4,isChangeState:false);
}
} else {
helpers.showErrorToast(TranslationBase.of(context).progressNoteErrorMsg);

@ -41,9 +41,13 @@ class _UpdateSoapIndexState extends State<UpdateSoapIndex>
GetPatientProgressNoteResModel patientProgressNote =
GetPatientProgressNoteResModel();
changePageViewIndex(pageIndex) {
if (pageIndex != _currentIndex) changeLoadingState(true);
changePageViewIndex(pageIndex,{isChangeState = true}) {
if (pageIndex != _currentIndex && isChangeState)
changeLoadingState(true);
_controller.jumpToPage(pageIndex);
setState(() {
_currentIndex = pageIndex;
});
}
bool _isLoading = true;

@ -1,4 +1,5 @@
import 'package:doctor_app_flutter/config/size_config.dart';
import 'package:doctor_app_flutter/icons_app/doctor_app_icons.dart';
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'app_texts_widget.dart';
@ -19,6 +20,7 @@ class AppTextFieldCustom extends StatefulWidget {
final int maxLines;
final List<TextInputFormatter> inputFormatters;
final Function(String) onChanged;
final String validationError;
AppTextFieldCustom({
this.height = 0,
@ -36,6 +38,7 @@ class AppTextFieldCustom extends StatefulWidget {
this.maxLines = 1,
this.inputFormatters,
this.onChanged,
this.validationError,
});
@override
@ -45,80 +48,115 @@ class AppTextFieldCustom extends StatefulWidget {
class _AppTextFieldCustomState extends State<AppTextFieldCustom> {
@override
Widget build(BuildContext context) {
return Container(
height: widget.height != 0 ? widget.height : null,
decoration: widget.hasBorder
? containerBorderDecoration(Color(0Xffffffff), Color(0xFFEFEFEF))
: null,
padding: EdgeInsets.only(top: 4.0, bottom: 4.0, left: 8.0, right: 8.0),
child: InkWell(
onTap: widget.onClick ?? null,
child: Row(
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Expanded(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
mainAxisAlignment: MainAxisAlignment.center,
children: [
if ((widget.controller != null &&
widget.controller.text != "") ||
widget.dropDownText != null)
AppText(
widget.hintText,
fontFamily: 'Poppins',
fontSize: SizeConfig.textMultiplier * 1.4,
fontWeight: FontWeight.w600,
),
widget.dropDownText == null
? TextField(
textAlign: TextAlign.left,
decoration: textFieldSelectorDecoration(
widget.hintText, null, true),
style: TextStyle(
fontSize: SizeConfig.textMultiplier * 1.7,
return Column(
children: [
Container(
height: widget.height != 0 ? widget.height + 8 : null,
decoration: widget.hasBorder
? containerBorderDecoration(
Color(0Xffffffff),
widget.validationError == null
? Color(0xFFEFEFEF)
: Colors.red.shade700)
: null,
padding:
EdgeInsets.only(top: 4.0, bottom: 4.0, left: 8.0, right: 8.0),
child: InkWell(
onTap: widget.onClick ?? null,
child: Row(
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Expanded(
child: Container(
padding: widget.dropDownText == null
? EdgeInsets.symmetric(vertical: 0)
: EdgeInsets.symmetric(vertical: 8),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
mainAxisAlignment: MainAxisAlignment.center,
children: [
if ((widget.controller != null &&
widget.controller.text != "") ||
widget.dropDownText != null)
AppText(
widget.hintText,
fontFamily: 'Poppins',
color: Colors.grey.shade800,
fontSize: SizeConfig.textMultiplier * 1.4,
fontWeight: FontWeight.w700,
),
controller: widget.controller,
keyboardType: widget.inputType,
enabled: widget.enabled,
minLines: widget.minLines,
maxLines: widget.maxLines,
inputFormatters: widget.inputFormatters != null
? widget.inputFormatters
: [],
onChanged: (value) {
if (widget.onChanged != null){
widget.onChanged(value);
setState(() {
});
}
},
)
: AppText(
widget.dropDownText,
fontFamily: 'Poppins',
color: Colors.grey.shade800,
fontSize: SizeConfig.textMultiplier * 1.7,
),
],
),
widget.dropDownText == null
? TextField(
textAlign: TextAlign.left,
decoration: textFieldSelectorDecoration(
widget.hintText, null, true),
style: TextStyle(
fontSize: SizeConfig.textMultiplier * 1.7,
fontFamily: 'Poppins',
color: Colors.grey.shade800,
),
controller: widget.controller,
keyboardType: widget.inputType,
enabled: widget.enabled,
minLines: widget.minLines,
maxLines: widget.maxLines,
inputFormatters: widget.inputFormatters != null
? widget.inputFormatters
: [],
onChanged: (value) {
if (widget.onChanged != null) {
widget.onChanged(value);
setState(() {});
}
},
)
: AppText(
widget.dropDownText,
fontFamily: 'Poppins',
color: Colors.grey.shade800,
fontSize: SizeConfig.textMultiplier * 1.7,
),
],
),
),
),
widget.isDropDown
? widget.suffixIcon != null
? widget.suffixIcon
: Icon(
Icons.keyboard_arrow_down,
color: widget.dropDownColor != null
? widget.dropDownColor
: Colors.black,
)
: Container(),
],
),
widget.isDropDown
? widget.suffixIcon != null
? widget.suffixIcon
: Icon(
Icons.keyboard_arrow_down,
color: widget.dropDownColor != null
? widget.dropDownColor
: Colors.black,
)
: Container(),
],
),
),
),
if (widget.validationError != null)
Container(
margin: EdgeInsets.only(top: 8, right: 8, left: 8, bottom: 8),
child: Row(
children: [
Icon(
DoctorApp.warning,
size: 20,
color: Colors.red.shade700,
),
SizedBox(
width: 12,
),
AppText(
widget.validationError,
fontFamily: 'Poppins',
fontSize: SizeConfig.textMultiplier * 1.7,
color: Colors.red.shade700,
fontWeight: FontWeight.w700,
),
],
),
),
],
);
}

@ -82,7 +82,7 @@ class DoctorCard extends StatelessWidget {
],
),
Row(
crossAxisAlignment: CrossAxisAlignment.end,
crossAxisAlignment: CrossAxisAlignment.center,
children: <Widget>[
Container(
child: LargeAvatar(
@ -93,74 +93,81 @@ class DoctorCard extends StatelessWidget {
height: 55,
),
Expanded(
flex: 4,
child: Container(
margin: EdgeInsets.all(10),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
if (orderNo != null && !isPrescriptions)
Row(
children: <Widget>[
Texts(
'order No:',
color: Colors.grey[500],
fontSize: 14,
),
Texts(
orderNo ?? '',
fontSize: 14,
)
],
),
if (invoiceNO != null && !isPrescriptions)
Row(
child: Row(
crossAxisAlignment: CrossAxisAlignment.end,
children: [
Expanded(
child: Container(
margin: EdgeInsets.all(10),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
Texts(
'Invoice:',
fontSize: 14,
color: Colors.grey[500],
if (orderNo != null && !isPrescriptions)
Row(
children: <Widget>[
Texts(
'order No:',
color: Colors.grey[500],
fontSize: 14,
),
Texts(
orderNo ?? '',
fontSize: 14,
)
],
),
if (invoiceNO != null && !isPrescriptions)
Row(
children: <Widget>[
Texts(
'Invoice:',
fontSize: 14,
color: Colors.grey[500],
),
Texts(
invoiceNO,
fontSize: 14,
)
],
),
if(clinic!=null)
Row(
children: <Widget>[
Texts(
'Clinic: ',
color: Colors.grey[500],
fontSize: 14,
),
Texts(
clinic,
fontSize: 14,
)
],
),
Texts(
invoiceNO,
fontSize: 14,
if(branch!=null)
Row(
children: <Widget>[
Texts(
'Branch: ',
fontSize: 14,
color: Colors.grey[500],
),
Texts(
branch,
fontSize: 14,
)
],
)
],
),
if(isPrescriptions)
Row(
children: <Widget>[
Texts(
'Clinic: ',
color: Colors.grey[500],
fontSize: 14,
),
Texts(
clinic,
fontSize: 14,
)
],
),
if(branch!=null)
Row(
children: <Widget>[
Texts(
'Branch: ',
fontSize: 14,
color: Colors.grey[500],
),
Texts(
branch,
fontSize: 14,
)
],
)
]),
]),
),
),
Icon(
EvaIcons.eye,
)
],
),
),
Icon(
EvaIcons.eye,
)
],
),
],

@ -1,4 +1,5 @@
import 'package:doctor_app_flutter/core/viewModel/project_view_model.dart';
import 'package:doctor_app_flutter/icons_app/doctor_app_icons.dart';
import 'package:doctor_app_flutter/widgets/patients/profile/large_avatar.dart';
import 'package:eva_icons_flutter/eva_icons_flutter.dart';
import 'package:flutter/cupertino.dart';
@ -89,7 +90,7 @@ class DoctorCardInsurance extends StatelessWidget {
child: Padding(
padding: const EdgeInsets.all(5.0),
child: Texts(
'$patientOut',
'$patientOut'.replaceAll(" ", ""),
color: Colors.white,
fontSize: 13.0,
),
@ -102,7 +103,7 @@ class DoctorCardInsurance extends StatelessWidget {
Expanded(
child: Texts(
doctorName,
bold: true,
fontWeight: FontWeight.w700,
)),
],
),
@ -153,11 +154,13 @@ class DoctorCardInsurance extends StatelessWidget {
children: <Widget>[
Texts(
'Clinic: ',
color: Colors.grey[500],
//fontWeight: FontWeight.w600,
//color: Colors.grey[500],
),
Expanded(
child: Texts(
clinic,
fontWeight: FontWeight.w700,
),
)
],
@ -167,19 +170,24 @@ class DoctorCardInsurance extends StatelessWidget {
children: <Widget>[
Texts(
'Approval No: ',
color: Colors.grey[500],
//color: Colors.grey[500],
),
Texts(
branch,
fontWeight: FontWeight.w700,
)
],
)
]),
),
),
Icon(
EvaIcons.eye,
size: 38.0,
Padding(
padding:
const EdgeInsets.symmetric(horizontal: 15.0),
child: Icon(
DoctorApp.view,
size: 22.0,
),
)
],
),

@ -18,6 +18,12 @@ class HeaderBodyExpandableNotifier extends StatefulWidget {
class _HeaderBodyExpandableNotifierState
extends State<HeaderBodyExpandableNotifier> {
@override
void initState() {
super.initState();
}
@override
Widget build(BuildContext context) {
setState(() {
@ -26,7 +32,6 @@ class _HeaderBodyExpandableNotifierState
widget.controller.expanded = true;
}
});
return ExpandableNotifier(
child: Padding(
padding: const EdgeInsets.only(left: 0, right: 0),

@ -1,5 +1,6 @@
import 'package:doctor_app_flutter/core/enum/viewstate.dart';
import 'package:doctor_app_flutter/core/viewModel/base_view_model.dart';
import 'package:doctor_app_flutter/widgets/shared/Text.dart';
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
@ -32,8 +33,13 @@ class NetworkBaseView extends StatelessWidget {
break;
case ViewState.Error:
return Center(
child: DrAppEmbeddedError(
error: baseViewModel.error,
child: Column(
children: [
SizedBox(height: 100,),
Image.asset('assets/images/no-data.png',height: 250),
Texts(baseViewModel.error??'')
],
),
);
break;

Loading…
Cancel
Save