Merge branch 'mohammad' of https://gitlab.com/Cloud_Solution/doctor_app_flutter into elham
commit
6e5c2aca4d
@ -0,0 +1,98 @@
|
||||
import 'package:doctor_app_flutter/screens/dashboard_screen.dart';
|
||||
import 'package:doctor_app_flutter/screens/doctor/message_screen.dart';
|
||||
import 'package:doctor_app_flutter/screens/doctor/my_schedule_screen.dart';
|
||||
import 'package:doctor_app_flutter/screens/doctor/services_screen.dart';
|
||||
import 'package:doctor_app_flutter/widgets/shared/app_drawer_widget.dart';
|
||||
import 'package:doctor_app_flutter/widgets/shared/bottom_nav_bar.dart';
|
||||
import 'package:doctor_app_flutter/widgets/shared/profile_image_widget.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:hexcolor/hexcolor.dart';
|
||||
|
||||
|
||||
class LandingPage extends StatefulWidget {
|
||||
@override
|
||||
_LandingPageState createState() => _LandingPageState();
|
||||
}
|
||||
|
||||
class _LandingPageState extends State<LandingPage> {
|
||||
int currentTab = 0;
|
||||
PageController pageController;
|
||||
|
||||
_changeCurrentTab(int tab) {
|
||||
setState(() {
|
||||
currentTab = tab;
|
||||
pageController.jumpToPage(tab);
|
||||
});
|
||||
}
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
super.initState();
|
||||
pageController = new PageController(keepPage: true);
|
||||
}
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
elevation: 0,
|
||||
backgroundColor: Hexcolor('#515B5D'),
|
||||
textTheme: TextTheme(
|
||||
headline6: TextStyle(color: Colors.white, fontWeight: FontWeight.bold)),
|
||||
title: Text(getText(currentTab).toUpperCase()),
|
||||
leading: Builder(
|
||||
builder: (BuildContext context) {
|
||||
return IconButton(
|
||||
icon: Icon(Icons.menu),
|
||||
color: Colors.white,
|
||||
onPressed: () => Scaffold.of(context).openDrawer(),
|
||||
);
|
||||
},
|
||||
),
|
||||
centerTitle: true,
|
||||
actions: <Widget>[
|
||||
ProfileImageWidget(
|
||||
height: 50,
|
||||
width: 50,
|
||||
url:
|
||||
"https://hmgwebservices.com/Images/MobileImages/DUBAI/unkown_female.png",
|
||||
)
|
||||
],
|
||||
),
|
||||
drawer: Theme(
|
||||
data: Theme.of(context).copyWith(
|
||||
canvasColor: Colors.transparent,
|
||||
),
|
||||
child: SafeArea(child: AppDrawer()),
|
||||
),
|
||||
extendBody: true,
|
||||
body: PageView(
|
||||
physics: NeverScrollableScrollPhysics(),
|
||||
controller: pageController,
|
||||
children: [
|
||||
DashboardScreen(),
|
||||
MessagesScreen(),
|
||||
MyScheduleScreen(),
|
||||
ServicesScreen()
|
||||
],
|
||||
),
|
||||
bottomNavigationBar: BottomNavBar(changeIndex: _changeCurrentTab),
|
||||
|
||||
);
|
||||
}
|
||||
|
||||
getText(currentTab) {
|
||||
switch (currentTab) {
|
||||
case 0:
|
||||
return "HOME";
|
||||
case 1:
|
||||
return "REPLAY";
|
||||
case 2:
|
||||
return "SCHEDULE";
|
||||
case 3:
|
||||
return 'SERVICES';
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,200 @@
|
||||
class PrescriptionReportForInPatient {
|
||||
int admissionNo;
|
||||
int authorizedBy;
|
||||
Null bedNo;
|
||||
String comments;
|
||||
int createdBy;
|
||||
String createdByName;
|
||||
Null createdByNameN;
|
||||
String createdOn;
|
||||
String direction;
|
||||
int directionID;
|
||||
Null directionN;
|
||||
String dose;
|
||||
int editedBy;
|
||||
Null iVDiluentLine;
|
||||
int iVDiluentType;
|
||||
Null iVDiluentVolume;
|
||||
Null iVRate;
|
||||
Null iVStability;
|
||||
String itemDescription;
|
||||
int itemID;
|
||||
int lineItemNo;
|
||||
int locationId;
|
||||
int noOfDoses;
|
||||
int orderNo;
|
||||
int patientID;
|
||||
String pharmacyRemarks;
|
||||
String prescriptionDatetime;
|
||||
int prescriptionNo;
|
||||
String processedBy;
|
||||
int projectID;
|
||||
int refillID;
|
||||
String refillType;
|
||||
Null refillTypeN;
|
||||
int reviewedPharmacist;
|
||||
Null roomId;
|
||||
String route;
|
||||
int routeId;
|
||||
Null routeN;
|
||||
Null setupID;
|
||||
String startDatetime;
|
||||
int status;
|
||||
String statusDescription;
|
||||
Null statusDescriptionN;
|
||||
String stopDatetime;
|
||||
int unitofMeasurement;
|
||||
String unitofMeasurementDescription;
|
||||
Null unitofMeasurementDescriptionN;
|
||||
|
||||
PrescriptionReportForInPatient(
|
||||
{this.admissionNo,
|
||||
this.authorizedBy,
|
||||
this.bedNo,
|
||||
this.comments,
|
||||
this.createdBy,
|
||||
this.createdByName,
|
||||
this.createdByNameN,
|
||||
this.createdOn,
|
||||
this.direction,
|
||||
this.directionID,
|
||||
this.directionN,
|
||||
this.dose,
|
||||
this.editedBy,
|
||||
this.iVDiluentLine,
|
||||
this.iVDiluentType,
|
||||
this.iVDiluentVolume,
|
||||
this.iVRate,
|
||||
this.iVStability,
|
||||
this.itemDescription,
|
||||
this.itemID,
|
||||
this.lineItemNo,
|
||||
this.locationId,
|
||||
this.noOfDoses,
|
||||
this.orderNo,
|
||||
this.patientID,
|
||||
this.pharmacyRemarks,
|
||||
this.prescriptionDatetime,
|
||||
this.prescriptionNo,
|
||||
this.processedBy,
|
||||
this.projectID,
|
||||
this.refillID,
|
||||
this.refillType,
|
||||
this.refillTypeN,
|
||||
this.reviewedPharmacist,
|
||||
this.roomId,
|
||||
this.route,
|
||||
this.routeId,
|
||||
this.routeN,
|
||||
this.setupID,
|
||||
this.startDatetime,
|
||||
this.status,
|
||||
this.statusDescription,
|
||||
this.statusDescriptionN,
|
||||
this.stopDatetime,
|
||||
this.unitofMeasurement,
|
||||
this.unitofMeasurementDescription,
|
||||
this.unitofMeasurementDescriptionN});
|
||||
|
||||
PrescriptionReportForInPatient.fromJson(Map<String, dynamic> json) {
|
||||
admissionNo = json['AdmissionNo'];
|
||||
authorizedBy = json['AuthorizedBy'];
|
||||
bedNo = json['BedNo'];
|
||||
comments = json['Comments'];
|
||||
createdBy = json['CreatedBy'];
|
||||
createdByName = json['CreatedByName'];
|
||||
createdByNameN = json['CreatedByNameN'];
|
||||
createdOn = json['CreatedOn'];
|
||||
direction = json['Direction'];
|
||||
directionID = json['DirectionID'];
|
||||
directionN = json['DirectionN'];
|
||||
dose = json['Dose'];
|
||||
editedBy = json['EditedBy'];
|
||||
iVDiluentLine = json['IVDiluentLine'];
|
||||
iVDiluentType = json['IVDiluentType'];
|
||||
iVDiluentVolume = json['IVDiluentVolume'];
|
||||
iVRate = json['IVRate'];
|
||||
iVStability = json['IVStability'];
|
||||
itemDescription = json['ItemDescription'];
|
||||
itemID = json['ItemID'];
|
||||
lineItemNo = json['LineItemNo'];
|
||||
locationId = json['LocationId'];
|
||||
noOfDoses = json['NoOfDoses'];
|
||||
orderNo = json['OrderNo'];
|
||||
patientID = json['PatientID'];
|
||||
pharmacyRemarks = json['PharmacyRemarks'];
|
||||
prescriptionDatetime = json['PrescriptionDatetime'];
|
||||
prescriptionNo = json['PrescriptionNo'];
|
||||
processedBy = json['ProcessedBy'];
|
||||
projectID = json['ProjectID'];
|
||||
refillID = json['RefillID'];
|
||||
refillType = json['RefillType'];
|
||||
refillTypeN = json['RefillTypeN'];
|
||||
reviewedPharmacist = json['ReviewedPharmacist'];
|
||||
roomId = json['RoomId'];
|
||||
route = json['Route'];
|
||||
routeId = json['RouteId'];
|
||||
routeN = json['RouteN'];
|
||||
setupID = json['SetupID'];
|
||||
startDatetime = json['StartDatetime'];
|
||||
status = json['Status'];
|
||||
statusDescription = json['StatusDescription'];
|
||||
statusDescriptionN = json['StatusDescriptionN'];
|
||||
stopDatetime = json['StopDatetime'];
|
||||
unitofMeasurement = json['UnitofMeasurement'];
|
||||
unitofMeasurementDescription = json['UnitofMeasurementDescription'];
|
||||
unitofMeasurementDescriptionN = json['UnitofMeasurementDescriptionN'];
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['AdmissionNo'] = this.admissionNo;
|
||||
data['AuthorizedBy'] = this.authorizedBy;
|
||||
data['BedNo'] = this.bedNo;
|
||||
data['Comments'] = this.comments;
|
||||
data['CreatedBy'] = this.createdBy;
|
||||
data['CreatedByName'] = this.createdByName;
|
||||
data['CreatedByNameN'] = this.createdByNameN;
|
||||
data['CreatedOn'] = this.createdOn;
|
||||
data['Direction'] = this.direction;
|
||||
data['DirectionID'] = this.directionID;
|
||||
data['DirectionN'] = this.directionN;
|
||||
data['Dose'] = this.dose;
|
||||
data['EditedBy'] = this.editedBy;
|
||||
data['IVDiluentLine'] = this.iVDiluentLine;
|
||||
data['IVDiluentType'] = this.iVDiluentType;
|
||||
data['IVDiluentVolume'] = this.iVDiluentVolume;
|
||||
data['IVRate'] = this.iVRate;
|
||||
data['IVStability'] = this.iVStability;
|
||||
data['ItemDescription'] = this.itemDescription;
|
||||
data['ItemID'] = this.itemID;
|
||||
data['LineItemNo'] = this.lineItemNo;
|
||||
data['LocationId'] = this.locationId;
|
||||
data['NoOfDoses'] = this.noOfDoses;
|
||||
data['OrderNo'] = this.orderNo;
|
||||
data['PatientID'] = this.patientID;
|
||||
data['PharmacyRemarks'] = this.pharmacyRemarks;
|
||||
data['PrescriptionDatetime'] = this.prescriptionDatetime;
|
||||
data['PrescriptionNo'] = this.prescriptionNo;
|
||||
data['ProcessedBy'] = this.processedBy;
|
||||
data['ProjectID'] = this.projectID;
|
||||
data['RefillID'] = this.refillID;
|
||||
data['RefillType'] = this.refillType;
|
||||
data['RefillTypeN'] = this.refillTypeN;
|
||||
data['ReviewedPharmacist'] = this.reviewedPharmacist;
|
||||
data['RoomId'] = this.roomId;
|
||||
data['Route'] = this.route;
|
||||
data['RouteId'] = this.routeId;
|
||||
data['RouteN'] = this.routeN;
|
||||
data['SetupID'] = this.setupID;
|
||||
data['StartDatetime'] = this.startDatetime;
|
||||
data['Status'] = this.status;
|
||||
data['StatusDescription'] = this.statusDescription;
|
||||
data['StatusDescriptionN'] = this.statusDescriptionN;
|
||||
data['StopDatetime'] = this.stopDatetime;
|
||||
data['UnitofMeasurement'] = this.unitofMeasurement;
|
||||
data['UnitofMeasurementDescription'] = this.unitofMeasurementDescription;
|
||||
data['UnitofMeasurementDescriptionN'] = this.unitofMeasurementDescriptionN;
|
||||
return data;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,64 @@
|
||||
class RequestPrescriptionReportForInPatient {
|
||||
int patientID;
|
||||
int projectID;
|
||||
int admissionNo;
|
||||
int languageID;
|
||||
String stamp;
|
||||
String iPAdress;
|
||||
double versionID;
|
||||
int channel;
|
||||
String tokenID;
|
||||
String sessionID;
|
||||
bool isLoginForDoctorApp;
|
||||
bool patientOutSA;
|
||||
int patientTypeID;
|
||||
|
||||
RequestPrescriptionReportForInPatient(
|
||||
{this.patientID,
|
||||
this.projectID,
|
||||
this.admissionNo,
|
||||
this.languageID,
|
||||
this.stamp,
|
||||
this.iPAdress,
|
||||
this.versionID,
|
||||
this.channel,
|
||||
this.tokenID,
|
||||
this.sessionID,
|
||||
this.isLoginForDoctorApp,
|
||||
this.patientOutSA,
|
||||
this.patientTypeID});
|
||||
|
||||
RequestPrescriptionReportForInPatient.fromJson(Map<String, dynamic> json) {
|
||||
patientID = json['PatientID'];
|
||||
projectID = json['ProjectID'];
|
||||
admissionNo = json['AdmissionNo'];
|
||||
languageID = json['LanguageID'];
|
||||
stamp = json['stamp'];
|
||||
iPAdress = json['IPAdress'];
|
||||
versionID = json['VersionID'];
|
||||
channel = json['Channel'];
|
||||
tokenID = json['TokenID'];
|
||||
sessionID = json['SessionID'];
|
||||
isLoginForDoctorApp = json['IsLoginForDoctorApp'];
|
||||
patientOutSA = json['PatientOutSA'];
|
||||
patientTypeID = json['PatientTypeID'];
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['PatientID'] = this.patientID;
|
||||
data['ProjectID'] = this.projectID;
|
||||
data['AdmissionNo'] = this.admissionNo;
|
||||
data['LanguageID'] = this.languageID;
|
||||
data['stamp'] = this.stamp;
|
||||
data['IPAdress'] = this.iPAdress;
|
||||
data['VersionID'] = this.versionID;
|
||||
data['Channel'] = this.channel;
|
||||
data['TokenID'] = this.tokenID;
|
||||
data['SessionID'] = this.sessionID;
|
||||
data['IsLoginForDoctorApp'] = this.isLoginForDoctorApp;
|
||||
data['PatientOutSA'] = this.patientOutSA;
|
||||
data['PatientTypeID'] = this.patientTypeID;
|
||||
return data;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,40 @@
|
||||
import 'package:doctor_app_flutter/config/size_config.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:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class RadiologyReportScreen extends StatelessWidget {
|
||||
final String reportData;
|
||||
|
||||
RadiologyReportScreen({Key key, this.reportData});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return AppScaffold(
|
||||
appBarTitle: "Radiology Report",
|
||||
body: Container(
|
||||
padding: EdgeInsets.all(10),
|
||||
margin: EdgeInsets.all(10),
|
||||
decoration: BoxDecoration(
|
||||
borderRadius:
|
||||
BorderRadius.all(Radius.circular(10)),
|
||||
color: Colors.white,
|
||||
border: Border(
|
||||
bottom: BorderSide(
|
||||
color: Colors.grey, width: 0.5),
|
||||
top: BorderSide(
|
||||
color: Colors.grey, width: 0.5),
|
||||
left: BorderSide(
|
||||
color: Colors.grey, width: 0.5),
|
||||
right: BorderSide(
|
||||
color: Colors.grey, width: 0.5),
|
||||
),
|
||||
),
|
||||
child: AppText(reportData,
|
||||
fontSize: 2.5 * SizeConfig.textMultiplier,
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,75 @@
|
||||
import 'package:doctor_app_flutter/presentation/doctor_app_icons.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
import 'bottom_navigation_item.dart';
|
||||
|
||||
class BottomNavBar extends StatefulWidget {
|
||||
final ValueChanged<int> changeIndex;
|
||||
|
||||
BottomNavBar({Key key, this.changeIndex}) : super(key: key);
|
||||
|
||||
@override
|
||||
_BottomNavBarState createState() => _BottomNavBarState();
|
||||
}
|
||||
|
||||
class _BottomNavBarState extends State<BottomNavBar> {
|
||||
int _index = 0;
|
||||
|
||||
_changeIndex(int index) {
|
||||
widget.changeIndex(index);
|
||||
setState(() {
|
||||
_index = index;
|
||||
});
|
||||
}
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return BottomAppBar(
|
||||
elevation: 4,
|
||||
shape: CircularNotchedRectangle(),
|
||||
color: Colors.white,
|
||||
child: Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 18),
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment: MainAxisAlignment.spaceAround,
|
||||
children: [
|
||||
BottomNavigationItem(
|
||||
icon: DoctorApp.home_icon,
|
||||
activeIcon: DoctorApp.home_icon_active,
|
||||
changeIndex: _changeIndex,
|
||||
index: _index,
|
||||
currentIndex: 0,
|
||||
name: 'HOME',
|
||||
),
|
||||
BottomNavigationItem(
|
||||
icon: DoctorApp.message_icon,
|
||||
activeIcon: DoctorApp.message_icon_active,
|
||||
changeIndex: _changeIndex,
|
||||
index: _index,
|
||||
currentIndex: 1,
|
||||
name: 'REPLAY',
|
||||
),
|
||||
BottomNavigationItem(
|
||||
icon: DoctorApp.schedule_icon,
|
||||
activeIcon: DoctorApp.scdedule_icon_active,
|
||||
changeIndex: _changeIndex,
|
||||
index: _index,
|
||||
currentIndex: 2,
|
||||
name: 'SCHEDULE',
|
||||
),
|
||||
BottomNavigationItem(
|
||||
icon: DoctorApp.menu_icon,
|
||||
activeIcon: DoctorApp.menu_icon_active,
|
||||
changeIndex: _changeIndex,
|
||||
index: _index,
|
||||
currentIndex: 3,
|
||||
name: 'SERVICES',
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,68 @@
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class BottomNavigationItem extends StatelessWidget {
|
||||
final IconData icon;
|
||||
final IconData activeIcon;
|
||||
final ValueChanged<int> changeIndex;
|
||||
final int index;
|
||||
final int currentIndex;
|
||||
final String name;
|
||||
|
||||
BottomNavigationItem(
|
||||
{this.icon,
|
||||
this.activeIcon,
|
||||
this.changeIndex,
|
||||
this.index,
|
||||
this.currentIndex,
|
||||
this.name});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Expanded(
|
||||
child: SizedBox(
|
||||
height: 70.0,
|
||||
child: Material(
|
||||
type: MaterialType.transparency,
|
||||
child: InkWell(
|
||||
highlightColor: Colors.transparent,
|
||||
splashColor: Colors.transparent,
|
||||
onTap: () => changeIndex(currentIndex),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: <Widget>[
|
||||
SizedBox(height: 15,),
|
||||
Container(
|
||||
// decoration: BoxDecoration(boxShadow: [
|
||||
// BoxShadow(
|
||||
// color: currentIndex == index
|
||||
// ? Color.fromRGBO(78, 62, 253, 0.4)
|
||||
// : Color.fromRGBO(78, 62, 253, 0),
|
||||
// blurRadius: 9.0,
|
||||
// spreadRadius: -4.0,
|
||||
// offset: Offset(0.0, 2.0))
|
||||
// ]),
|
||||
child: Icon(currentIndex == index ? activeIcon : icon,
|
||||
/*color: currentIndex == index
|
||||
? Theme.of(context).primaryColor
|
||||
: Theme.of(context).dividerColor,*/
|
||||
size: 22.0),
|
||||
),
|
||||
SizedBox(height: 5,),
|
||||
Text(
|
||||
name,
|
||||
style: TextStyle(
|
||||
color: currentIndex == index
|
||||
? Theme.of(context).primaryColor
|
||||
: Theme.of(context).dividerColor,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue