fix doctor id spelling in live care service, fix colors in

merge-requests/724/head
Elham Rababah 5 years ago
parent d57b331df2
commit f80215b6bb

@ -1,4 +1,3 @@
import 'dart:collection';
import 'package:doctor_app_flutter/config/config.dart'; import 'package:doctor_app_flutter/config/config.dart';
import 'package:doctor_app_flutter/core/model/live_care/AlternativeServicesList.dart'; import 'package:doctor_app_flutter/core/model/live_care/AlternativeServicesList.dart';
@ -104,6 +103,8 @@ class LiveCarePatientServices extends BaseService {
Future isLogin({LiveCareUserLoginRequestModel isLoginRequestModel, int loginStatus}) async { Future isLogin({LiveCareUserLoginRequestModel isLoginRequestModel, int loginStatus}) async {
hasError = false; hasError = false;
await getDoctorProfile( );
isLoginRequestModel.doctorId = super.doctorProfile.doctorID;
await baseAppClient.post(LIVE_CARE_IS_LOGIN, onSuccess: (response, statusCode) async { await baseAppClient.post(LIVE_CARE_IS_LOGIN, onSuccess: (response, statusCode) async {
isLoginResponse = response; isLoginResponse = response;
}, onFailure: (String error, int statusCode) { }, onFailure: (String error, int statusCode) {

@ -48,7 +48,9 @@ class _EndCallScreenState extends State<EndCallScreen> {
final List<PatientProfileCardModel> cardsList = [ final List<PatientProfileCardModel> cardsList = [
PatientProfileCardModel(TranslationBase.of(context).resume, PatientProfileCardModel(TranslationBase.of(context).resume,
TranslationBase.of(context).theCall, '', 'patient/vital_signs.png', TranslationBase.of(context).theCall, '', 'patient/vital_signs.png',
isInPatient: isInpatient, onTap: () async { isInPatient: isInpatient,
color: Colors.green[800],
onTap: () async {
GifLoaderDialogUtils.showMyDialog(context); GifLoaderDialogUtils.showMyDialog(context);
await liveCareModel await liveCareModel
.startCall(isReCall: false, vCID: widget.patient.vcId) .startCall(isReCall: false, vCID: widget.patient.vcId)
@ -105,7 +107,9 @@ class _EndCallScreenState extends State<EndCallScreen> {
TranslationBase.of(context).consultation, TranslationBase.of(context).consultation,
'', '',
'patient/vital_signs.png', 'patient/vital_signs.png',
isInPatient: isInpatient, onTap: () { isInPatient: isInpatient,
color: Colors.red[800],
onTap: () {
Helpers.showConfirmationDialog(context, Helpers.showConfirmationDialog(context,
"${TranslationBase.of(context).areYouSureYouWantTo} ${TranslationBase.of(context).endLC} ${TranslationBase.of(context).consultation} ?", "${TranslationBase.of(context).areYouSureYouWantTo} ${TranslationBase.of(context).endLC} ${TranslationBase.of(context).consultation} ?",
() async { () async {
@ -230,6 +234,7 @@ class _EndCallScreenState extends State<EndCallScreen> {
isLoading: cardsList[index].isLoading, isLoading: cardsList[index].isLoading,
isDartIcon: cardsList[index].isDartIcon, isDartIcon: cardsList[index].isDartIcon,
dartIcon: cardsList[index].dartIcon, dartIcon: cardsList[index].dartIcon,
color: cardsList[index].color,
), ),
), ),
], ],

@ -13,6 +13,7 @@ class PatientProfileCardModel {
final bool isSelectInpatient; final bool isSelectInpatient;
final bool isDartIcon; final bool isDartIcon;
final IconData dartIcon; final IconData dartIcon;
final Color color;
PatientProfileCardModel( PatientProfileCardModel(
this.nameLine1, this.nameLine1,
@ -25,6 +26,8 @@ class PatientProfileCardModel {
this.onTap, this.onTap,
this.isDischargedPatient = false, this.isDischargedPatient = false,
this.isSelectInpatient = false, this.isSelectInpatient = false,
this.isDartIcon = false,this.dartIcon this.isDartIcon = false,
this.dartIcon,
this.color,
}); });
} }

@ -28,6 +28,7 @@ class PatientProfileButton extends StatelessWidget {
final bool isDartIcon; final bool isDartIcon;
final IconData dartIcon; final IconData dartIcon;
final bool isFromLiveCare; final bool isFromLiveCare;
final Color color;
PatientProfileButton({ PatientProfileButton({
Key key, Key key,
@ -47,7 +48,7 @@ class PatientProfileButton extends StatelessWidget {
this.isDischargedPatient = false, this.isDischargedPatient = false,
this.isSelectInpatient = false, this.isSelectInpatient = false,
this.isDartIcon = false, this.isDartIcon = false,
this.dartIcon, this.isFromLiveCare = false, this.dartIcon, this.isFromLiveCare = false, this.color,
}) : super(key: key); }) : super(key: key);
@override @override
@ -73,7 +74,7 @@ class PatientProfileButton extends StatelessWidget {
children: <Widget>[ children: <Widget>[
Container( Container(
child: isDartIcon ? Icon( child: isDartIcon ? Icon(
dartIcon, size: 30, color: Color(0xFF333C45),) : new Image dartIcon, size: 30, color: color?? Color(0xFF333C45),) : new Image
.asset( .asset(
url + icon, url + icon,
width: 30, width: 30,
@ -93,14 +94,14 @@ class PatientProfileButton extends StatelessWidget {
children: [ children: [
AppText( AppText(
!projectsProvider.isArabic ? this.nameLine1 : nameLine2, !projectsProvider.isArabic ? this.nameLine1 : nameLine2,
color: Color(0xFF2B353E), color: color??Color(0xFF2B353E),
fontWeight: FontWeight.w600, fontWeight: FontWeight.w600,
textAlign: TextAlign.left, textAlign: TextAlign.left,
fontSize: SizeConfig.textMultiplier * 1.5, fontSize: SizeConfig.textMultiplier * 1.5,
), ),
AppText( AppText(
!projectsProvider.isArabic ? this.nameLine2 : nameLine1, !projectsProvider.isArabic ? this.nameLine2 : nameLine1,
color: Color(0xFF2B353E), color: color??Color(0xFF2B353E),
fontWeight: FontWeight.w600, fontWeight: FontWeight.w600,
textAlign: TextAlign.left, textAlign: TextAlign.left,
fontSize: SizeConfig.textMultiplier * 1.5, fontSize: SizeConfig.textMultiplier * 1.5,
@ -116,7 +117,7 @@ class PatientProfileButton extends StatelessWidget {
color: isDisable ? Colors.grey.withOpacity(0.4) : Colors.white, color: isDisable ? Colors.grey.withOpacity(0.4) : Colors.white,
borderRadius: BorderRadius.all(Radius.circular(10)), borderRadius: BorderRadius.all(Radius.circular(10)),
border: Border.fromBorderSide(BorderSide( border: Border.fromBorderSide(BorderSide(
color: Color(0xffBBBBBB), color: color??Color(0xffBBBBBB),
width: 1, width: 1,
)), )),
), ),

Loading…
Cancel
Save