add doctor profile

merge-requests/606/head
Elham Rababah 5 years ago
parent 3e2323fbc0
commit 05a3ca7300

@ -559,7 +559,7 @@ class _HomeScreenState extends State<HomeScreen> {
isSearch: false, isSearch: false,
isInpatient: false, isInpatient: false,
patientSearchRequestModel: patientSearchRequestModel:
PatientSearchRequestModel(from: date, to: date), PatientSearchRequestModel(from: date, to: date,doctorID: authProvider.doctorProfile.doctorID),
selectedPatientType: selectedPatientType:
PatientType.OutPatient, PatientType.OutPatient,
isSearchWithKeyInfo: false, isSearchWithKeyInfo: false,

@ -1,6 +1,7 @@
import 'package:doctor_app_flutter/core/enum/patient_type.dart'; import 'package:doctor_app_flutter/core/enum/patient_type.dart';
import 'package:doctor_app_flutter/core/model/PatientSearchRequestModel.dart'; import 'package:doctor_app_flutter/core/model/PatientSearchRequestModel.dart';
import 'package:doctor_app_flutter/core/viewModel/PatientSearchViewModel.dart'; import 'package:doctor_app_flutter/core/viewModel/PatientSearchViewModel.dart';
import 'package:doctor_app_flutter/core/viewModel/auth_view_model.dart';
import 'package:doctor_app_flutter/screens/base/base_view.dart'; import 'package:doctor_app_flutter/screens/base/base_view.dart';
import 'package:doctor_app_flutter/screens/patients/patient_search/patients_screen_new.dart'; import 'package:doctor_app_flutter/screens/patients/patient_search/patients_screen_new.dart';
import 'package:doctor_app_flutter/screens/patients/profile/soap_update/shared_soap_widgets/bottom_sheet_title.dart'; import 'package:doctor_app_flutter/screens/patients/profile/soap_update/shared_soap_widgets/bottom_sheet_title.dart';
@ -12,6 +13,7 @@ import 'package:doctor_app_flutter/widgets/shared/loader/gif_loader_dialog_utils
import 'package:doctor_app_flutter/widgets/shared/text_fields/app-textfield-custom.dart'; import 'package:doctor_app_flutter/widgets/shared/text_fields/app-textfield-custom.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:hexcolor/hexcolor.dart'; import 'package:hexcolor/hexcolor.dart';
import 'package:provider/provider.dart';
class PatientSearchScreenNew extends StatefulWidget { class PatientSearchScreenNew extends StatefulWidget {
@override @override
@ -26,9 +28,11 @@ class _PatientSearchScreenNewState extends State<PatientSearchScreenNew> {
TextEditingController middleNameInfoController = TextEditingController(); TextEditingController middleNameInfoController = TextEditingController();
TextEditingController lastNameFileInfoController = TextEditingController(); TextEditingController lastNameFileInfoController = TextEditingController();
PatientType selectedPatientType = PatientType.inPatient; PatientType selectedPatientType = PatientType.inPatient;
AuthViewModel authProvider;
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
authProvider =Provider.of(context);
return BaseView<PatientSearchViewModel>( return BaseView<PatientSearchViewModel>(
onModelReady: (model) async {}, onModelReady: (model) async {},
builder: (_, model, w) => AppScaffold( builder: (_, model, w) => AppScaffold(
@ -248,7 +252,7 @@ class _PatientSearchScreenNewState extends State<PatientSearchScreenNew> {
isFormSubmitted = true; isFormSubmitted = true;
}); });
PatientSearchRequestModel patientSearchRequestModel = PatientSearchRequestModel patientSearchRequestModel =
PatientSearchRequestModel(); PatientSearchRequestModel(doctorID: authProvider.doctorProfile.doctorID);
if (showOther) { if (showOther) {
patientSearchRequestModel.firstName = firstNameInfoController.text.trim().isEmpty?"0":firstNameInfoController.text.trim(); patientSearchRequestModel.firstName = firstNameInfoController.text.trim().isEmpty?"0":firstNameInfoController.text.trim();
patientSearchRequestModel.middleName = middleNameInfoController.text.trim().isEmpty?"0":middleNameInfoController.text.trim(); patientSearchRequestModel.middleName = middleNameInfoController.text.trim().isEmpty?"0":middleNameInfoController.text.trim();

@ -100,14 +100,8 @@ class _PatientsScreenNewState extends State<PatientsScreenNew> {
title: "Search for ${widget.searchKey}", title: "Search for ${widget.searchKey}",
), ),
baseViewModel: model, baseViewModel: model,
body: Container( body: Column(
color: Colors.grey[200], children: [
child: ListView(
scrollDirection: Axis.vertical,
children: <Widget>[
Container(
child: Column(
children: <Widget>[
if(!widget.isInpatient && !widget.isSearch) if(!widget.isInpatient && !widget.isSearch)
Container( Container(
// color: Colors.red, // color: Colors.red,
@ -212,6 +206,16 @@ class _PatientsScreenNewState extends State<PatientsScreenNew> {
SizedBox( SizedBox(
height: 10.0, height: 10.0,
), ),
Expanded(
child: Container(
// color: Colors.grey[200],
child: ListView(
scrollDirection: Axis.vertical,
children: <Widget>[
Container(
child: Column(
children: <Widget>[
SizedBox( SizedBox(
height: 10.0, height: 10.0,
), ),
@ -281,6 +285,9 @@ class _PatientsScreenNewState extends State<PatientsScreenNew> {
) )
], ],
), ),
),
),
],
) )
), ),
); );

Loading…
Cancel
Save