|
|
|
@ -33,14 +33,14 @@ class _MedicalProfilePageState extends State<MedicalProfilePageNew> {
|
|
|
|
|
ProjectViewModel? projectViewModel;
|
|
|
|
|
|
|
|
|
|
List<HospitalsModel> projectsList = [];
|
|
|
|
|
HospitalsModel _selectedHospital;
|
|
|
|
|
HospitalsModel? _selectedHospital;
|
|
|
|
|
|
|
|
|
|
@override
|
|
|
|
|
Widget build(BuildContext context) {
|
|
|
|
|
projectViewModel = Provider.of(context);
|
|
|
|
|
var appoCountProvider = Provider.of<ToDoCountProviderModel>(context);
|
|
|
|
|
List<Widget> myMedicalList =
|
|
|
|
|
Utils.myMedicalList(projectViewModel: projectViewModel, context: context, count: appoCountProvider.count, isLogin: projectViewModel.isLogin, onWeCareClick: openWeCareProjectSelection);
|
|
|
|
|
Utils.myMedicalList(projectViewModel: projectViewModel!, context: context, count: appoCountProvider.count, isLogin: projectViewModel!.isLogin, onWeCareClick: openWeCareProjectSelection);
|
|
|
|
|
return BaseView<MedicalViewModel>(
|
|
|
|
|
onModelReady: (model) => model.getAppointmentHistory(isForTimeLine: true),
|
|
|
|
|
builder: (_, model, widget1) => AppScaffold(
|
|
|
|
@ -113,7 +113,7 @@ class _MedicalProfilePageState extends State<MedicalProfilePageNew> {
|
|
|
|
|
|
|
|
|
|
openWeCareProjectSelection() {
|
|
|
|
|
int _selectedHospitalIndex = -1;
|
|
|
|
|
int languageID = projectViewModel.isArabic ? 1 : 2;
|
|
|
|
|
int languageID = projectViewModel!.isArabic ? 1 : 2;
|
|
|
|
|
GifLoaderDialogUtils.showMyDialog(context);
|
|
|
|
|
ClinicListService service = new ClinicListService();
|
|
|
|
|
List<HospitalsModel> projectsListLocal = [];
|
|
|
|
@ -127,7 +127,7 @@ class _MedicalProfilePageState extends State<MedicalProfilePageNew> {
|
|
|
|
|
});
|
|
|
|
|
GifLoaderDialogUtils.hideDialog(context);
|
|
|
|
|
List<RadioSelectionDialogModel> list = [
|
|
|
|
|
for (int i = 0; i < projectsList.length; i++) RadioSelectionDialogModel(projectsList[i].name + ' ${projectsList[i].distanceInKilometers} ' + TranslationBase.of(context).km, i),
|
|
|
|
|
for (int i = 0; i < projectsList.length; i++) RadioSelectionDialogModel(projectsList[i].name! + ' ${projectsList[i].distanceInKilometers} ' + TranslationBase.of(context).km, i),
|
|
|
|
|
];
|
|
|
|
|
showDialog(
|
|
|
|
|
context: context,
|
|
|
|
@ -139,7 +139,7 @@ class _MedicalProfilePageState extends State<MedicalProfilePageNew> {
|
|
|
|
|
onValueSelected: (index) {
|
|
|
|
|
_selectedHospitalIndex = index;
|
|
|
|
|
_selectedHospital = projectsList[index];
|
|
|
|
|
openWeCareURL(_selectedHospital.iD);
|
|
|
|
|
openWeCareURL(_selectedHospital!.iD);
|
|
|
|
|
// setState(() {});
|
|
|
|
|
},
|
|
|
|
|
),
|
|
|
|
|