Merge branch 'development' of https://gitlab.com/Cloud_Solution/diplomatic-quarter into Haroon
commit
0d2a91c124
Binary file not shown.
Before Width: | Height: | Size: 147 KiB After Width: | Height: | Size: 23 KiB |
Binary file not shown.
After Width: | Height: | Size: 147 KiB |
@ -0,0 +1,198 @@
|
||||
class DoctorListByTimeModel {
|
||||
dynamic clinicID;
|
||||
String clinicName;
|
||||
String doctorTitle;
|
||||
dynamic iD;
|
||||
String name;
|
||||
dynamic projectID;
|
||||
String projectName;
|
||||
dynamic actualDoctorRate;
|
||||
dynamic clinicRoomNo;
|
||||
dynamic date;
|
||||
dynamic dayName;
|
||||
double decimalDoctorRate;
|
||||
dynamic doctorAvailability;
|
||||
dynamic doctorID;
|
||||
String doctorImageURL;
|
||||
dynamic doctorProfile;
|
||||
dynamic doctorProfileInfo;
|
||||
dynamic doctorRate;
|
||||
dynamic doctorStarsRate;
|
||||
dynamic gender;
|
||||
String genderDescription;
|
||||
bool isAllowWaitList;
|
||||
bool isAppointmentAllowed;
|
||||
bool isDoctorAllowVedioCall;
|
||||
bool isDoctorDummy;
|
||||
bool isDoctorHasPrePostImages;
|
||||
bool isLiveCare;
|
||||
String latitude;
|
||||
String longitude;
|
||||
String nationalityFlagURL;
|
||||
String nationalityID;
|
||||
String nationalityName;
|
||||
dynamic nearestFreeSlot;
|
||||
dynamic noOfPatientsRate;
|
||||
dynamic originalClinicID;
|
||||
dynamic personRate;
|
||||
dynamic projectDistanceInKiloMeters;
|
||||
String qR;
|
||||
dynamic qRString;
|
||||
dynamic rateNumber;
|
||||
dynamic serviceID;
|
||||
String setupID;
|
||||
List<String> speciality;
|
||||
dynamic workingHours;
|
||||
|
||||
DoctorListByTimeModel(
|
||||
{this.clinicID,
|
||||
this.clinicName,
|
||||
this.doctorTitle,
|
||||
this.iD,
|
||||
this.name,
|
||||
this.projectID,
|
||||
this.projectName,
|
||||
this.actualDoctorRate,
|
||||
this.clinicRoomNo,
|
||||
this.date,
|
||||
this.dayName,
|
||||
this.decimalDoctorRate,
|
||||
this.doctorAvailability,
|
||||
this.doctorID,
|
||||
this.doctorImageURL,
|
||||
this.doctorProfile,
|
||||
this.doctorProfileInfo,
|
||||
this.doctorRate,
|
||||
this.doctorStarsRate,
|
||||
this.gender,
|
||||
this.genderDescription,
|
||||
this.isAllowWaitList,
|
||||
this.isAppointmentAllowed,
|
||||
this.isDoctorAllowVedioCall,
|
||||
this.isDoctorDummy,
|
||||
this.isDoctorHasPrePostImages,
|
||||
this.isLiveCare,
|
||||
this.latitude,
|
||||
this.longitude,
|
||||
this.nationalityFlagURL,
|
||||
this.nationalityID,
|
||||
this.nationalityName,
|
||||
this.nearestFreeSlot,
|
||||
this.noOfPatientsRate,
|
||||
this.originalClinicID,
|
||||
this.personRate,
|
||||
this.projectDistanceInKiloMeters,
|
||||
this.qR,
|
||||
this.qRString,
|
||||
this.rateNumber,
|
||||
this.serviceID,
|
||||
this.setupID,
|
||||
this.speciality,
|
||||
this.workingHours});
|
||||
|
||||
DoctorListByTimeModel.fromJson(Map<String, dynamic> json) {
|
||||
clinicID = json['ClinicID'];
|
||||
clinicName = json['ClinicName'];
|
||||
doctorTitle = json['DoctorTitle'];
|
||||
iD = json['ID'];
|
||||
name = json['Name'];
|
||||
projectID = json['ProjectID'];
|
||||
projectName = json['ProjectName'];
|
||||
actualDoctorRate = json['ActualDoctorRate'];
|
||||
clinicRoomNo = json['ClinicRoomNo'];
|
||||
date = json['Date'];
|
||||
dayName = json['DayName'];
|
||||
decimalDoctorRate = json['DecimalDoctorRate'];
|
||||
doctorAvailability = json['DoctorAvailability'];
|
||||
doctorID = json['DoctorID'];
|
||||
doctorImageURL = json['DoctorImageURL'];
|
||||
doctorProfile = json['DoctorProfile'];
|
||||
doctorProfileInfo = json['DoctorProfileInfo'];
|
||||
doctorRate = json['DoctorRate'];
|
||||
doctorStarsRate = json['DoctorStarsRate'];
|
||||
gender = json['Gender'];
|
||||
genderDescription = json['GenderDescription'];
|
||||
isAllowWaitList = json['IsAllowWaitList'];
|
||||
isAppointmentAllowed = json['IsAppointmentAllowed'];
|
||||
isDoctorAllowVedioCall = json['IsDoctorAllowVedioCall'];
|
||||
isDoctorDummy = json['IsDoctorDummy'];
|
||||
isDoctorHasPrePostImages = json['IsDoctorHasPrePostImages'];
|
||||
isLiveCare = json['IsLiveCare'];
|
||||
latitude = json['Latitude'];
|
||||
longitude = json['Longitude'];
|
||||
nationalityFlagURL = json['NationalityFlagURL'];
|
||||
nationalityID = json['NationalityID'];
|
||||
nationalityName = json['NationalityName'];
|
||||
nearestFreeSlot = json['NearestFreeSlot'];
|
||||
noOfPatientsRate = json['NoOfPatientsRate'];
|
||||
originalClinicID = json['OriginalClinicID'];
|
||||
personRate = json['PersonRate'];
|
||||
projectDistanceInKiloMeters = json['ProjectDistanceInKiloMeters'];
|
||||
qR = json['QR'];
|
||||
qRString = json['QRString'];
|
||||
rateNumber = json['RateNumber'];
|
||||
serviceID = json['ServiceID'];
|
||||
setupID = json['SetupID'];
|
||||
speciality = json['Speciality'].cast<String>();
|
||||
workingHours = json['WorkingHours'];
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['ClinicID'] = this.clinicID;
|
||||
data['ClinicName'] = this.clinicName;
|
||||
data['DoctorTitle'] = this.doctorTitle;
|
||||
data['ID'] = this.iD;
|
||||
data['Name'] = this.name;
|
||||
data['ProjectID'] = this.projectID;
|
||||
data['ProjectName'] = this.projectName;
|
||||
data['ActualDoctorRate'] = this.actualDoctorRate;
|
||||
data['ClinicRoomNo'] = this.clinicRoomNo;
|
||||
data['Date'] = this.date;
|
||||
data['DayName'] = this.dayName;
|
||||
data['DecimalDoctorRate'] = this.decimalDoctorRate;
|
||||
data['DoctorAvailability'] = this.doctorAvailability;
|
||||
data['DoctorID'] = this.doctorID;
|
||||
data['DoctorImageURL'] = this.doctorImageURL;
|
||||
data['DoctorProfile'] = this.doctorProfile;
|
||||
data['DoctorProfileInfo'] = this.doctorProfileInfo;
|
||||
data['DoctorRate'] = this.doctorRate;
|
||||
data['DoctorStarsRate'] = this.doctorStarsRate;
|
||||
data['Gender'] = this.gender;
|
||||
data['GenderDescription'] = this.genderDescription;
|
||||
data['IsAllowWaitList'] = this.isAllowWaitList;
|
||||
data['IsAppointmentAllowed'] = this.isAppointmentAllowed;
|
||||
data['IsDoctorAllowVedioCall'] = this.isDoctorAllowVedioCall;
|
||||
data['IsDoctorDummy'] = this.isDoctorDummy;
|
||||
data['IsDoctorHasPrePostImages'] = this.isDoctorHasPrePostImages;
|
||||
data['IsLiveCare'] = this.isLiveCare;
|
||||
data['Latitude'] = this.latitude;
|
||||
data['Longitude'] = this.longitude;
|
||||
data['NationalityFlagURL'] = this.nationalityFlagURL;
|
||||
data['NationalityID'] = this.nationalityID;
|
||||
data['NationalityName'] = this.nationalityName;
|
||||
data['NearestFreeSlot'] = this.nearestFreeSlot;
|
||||
data['NoOfPatientsRate'] = this.noOfPatientsRate;
|
||||
data['OriginalClinicID'] = this.originalClinicID;
|
||||
data['PersonRate'] = this.personRate;
|
||||
data['ProjectDistanceInKiloMeters'] = this.projectDistanceInKiloMeters;
|
||||
data['QR'] = this.qR;
|
||||
data['QRString'] = this.qRString;
|
||||
data['RateNumber'] = this.rateNumber;
|
||||
data['ServiceID'] = this.serviceID;
|
||||
data['SetupID'] = this.setupID;
|
||||
data['Speciality'] = this.speciality;
|
||||
data['WorkingHours'] = this.workingHours;
|
||||
return data;
|
||||
}
|
||||
}
|
||||
|
||||
class DoctorsListTime {
|
||||
List<DoctorListByTimeModel> doctorsByTimeList = List();
|
||||
String filterName = "";
|
||||
|
||||
DoctorsListTime({filterName, DoctorListByTimeModel doctor}) {
|
||||
doctorsByTimeList.add(doctor);
|
||||
this.filterName = filterName;
|
||||
}
|
||||
}
|
@ -0,0 +1,80 @@
|
||||
class DoctorListByTimeRequestModel {
|
||||
int clinicID;
|
||||
bool isGetNearAppointment;
|
||||
bool continueDentalPlan;
|
||||
bool isSearchAppointmnetByClinicID;
|
||||
int patientID;
|
||||
int latitude;
|
||||
int longitude;
|
||||
bool license;
|
||||
double versionID;
|
||||
int channel;
|
||||
int languageID;
|
||||
String iPAdress;
|
||||
String generalid;
|
||||
int patientOutSA;
|
||||
dynamic sessionID;
|
||||
bool isDentalAllowedBackend;
|
||||
int deviceTypeID;
|
||||
|
||||
DoctorListByTimeRequestModel(
|
||||
{this.clinicID,
|
||||
this.isGetNearAppointment,
|
||||
this.continueDentalPlan,
|
||||
this.isSearchAppointmnetByClinicID,
|
||||
this.patientID,
|
||||
this.latitude,
|
||||
this.longitude,
|
||||
this.license,
|
||||
this.versionID,
|
||||
this.channel,
|
||||
this.languageID,
|
||||
this.iPAdress,
|
||||
this.generalid,
|
||||
this.patientOutSA,
|
||||
this.sessionID,
|
||||
this.isDentalAllowedBackend,
|
||||
this.deviceTypeID});
|
||||
|
||||
DoctorListByTimeRequestModel.fromJson(Map<String, dynamic> json) {
|
||||
clinicID = json['ClinicID'];
|
||||
isGetNearAppointment = json['IsGetNearAppointment'];
|
||||
continueDentalPlan = json['ContinueDentalPlan'];
|
||||
isSearchAppointmnetByClinicID = json['IsSearchAppointmnetByClinicID'];
|
||||
patientID = json['PatientID'];
|
||||
latitude = json['Latitude'];
|
||||
longitude = json['Longitude'];
|
||||
license = json['License'];
|
||||
versionID = json['VersionID'];
|
||||
channel = json['Channel'];
|
||||
languageID = json['LanguageID'];
|
||||
iPAdress = json['IPAdress'];
|
||||
generalid = json['generalid'];
|
||||
patientOutSA = json['PatientOutSA'];
|
||||
sessionID = json['SessionID'];
|
||||
isDentalAllowedBackend = json['isDentalAllowedBackend'];
|
||||
deviceTypeID = json['DeviceTypeID'];
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['ClinicID'] = this.clinicID;
|
||||
data['IsGetNearAppointment'] = this.isGetNearAppointment;
|
||||
data['ContinueDentalPlan'] = this.continueDentalPlan;
|
||||
data['IsSearchAppointmnetByClinicID'] = this.isSearchAppointmnetByClinicID;
|
||||
data['PatientID'] = this.patientID;
|
||||
data['Latitude'] = this.latitude;
|
||||
data['Longitude'] = this.longitude;
|
||||
data['License'] = this.license;
|
||||
data['VersionID'] = this.versionID;
|
||||
data['Channel'] = this.channel;
|
||||
data['LanguageID'] = this.languageID;
|
||||
data['IPAdress'] = this.iPAdress;
|
||||
data['generalid'] = this.generalid;
|
||||
data['PatientOutSA'] = this.patientOutSA;
|
||||
data['SessionID'] = this.sessionID;
|
||||
data['isDentalAllowedBackend'] = this.isDentalAllowedBackend;
|
||||
data['DeviceTypeID'] = this.deviceTypeID;
|
||||
return data;
|
||||
}
|
||||
}
|
@ -0,0 +1,64 @@
|
||||
class GetDoctorListModel {
|
||||
int calcID;
|
||||
int projectID;
|
||||
int clinicID;
|
||||
String clinicName;
|
||||
int doctorID;
|
||||
String doctorImageURL;
|
||||
String doctorName;
|
||||
String doctorTitle;
|
||||
int gender;
|
||||
String genderDescription;
|
||||
String nationality;
|
||||
String nationalityFlagURL;
|
||||
String projectName;
|
||||
|
||||
GetDoctorListModel(
|
||||
{this.calcID,
|
||||
this.projectID,
|
||||
this.clinicID,
|
||||
this.clinicName,
|
||||
this.doctorID,
|
||||
this.doctorImageURL,
|
||||
this.doctorName,
|
||||
this.doctorTitle,
|
||||
this.gender,
|
||||
this.genderDescription,
|
||||
this.nationality,
|
||||
this.nationalityFlagURL,
|
||||
this.projectName});
|
||||
|
||||
GetDoctorListModel.fromJson(Map<String, dynamic> json) {
|
||||
calcID = json['CalcID'];
|
||||
projectID = json['ProjectID'];
|
||||
clinicID = json['ClinicID'];
|
||||
clinicName = json['ClinicName'];
|
||||
doctorID = json['DoctorID'];
|
||||
doctorImageURL = json['DoctorImageURL'];
|
||||
doctorName = json['DoctorName'];
|
||||
doctorTitle = json['DoctorTitle'];
|
||||
gender = json['Gender'];
|
||||
genderDescription = json['GenderDescription'];
|
||||
nationality = json['Nationality'];
|
||||
nationalityFlagURL = json['NationalityFlagURL'];
|
||||
projectName = json['ProjectName'];
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['CalcID'] = this.calcID;
|
||||
data['ProjectID'] = this.projectID;
|
||||
data['ClinicID'] = this.clinicID;
|
||||
data['ClinicName'] = this.clinicName;
|
||||
data['DoctorID'] = this.doctorID;
|
||||
data['DoctorImageURL'] = this.doctorImageURL;
|
||||
data['DoctorName'] = this.doctorName;
|
||||
data['DoctorTitle'] = this.doctorTitle;
|
||||
data['Gender'] = this.gender;
|
||||
data['GenderDescription'] = this.genderDescription;
|
||||
data['Nationality'] = this.nationality;
|
||||
data['NationalityFlagURL'] = this.nationalityFlagURL;
|
||||
data['ProjectName'] = this.projectName;
|
||||
return data;
|
||||
}
|
||||
}
|
@ -0,0 +1,52 @@
|
||||
class GetDoctorListRequestModel {
|
||||
int calculationID;
|
||||
double versionID;
|
||||
int channel;
|
||||
int languageID;
|
||||
String iPAdress;
|
||||
String generalid;
|
||||
int patientOutSA;
|
||||
String sessionID;
|
||||
bool isDentalAllowedBackend;
|
||||
int deviceTypeID;
|
||||
|
||||
GetDoctorListRequestModel(
|
||||
{this.calculationID,
|
||||
this.versionID,
|
||||
this.channel,
|
||||
this.languageID,
|
||||
this.iPAdress,
|
||||
this.generalid,
|
||||
this.patientOutSA,
|
||||
this.sessionID,
|
||||
this.isDentalAllowedBackend,
|
||||
this.deviceTypeID});
|
||||
|
||||
GetDoctorListRequestModel.fromJson(Map<String, dynamic> json) {
|
||||
calculationID = json['CalculationID'];
|
||||
versionID = json['VersionID'];
|
||||
channel = json['Channel'];
|
||||
languageID = json['LanguageID'];
|
||||
iPAdress = json['IPAdress'];
|
||||
generalid = json['generalid'];
|
||||
patientOutSA = json['PatientOutSA'];
|
||||
sessionID = json['SessionID'];
|
||||
isDentalAllowedBackend = json['isDentalAllowedBackend'];
|
||||
deviceTypeID = json['DeviceTypeID'];
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
final Map<String, dynamic> data = new Map<String, dynamic>();
|
||||
data['CalculationID'] = this.calculationID;
|
||||
data['VersionID'] = this.versionID;
|
||||
data['Channel'] = this.channel;
|
||||
data['LanguageID'] = this.languageID;
|
||||
data['IPAdress'] = this.iPAdress;
|
||||
data['generalid'] = this.generalid;
|
||||
data['PatientOutSA'] = this.patientOutSA;
|
||||
data['SessionID'] = this.sessionID;
|
||||
data['isDentalAllowedBackend'] = this.isDentalAllowedBackend;
|
||||
data['DeviceTypeID'] = this.deviceTypeID;
|
||||
return data;
|
||||
}
|
||||
}
|
@ -0,0 +1,126 @@
|
||||
import 'package:diplomaticquarterapp/core/viewModels/AlHabibMedicalService/health-calculator/Bariatrics-viewmodel.dart';
|
||||
import 'package:diplomaticquarterapp/pages/base/base_view.dart';
|
||||
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
|
||||
import 'package:diplomaticquarterapp/widgets/data_display/text.dart';
|
||||
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:rating_bar/rating_bar.dart';
|
||||
|
||||
class DoctorList extends StatelessWidget {
|
||||
const DoctorList({Key key}) : super(key: key);
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return BaseView<BariatricsViewModel>(
|
||||
allowAny: true,
|
||||
onModelReady: (model) => model.getDoctorList(),
|
||||
builder: (BuildContext context, BariatricsViewModel model, Widget child) => AppScaffold(
|
||||
isShowDecPage: false,
|
||||
isShowAppBar: true,
|
||||
baseViewModel: model,
|
||||
appBarTitle: "Doctors List",
|
||||
description: TranslationBase.of(context).infoApprovals,
|
||||
infoList: TranslationBase.of(context).infoApprovalPoints,
|
||||
body: ListView.builder(
|
||||
itemCount: model.doctorLists.length,
|
||||
itemBuilder: (BuildContext context, int index) {
|
||||
return Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 16.0, vertical: 10.0),
|
||||
child: Container(
|
||||
//height: MediaQuery.of(context).size.height * 0.09,
|
||||
decoration: BoxDecoration(color: Colors.white),
|
||||
|
||||
child: ExpansionTile(
|
||||
title: Padding(
|
||||
padding: EdgeInsets.all(21.0),
|
||||
child: Texts(model.doctorLists[index].filterName),
|
||||
),
|
||||
children: model.doctorLists[index].doctorsByTimeList
|
||||
.map((doctor) => Card(
|
||||
margin: EdgeInsets.fromLTRB(10.0, 16.0, 10.0, 8.0),
|
||||
color: Colors.white,
|
||||
shape: RoundedRectangleBorder(
|
||||
borderRadius: BorderRadius.circular(10),
|
||||
),
|
||||
child: Container(
|
||||
decoration: BoxDecoration(),
|
||||
padding: EdgeInsets.all(7.0),
|
||||
width: MediaQuery.of(context).size.width,
|
||||
child: Row(
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
children: <Widget>[
|
||||
Expanded(
|
||||
flex: 1,
|
||||
child: ClipRRect(
|
||||
borderRadius: BorderRadius.circular(100.0),
|
||||
child: Image.network(doctor.doctorImageURL,
|
||||
fit: BoxFit.fill, height: 60.0, width: 60.0),
|
||||
),
|
||||
),
|
||||
Expanded(
|
||||
flex: 4,
|
||||
child: Container(
|
||||
width: MediaQuery.of(context).size.width * 0.55,
|
||||
margin: EdgeInsets.fromLTRB(20.0, 10.0, 10.0, 0.0),
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: <Widget>[
|
||||
if (doctor.doctorTitle != null)
|
||||
Text(doctor.doctorTitle + " " + doctor.name,
|
||||
style: TextStyle(
|
||||
fontSize: 14.0,
|
||||
color: Colors.grey[700],
|
||||
letterSpacing: 1.0)),
|
||||
Container(
|
||||
margin: EdgeInsets.only(top: 3.0),
|
||||
child: Text(doctor.clinicName != null ? doctor.clinicName : "",
|
||||
style: TextStyle(
|
||||
fontSize: 12.0,
|
||||
color: Colors.grey[600],
|
||||
letterSpacing: 1.0)),
|
||||
),
|
||||
Container(
|
||||
margin: EdgeInsets.only(top: 3.0),
|
||||
child: Text(doctor.projectName,
|
||||
style: TextStyle(
|
||||
fontSize: 12.0,
|
||||
color: Colors.grey[600],
|
||||
letterSpacing: 1.0)),
|
||||
),
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
children: <Widget>[
|
||||
RatingBar.readOnly(
|
||||
initialRating: doctor.actualDoctorRate.toDouble(),
|
||||
size: 20.0,
|
||||
filledColor: Colors.yellow[700],
|
||||
emptyColor: Colors.grey[500],
|
||||
isHalfAllowed: true,
|
||||
halfFilledIcon: Icons.star_half,
|
||||
filledIcon: Icons.star,
|
||||
emptyIcon: Icons.star,
|
||||
),
|
||||
Container(
|
||||
child: Image.network(doctor.nationalityFlagURL,
|
||||
width: 25.0, height: 25.0),
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
))
|
||||
.toList(),
|
||||
),
|
||||
),
|
||||
);
|
||||
}),
|
||||
));
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue