bug fixes

merge-requests/393/head
Sultan Khan 3 years ago
parent 2ebfdcfdd7
commit d535cb421d

@ -12,8 +12,8 @@ const PACKAGES_PRODUCTS = '/api/products';
const PACKAGES_CUSTOMER = '/api/customers'; const PACKAGES_CUSTOMER = '/api/customers';
const PACKAGES_SHOPPING_CART = '/api/shopping_cart_items'; const PACKAGES_SHOPPING_CART = '/api/shopping_cart_items';
const PACKAGES_ORDERS = '/api/orders'; const PACKAGES_ORDERS = '/api/orders';
// const BASE_URL = 'https://uat.hmgwebservices.com/'; const BASE_URL = 'https://uat.hmgwebservices.com/';
const BASE_URL = 'https://hmgwebservices.com/'; // const BASE_URL = 'https://hmgwebservices.com/';
// Pharmacy UAT URLs // Pharmacy UAT URLs
const BASE_PHARMACY_URL = 'https://uat.hmgwebservices.com/epharmacy/api/'; const BASE_PHARMACY_URL = 'https://uat.hmgwebservices.com/epharmacy/api/';

@ -19,8 +19,7 @@ class BloodSugarService extends BaseService {
hasError = false; hasError = false;
Map<String, dynamic> body = Map(); Map<String, dynamic> body = Map();
body['isDentalAllowedBackend'] = false; body['isDentalAllowedBackend'] = false;
await baseAppClient.post(GET_DIABETIC_RESULT_AVERAGE, await baseAppClient.post(GET_DIABETIC_RESULT_AVERAGE, onSuccess: (dynamic response, int statusCode) {
onSuccess: (dynamic response, int statusCode) {
monthDiabtectResultAverageList.clear(); monthDiabtectResultAverageList.clear();
weekDiabtectResultAverageList.clear(); weekDiabtectResultAverageList.clear();
yearDiabtecResultAverageList.clear(); yearDiabtecResultAverageList.clear();
@ -30,18 +29,15 @@ class BloodSugarService extends BaseService {
yearDiabtecPatientResult.clear(); yearDiabtecPatientResult.clear();
response['List_MonthDiabtectResultAverage'].forEach((item) { response['List_MonthDiabtectResultAverage'].forEach((item) {
monthDiabtectResultAverageList monthDiabtectResultAverageList.add(MonthDiabtectResultAverage.fromJson(item));
.add(MonthDiabtectResultAverage.fromJson(item));
}); });
response['List_WeekDiabtectResultAverage'].forEach((item) { response['List_WeekDiabtectResultAverage'].forEach((item) {
weekDiabtectResultAverageList weekDiabtectResultAverageList.add(WeekDiabtectResultAverage.fromJson(item));
.add(WeekDiabtectResultAverage.fromJson(item));
}); });
response['List_YearDiabtecResultAverage'].forEach((item) { response['List_YearDiabtecResultAverage'].forEach((item) {
yearDiabtecResultAverageList yearDiabtecResultAverageList.add(YearDiabtecResultAverage.fromJson(item));
.add(YearDiabtecResultAverage.fromJson(item));
}); });
}, onFailure: (String error, int statusCode) { }, onFailure: (String error, int statusCode) {
hasError = true; hasError = true;
@ -51,8 +47,7 @@ class BloodSugarService extends BaseService {
Future getDiabtecResults() async { Future getDiabtecResults() async {
hasError = false; hasError = false;
await baseAppClient.post(GET_DIABTEC_RESULT, await baseAppClient.post(GET_DIABTEC_RESULT, onSuccess: (dynamic response, int statusCode) {
onSuccess: (dynamic response, int statusCode) {
monthDiabtecPatientResult.clear(); monthDiabtecPatientResult.clear();
weekDiabtecPatientResult.clear(); weekDiabtecPatientResult.clear();
yearDiabtecPatientResult.clear(); yearDiabtecPatientResult.clear();
@ -69,7 +64,6 @@ class BloodSugarService extends BaseService {
yearDiabtecPatientResult.add(DiabtecPatientResult.fromJson(item)); yearDiabtecPatientResult.add(DiabtecPatientResult.fromJson(item));
}); });
}, onFailure: (String error, int statusCode) { }, onFailure: (String error, int statusCode) {
hasError = true;
super.error = error; super.error = error;
}, body: Map()); }, body: Map());
} }
@ -81,17 +75,15 @@ class BloodSugarService extends BaseService {
body['BloodSugerDateChart'] = bloodSugerDateChart; body['BloodSugerDateChart'] = bloodSugerDateChart;
body['BloodSugerResult'] = bloodSugerResult; body['BloodSugerResult'] = bloodSugerResult;
body['DiabtecUnit'] = diabtecUnit; body['DiabtecUnit'] = diabtecUnit;
body['MeasuredTime'] = measuredTime+1; body['MeasuredTime'] = measuredTime + 1;
body['isDentalAllowedBackend'] = false; body['isDentalAllowedBackend'] = false;
await baseAppClient.post(ADD_DIABTEC_RESULT, await baseAppClient.post(ADD_DIABTEC_RESULT, onSuccess: (response, statusCode) async {}, onFailure: (String error, int statusCode) {
onSuccess: (response, statusCode) async {},
onFailure: (String error, int statusCode) {
hasError = true; hasError = true;
super.error = error; super.error = error;
}, body: body); }, body: body);
} }
updateDiabtecResult({DateTime month,DateTime hour,String bloodSugerResult,String diabtecUnit, int measuredTime,int lineItemNo}) async { updateDiabtecResult({DateTime month, DateTime hour, String bloodSugerResult, String diabtecUnit, int measuredTime, int lineItemNo}) async {
hasError = false; hasError = false;
super.error = ""; super.error = "";
Map<String, dynamic> body = Map(); Map<String, dynamic> body = Map();
@ -99,11 +91,9 @@ class BloodSugarService extends BaseService {
body['DiabtecUnit'] = diabtecUnit; body['DiabtecUnit'] = diabtecUnit;
body['BloodSugerDateChart'] = '${month.year}-${month.month}-${month.day} ${hour.hour}:${hour.minute}:00'; body['BloodSugerDateChart'] = '${month.year}-${month.month}-${month.day} ${hour.hour}:${hour.minute}:00';
body['isDentalAllowedBackend'] = false; body['isDentalAllowedBackend'] = false;
body['MeasuredTime'] = measuredTime+1; body['MeasuredTime'] = measuredTime + 1;
body['LineItemNo'] = lineItemNo; body['LineItemNo'] = lineItemNo;
await baseAppClient.post(UPDATE_DIABETIC_RESULT, await baseAppClient.post(UPDATE_DIABETIC_RESULT, onSuccess: (response, statusCode) async {}, onFailure: (String error, int statusCode) {
onSuccess: (response, statusCode) async {},
onFailure: (String error, int statusCode) {
hasError = true; hasError = true;
super.error = error; super.error = error;
}, body: body); }, body: body);
@ -115,25 +105,21 @@ class BloodSugarService extends BaseService {
Map<String, dynamic> body = Map(); Map<String, dynamic> body = Map();
body['isDentalAllowedBackend'] = false; body['isDentalAllowedBackend'] = false;
body['To'] = user.emailAddress; body['To'] = user.emailAddress;
await baseAppClient.post(SEND_AVERAGE_BLOOD_SUGAR_REPORT, await baseAppClient.post(SEND_AVERAGE_BLOOD_SUGAR_REPORT, onSuccess: (response, statusCode) async {}, onFailure: (String error, int statusCode) {
onSuccess: (response, statusCode) async {}, hasError = true;
onFailure: (String error, int statusCode) { super.error = error;
hasError = true; }, body: body);
super.error = error;
}, body: body);
} }
Future deactivateDiabeticStatus({int lineItemNo }) async { Future deactivateDiabeticStatus({int lineItemNo}) async {
hasError = false; hasError = false;
super.error = ""; super.error = "";
Map<String, dynamic> body = Map(); Map<String, dynamic> body = Map();
body['isDentalAllowedBackend'] = false; body['isDentalAllowedBackend'] = false;
body['LineItemNo'] =lineItemNo; body['LineItemNo'] = lineItemNo;
await baseAppClient.post(DEACTIVATE_DIABETIC_STATUS, await baseAppClient.post(DEACTIVATE_DIABETIC_STATUS, onSuccess: (response, statusCode) async {}, onFailure: (String error, int statusCode) {
onSuccess: (response, statusCode) async {}, hasError = true;
onFailure: (String error, int statusCode) { super.error = error;
hasError = true; }, body: body);
super.error = error;
}, body: body);
} }
} }

@ -18,7 +18,7 @@ class PrescriptionsService extends BaseService {
List<Prescriptions> prescriptionsList = List(); List<Prescriptions> prescriptionsList = List();
List<PrescriptionReportINP> prescriptionReportListINP = List(); List<PrescriptionReportINP> prescriptionReportListINP = List();
List<PrescriptionsOrder> prescriptionsOrderList = List(); List<PrescriptionsOrder> prescriptionsOrderList = List();
var isMedDeliveryAllowed;
Future getPrescriptions() async { Future getPrescriptions() async {
hasError = false; hasError = false;
Map<String, dynamic> body = Map(); Map<String, dynamic> body = Map();
@ -48,8 +48,7 @@ class PrescriptionsService extends BaseService {
}, body: body); }, body: body);
} }
RequestPrescriptionReport _requestPrescriptionReport = RequestPrescriptionReport _requestPrescriptionReport = RequestPrescriptionReport(appointmentNo: 0, isDentalAllowedBackend: false);
RequestPrescriptionReport(appointmentNo: 0, isDentalAllowedBackend: false);
List<PrescriptionReport> prescriptionReportList = List(); List<PrescriptionReport> prescriptionReportList = List();
Future getPrescriptionReport({Prescriptions prescriptions}) async { Future getPrescriptionReport({Prescriptions prescriptions}) async {
@ -65,10 +64,10 @@ class PrescriptionsService extends BaseService {
_requestPrescriptionReport.episodeID = prescriptions.episodeID; _requestPrescriptionReport.episodeID = prescriptions.episodeID;
_requestPrescriptionReport.appointmentNo = prescriptions.appointmentNo; _requestPrescriptionReport.appointmentNo = prescriptions.appointmentNo;
await baseAppClient.post(prescriptions.isInOutPatient ? GET_PRESCRIPTION_REPORT_ENH : GET_PRESCRIPTION_REPORT, await baseAppClient.post(prescriptions.isInOutPatient ? GET_PRESCRIPTION_REPORT_ENH : GET_PRESCRIPTION_REPORT, onSuccess: (dynamic response, int statusCode) {
onSuccess: (dynamic response, int statusCode) {
prescriptionReportList.clear(); prescriptionReportList.clear();
prescriptionReportEnhList.clear(); prescriptionReportEnhList.clear();
isMedDeliveryAllowed = response['IsHomeMedicineDeliverySupported'];
if (prescriptions.isInOutPatient) { if (prescriptions.isInOutPatient) {
response['ListPRM'].forEach((prescriptions) { response['ListPRM'].forEach((prescriptions) {
prescriptionReportList.add(PrescriptionReport.fromJson(prescriptions)); prescriptionReportList.add(PrescriptionReport.fromJson(prescriptions));
@ -90,8 +89,7 @@ class PrescriptionsService extends BaseService {
isDentalAllowedBackend: false, isDentalAllowedBackend: false,
); );
Future sendPrescriptionEmail( Future sendPrescriptionEmail(String appointmentDate, int patientID, String clinicName, String doctorName, int doctorID, int projectID) async {
String appointmentDate, int patientID, String clinicName, String doctorName, int doctorID, int projectID) async {
_requestSendPrescriptionEmail.listPrescriptions = prescriptionReportList; _requestSendPrescriptionEmail.listPrescriptions = prescriptionReportList;
_requestSendPrescriptionEmail.appointmentDate = appointmentDate; _requestSendPrescriptionEmail.appointmentDate = appointmentDate;
_requestSendPrescriptionEmail.patientID = patientID; _requestSendPrescriptionEmail.patientID = patientID;
@ -107,15 +105,13 @@ class PrescriptionsService extends BaseService {
_requestSendPrescriptionEmail.setupID = user.setupID; _requestSendPrescriptionEmail.setupID = user.setupID;
_requestSendPrescriptionEmail.to = user.emailAddress; _requestSendPrescriptionEmail.to = user.emailAddress;
hasError = false; hasError = false;
await baseAppClient.post(SEND_PRESCRIPTION_EMAIL, onSuccess: (response, statusCode) {}, await baseAppClient.post(SEND_PRESCRIPTION_EMAIL, onSuccess: (response, statusCode) {}, onFailure: (String error, int statusCode) {
onFailure: (String error, int statusCode) {
hasError = true; hasError = true;
super.error = error; super.error = error;
}, body: _requestSendPrescriptionEmail.toJson()); }, body: _requestSendPrescriptionEmail.toJson());
} }
RequestGetListPharmacyForPrescriptions requestGetListPharmacyForPrescriptions = RequestGetListPharmacyForPrescriptions requestGetListPharmacyForPrescriptions = RequestGetListPharmacyForPrescriptions(
RequestGetListPharmacyForPrescriptions(
latitude: 0, latitude: 0,
longitude: 0, longitude: 0,
isDentalAllowedBackend: false, isDentalAllowedBackend: false,
@ -174,8 +170,7 @@ class PrescriptionsService extends BaseService {
hasError = false; hasError = false;
await baseAppClient.post(isInPatient ? GET_PRESCRIPTION_REPORT_ENH : GET_PRESCRIPTION_REPORT, await baseAppClient.post(isInPatient ? GET_PRESCRIPTION_REPORT_ENH : GET_PRESCRIPTION_REPORT, onSuccess: (dynamic response, int statusCode) {
onSuccess: (dynamic response, int statusCode) {
prescriptionReportEnhList.clear(); prescriptionReportEnhList.clear();
if (isInPatient) { if (isInPatient) {
@ -203,8 +198,7 @@ class PrescriptionsService extends BaseService {
body['RejectionReason'] = ''; body['RejectionReason'] = '';
body['PresOrderStatus'] = 4; body['PresOrderStatus'] = 4;
body['isDentalAllowedBackend'] = false; body['isDentalAllowedBackend'] = false;
await baseAppClient.post(UPDATE_PRESS_ORDER, onSuccess: (dynamic response, int statusCode) {}, await baseAppClient.post(UPDATE_PRESS_ORDER, onSuccess: (dynamic response, int statusCode) {}, onFailure: (String error, int statusCode) {
onFailure: (String error, int statusCode) {
hasError = true; hasError = true;
super.error = error; super.error = error;
}, body: body); }, body: body);

@ -29,9 +29,8 @@ class PrescriptionsViewModel extends BaseViewModel {
List<PharmacyPrescriptions> get pharmacyPrescriptionsList => _prescriptionsService.pharmacyPrescriptionsList; List<PharmacyPrescriptions> get pharmacyPrescriptionsList => _prescriptionsService.pharmacyPrescriptionsList;
List<PrescriptionsList> get prescriptionsOrderList => List<PrescriptionsList> get prescriptionsOrderList => filterType == FilterType.Clinic ? _prescriptionsOrderListClinic : _prescriptionsOrderListHospital;
filterType == FilterType.Clinic ? _prescriptionsOrderListClinic : _prescriptionsOrderListHospital; get isMedDeliveryAllowed => _prescriptionsService.isMedDeliveryAllowed;
getPrescriptions() async { getPrescriptions() async {
setState(ViewState.Busy); setState(ViewState.Busy);
await _prescriptionsService.getPrescriptions(); await _prescriptionsService.getPrescriptions();
@ -48,17 +47,12 @@ class PrescriptionsViewModel extends BaseViewModel {
void _filterList() { void _filterList() {
_prescriptionsService.prescriptionsList.forEach((element) { _prescriptionsService.prescriptionsList.forEach((element) {
/// PrescriptionsList list sort clinic /// PrescriptionsList list sort clinic
List<PrescriptionsList> prescriptionsByClinic = _prescriptionsOrderListClinic List<PrescriptionsList> prescriptionsByClinic = _prescriptionsOrderListClinic.where((elementClinic) => elementClinic.filterName == element.clinicDescription).toList();
.where((elementClinic) => elementClinic.filterName == element.clinicDescription)
.toList();
if (prescriptionsByClinic.length != 0) { if (prescriptionsByClinic.length != 0) {
_prescriptionsOrderListClinic[_prescriptionsOrderListClinic.indexOf(prescriptionsByClinic[0])] _prescriptionsOrderListClinic[_prescriptionsOrderListClinic.indexOf(prescriptionsByClinic[0])].prescriptionsList.add(element);
.prescriptionsList
.add(element);
} else { } else {
_prescriptionsOrderListClinic _prescriptionsOrderListClinic.add(PrescriptionsList(filterName: element.clinicDescription, prescriptions: element));
.add(PrescriptionsList(filterName: element.clinicDescription, prescriptions: element));
} }
/// PrescriptionsList list sort via hospital /// PrescriptionsList list sort via hospital
@ -69,9 +63,7 @@ class PrescriptionsViewModel extends BaseViewModel {
.toList(); .toList();
if (prescriptionsByHospital.length != 0) { if (prescriptionsByHospital.length != 0) {
_prescriptionsOrderListHospital[_prescriptionsOrderListHospital.indexOf(prescriptionsByHospital[0])] _prescriptionsOrderListHospital[_prescriptionsOrderListHospital.indexOf(prescriptionsByHospital[0])].prescriptionsList.add(element);
.prescriptionsList
.add(element);
} else { } else {
_prescriptionsOrderListHospital.add(PrescriptionsList(filterName: element.name, prescriptions: element)); _prescriptionsOrderListHospital.add(PrescriptionsList(filterName: element.name, prescriptions: element));
} }
@ -104,17 +96,9 @@ class PrescriptionsViewModel extends BaseViewModel {
} }
} }
sendPrescriptionEmail( sendPrescriptionEmail({String appointmentDate, int patientID, String clinicName, String doctorName, int doctorID, String mes, int projectID}) async {
{String appointmentDate,
int patientID,
String clinicName,
String doctorName,
int doctorID,
String mes,
int projectID}) async {
setState(ViewState.BusyLocal); setState(ViewState.BusyLocal);
await _prescriptionsService.sendPrescriptionEmail( await _prescriptionsService.sendPrescriptionEmail(appointmentDate, patientID, clinicName, doctorName, doctorID, projectID);
appointmentDate, patientID, clinicName, doctorName, doctorID, projectID);
if (_prescriptionsService.hasError) { if (_prescriptionsService.hasError) {
error = _prescriptionsService.error; error = _prescriptionsService.error;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);

@ -16,7 +16,7 @@ import 'package:diplomaticquarterapp/widgets/transitions/fade_page.dart';
import 'package:flutter/cupertino.dart'; import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:provider/provider.dart'; import 'package:provider/provider.dart';
import 'package:diplomaticquarterapp/widgets/buttons/secondary_button.dart';
import '../../../widgets/dialogs/confirm_send_email_dialog.dart'; import '../../../widgets/dialogs/confirm_send_email_dialog.dart';
import 'PrescriptionIDeliveryAddressPage.dart'; import 'PrescriptionIDeliveryAddressPage.dart';
@ -328,9 +328,10 @@ class PrescriptionItemsPage extends StatelessWidget {
padding: EdgeInsets.only(left: 16, right: 16, top: 16, bottom: 20), padding: EdgeInsets.only(left: 16, right: 16, top: 16, bottom: 20),
child: Container( child: Container(
width: MediaQuery.of(context).size.width * 0.8, width: MediaQuery.of(context).size.width * 0.8,
child: DefaultButton( child: SecondaryButton(
TranslationBase.of(context).resendOrder, label: TranslationBase.of(context).resendOrder,
() { disabled: (!projectViewModel.havePrivilege(62)) || projectViewModel.user.outSA == 1 || model.isMedDeliveryAllowed == false,
onTap: () {
Navigator.push( Navigator.push(
context, context,
FadePage( FadePage(

@ -47,6 +47,7 @@ class _AppDrawerState extends State<AppDrawer> {
@override @override
void initState() { void initState() {
super.initState(); super.initState();
checkUserData(); checkUserData();
} }
@ -173,17 +174,14 @@ class _AppDrawerState extends State<AppDrawer> {
children: <Widget>[ children: <Widget>[
(user.isFamily == null || user.isFamily == false) (user.isFamily == null || user.isFamily == false)
? InkWell( ? InkWell(
child: DrawerItem( child: DrawerItem(TranslationBase.of(context).family, SvgPicture.asset("assets/images/new/family_files.svg"),
TranslationBase.of(context).family, isImageIcon: true,
SvgPicture.asset("assets/images/new/family_files.svg"), bottomLine: false,
isImageIcon: true, textColor: Theme.of(context).textTheme.bodyText1.color,
bottomLine: false, iconColor: Theme.of(context).textTheme.bodyText1.color,
textColor: Theme.of(context).textTheme.bodyText1.color, sideArrow: true,
iconColor: Theme.of(context).textTheme.bodyText1.color, letterSpacing: -0.84,
sideArrow: true, projectProvider: projectProvider),
letterSpacing: -0.84,
projectProvider: projectProvider
),
onTap: () { onTap: () {
Navigator.of(context).pop(); Navigator.of(context).pop();
Navigator.of(context).pushNamed( Navigator.of(context).pushNamed(
@ -306,16 +304,9 @@ class _AppDrawerState extends State<AppDrawer> {
), ),
mHeight(20), mHeight(20),
InkWell( InkWell(
child: DrawerItem( child: DrawerItem(TranslationBase.of(context).arabicChange,
TranslationBase.of(context).arabicChange, Padding(child: Image.asset('assets/images/lang.png'), padding: EdgeInsets.only(left: 3, right: 3, top: 3, bottom: projectProvider.isArabic ? 3 : 0)),
Padding(child: Image.asset('assets/images/lang.png'), padding: EdgeInsets.only(left: 3, right: 3, top: 3, bottom: projectProvider.isArabic ? 3 : 0)), isImageIcon: true, bottomLine: false, letterSpacing: -0.84, fontSize: 14, fontHeight: projectProvider.isArabic ? 1 : 0.8, projectProvider: projectProvider),
isImageIcon: true,
bottomLine: false,
letterSpacing: -0.84,
fontSize: 14,
fontHeight: projectProvider.isArabic ? 1 : 0.8,
projectProvider: projectProvider
),
onTap: () { onTap: () {
sharedPref.remove(APPOINTMENT_HISTORY_MEDICAL); sharedPref.remove(APPOINTMENT_HISTORY_MEDICAL);
sharedPref.setBool(IS_ROBOT_INIT, null); sharedPref.setBool(IS_ROBOT_INIT, null);
@ -371,15 +362,8 @@ class _AppDrawerState extends State<AppDrawer> {
), ),
if (projectProvider.havePrivilege(3)) if (projectProvider.havePrivilege(3))
InkWell( InkWell(
child: DrawerItem( child: DrawerItem(TranslationBase.of(context).appsetting, SvgPicture.asset("assets/images/new/app_setting.svg"),
TranslationBase.of(context).appsetting, isImageIcon: true, bottomLine: false, letterSpacing: -0.84, fontSize: 14, projectProvider: projectProvider),
SvgPicture.asset("assets/images/new/app_setting.svg"),
isImageIcon: true,
bottomLine: false,
letterSpacing: -0.84,
fontSize: 14,
projectProvider: projectProvider
),
onTap: () { onTap: () {
Navigator.of(context).pushNamed( Navigator.of(context).pushNamed(
SETTINGS, SETTINGS,
@ -387,14 +371,7 @@ class _AppDrawerState extends State<AppDrawer> {
}, },
), ),
InkWell( InkWell(
child: DrawerItem( child: DrawerItem(TranslationBase.of(context).rateApp, Icons.star, bottomLine: false, letterSpacing: -0.84, fontSize: 14, projectProvider: projectProvider),
TranslationBase.of(context).rateApp,
Icons.star,
bottomLine: false,
letterSpacing: -0.84,
fontSize: 14,
projectProvider: projectProvider
),
onTap: () { onTap: () {
if (Platform.isIOS) { if (Platform.isIOS) {
launch("https://apps.apple.com/sa/app/dr-suliaman-alhabib/id733503978"); launch("https://apps.apple.com/sa/app/dr-suliaman-alhabib/id733503978");
@ -404,15 +381,8 @@ class _AppDrawerState extends State<AppDrawer> {
}, },
), ),
InkWell( InkWell(
child: DrawerItem( child: DrawerItem(TranslationBase.of(context).logout, SvgPicture.asset("assets/images/new/logout.svg"),
TranslationBase.of(context).logout, isImageIcon: true, bottomLine: false, letterSpacing: -0.84, fontSize: 14, projectProvider: projectProvider),
SvgPicture.asset("assets/images/new/logout.svg"),
isImageIcon: true,
bottomLine: false,
letterSpacing: -0.84,
fontSize: 14,
projectProvider: projectProvider
),
onTap: () { onTap: () {
logout(); logout();
}, },
@ -420,15 +390,8 @@ class _AppDrawerState extends State<AppDrawer> {
], ],
) )
: InkWell( : InkWell(
child: DrawerItem( child: DrawerItem(TranslationBase.of(context).loginregister, SvgPicture.asset("assets/images/new/logout.svg"),
TranslationBase.of(context).loginregister, isImageIcon: true, letterSpacing: -0.84, fontSize: 14, bottomLine: false, projectProvider: projectProvider),
SvgPicture.asset("assets/images/new/logout.svg"),
isImageIcon: true,
letterSpacing: -0.84,
fontSize: 14,
bottomLine: false,
projectProvider: projectProvider
),
onTap: () { onTap: () {
login(); login();
}, },
@ -499,6 +462,7 @@ class _AppDrawerState extends State<AppDrawer> {
this.mainUser = data2; this.mainUser = data2;
}); });
} }
notificationCount = await sharedPref.getString(NOTIFICATION_COUNT);
} }
logout() async { logout() async {

Loading…
Cancel
Save