voice command

fix_authentication
Sultan Khan 4 years ago
parent f03a711dff
commit 23b48485ed

@ -66,7 +66,8 @@ class DoctorsListService extends BaseService {
// "Latitude": 0,
// "Longitude": 0,
// "License": true,
"IsVoiceCommand": doctorId != null && doctorId.length > 0 ? true : false,
"SearchForVoiceCommand":
doctorId != null && doctorId.length > 0 ? true : false,
"DoctorIDsList": doctorId,
"Latitude": lat != null ? lat.toString() : 0,
"Longitude": long != null ? long.toString() : 0,
@ -212,8 +213,8 @@ class DoctorsListService extends BaseService {
return Future.value(localRes);
}
Future<Map> getDoctorScheduledFreeSlots(
int docID, int clinicID, int projectID, int serviceID, BuildContext context) async {
Future<Map> getDoctorScheduledFreeSlots(int docID, int clinicID,
int projectID, int serviceID, BuildContext context) async {
Map<String, dynamic> request;
var languageID = await sharedPref.getString(APP_LANGUAGE);
Request req = appGlobal.getPublicRequest();
@ -241,10 +242,10 @@ class DoctorsListService extends BaseService {
await baseAppClient.post(GET_LIVECARE_SCHEDULE_DOCTOR_TIME_SLOTS,
onSuccess: (response, statusCode) async {
localRes = response;
}, onFailure: (String error, int statusCode) {
throw error;
}, body: request);
localRes = response;
}, onFailure: (String error, int statusCode) {
throw error;
}, body: request);
return Future.value(localRes);
}
@ -301,8 +302,14 @@ class DoctorsListService extends BaseService {
return Future.value(localRes);
}
Future<Map> insertLiveCareScheduleAppointment(int docID, int clinicID, int projectID, int serviceID,
String selectedTime, String selectedDate, BuildContext context) async {
Future<Map> insertLiveCareScheduleAppointment(
int docID,
int clinicID,
int projectID,
int serviceID,
String selectedTime,
String selectedDate,
BuildContext context) async {
Map<String, dynamic> request;
if (await this.sharedPref.getObject(USER_PROFILE) != null) {
@ -348,10 +355,10 @@ class DoctorsListService extends BaseService {
await baseAppClient.post(INSERT_LIVECARE_SCHEDULE_APPOINTMENT,
onSuccess: (response, statusCode) async {
localRes = response;
}, onFailure: (String error, int statusCode) {
throw error;
}, body: request);
localRes = response;
}, onFailure: (String error, int statusCode) {
throw error;
}, body: request);
return Future.value(localRes);
}
@ -437,10 +444,10 @@ class DoctorsListService extends BaseService {
await baseAppClient.post(GET_PATIENT_SHARE_LIVECARE,
onSuccess: (response, statusCode) async {
localRes = response['OnlineCheckInAppointments'][0];
}, onFailure: (String error, int statusCode) {
throw error;
}, body: request);
localRes = response['OnlineCheckInAppointments'][0];
}, onFailure: (String error, int statusCode) {
throw error;
}, body: request);
return Future.value(localRes);
}
@ -519,8 +526,8 @@ class DoctorsListService extends BaseService {
return Future.value(localRes);
}
Future<Map> confirmAppointment(
int appoNo, int clinicID, int projectID, bool isLiveCare, BuildContext context) async {
Future<Map> confirmAppointment(int appoNo, int clinicID, int projectID,
bool isLiveCare, BuildContext context) async {
Map<String, dynamic> request;
if (await this.sharedPref.getObject(USER_PROFILE) != null) {
@ -564,9 +571,8 @@ class DoctorsListService extends BaseService {
return Future.value(localRes);
}
Future<Map> insertVIDARequest(
int appoNo, int clinicID, int projectID, int serviceID, int docID, BuildContext context) async {
Future<Map> insertVIDARequest(int appoNo, int clinicID, int projectID,
int serviceID, int docID, BuildContext context) async {
Map<String, dynamic> request;
if (await this.sharedPref.getObject(USER_PROFILE) != null) {
@ -613,10 +619,10 @@ class DoctorsListService extends BaseService {
await baseAppClient.post(INSERT_VIDA_REQUEST,
onSuccess: (response, statusCode) async {
localRes = response;
}, onFailure: (String error, int statusCode) {
throw error;
}, body: request);
localRes = response;
}, onFailure: (String error, int statusCode) {
throw error;
}, body: request);
return Future.value(localRes);
}

@ -50,7 +50,8 @@ class AppScaffold extends StatelessWidget {
this.floatingActionButton,
this.title,
this.description,
this.isShowDecPage = true, this.isBottomBar});
this.isShowDecPage = true,
this.isBottomBar});
@override
Widget build(BuildContext context) {
@ -68,7 +69,8 @@ class AppScaffold extends StatelessWidget {
),
title: Text(authenticatedUserObject.isLogin
? appBarTitle.toUpperCase()
: TranslationBase.of(context).serviceInformationTitle),leading: Builder(
: TranslationBase.of(context).serviceInformationTitle),
leading: Builder(
builder: (BuildContext context) {
return ArrowBack();
},
@ -79,7 +81,10 @@ class AppScaffold extends StatelessWidget {
icon: Icon(FontAwesomeIcons.home),
color: Colors.white,
onPressed: () {
Navigator.pushAndRemoveUntil(context, MaterialPageRoute(builder: (context) => LandingPage()), (Route<dynamic> r) => false);
Navigator.pushAndRemoveUntil(
context,
MaterialPageRoute(builder: (context) => LandingPage()),
(Route<dynamic> r) => false);
},
),
],
@ -90,14 +95,14 @@ class AppScaffold extends StatelessWidget {
title: appBarTitle,
description: description,
)
:baseViewModel != null
? NetworkBaseView(
child: buildBodyWidget(),
baseViewModel: baseViewModel,
)
: buildBodyWidget(),
: baseViewModel != null
? NetworkBaseView(
child: buildBodyWidget(),
baseViewModel: baseViewModel,
)
: buildBodyWidget(),
bottomSheet: bottomSheet,
floatingActionButton: floatingActionButton ?? floatingActionButton,
//floatingActionButton: floatingActionButton ?? floatingActionButton,
// bottomNavigationBar:
// this.isBottomBar == true ? BottomBarSearch() : SizedBox()
// floatingActionButton: FloatingSearchButton(),

Loading…
Cancel
Save