Use Mih Color Green

This commit is contained in:
2025-08-14 09:54:00 +02:00
parent 3b669bceac
commit 6ba3da6368
45 changed files with 178 additions and 252 deletions

View File

@@ -5,6 +5,7 @@ import 'package:mzansi_innovation_hub/mih_components/mih_objects/access_request.
import 'package:mzansi_innovation_hub/mih_components/mih_objects/app_user.dart';
import 'package:mzansi_innovation_hub/mih_components/mih_package_components/mih_button.dart';
import 'package:mzansi_innovation_hub/mih_components/mih_package_components/mih_package_window.dart';
import 'package:mzansi_innovation_hub/mih_config/mih_colors.dart';
import 'package:supertokens_flutter/http.dart' as http;
@@ -133,8 +134,7 @@ class _BuildPatientsListState extends State<BuildAccessRequestList> {
if (access == "APPROVED") {
accessWithColour = TextSpan(
text: "$access\n",
style: TextStyle(
color: MzansiInnovationHub.of(context)!.theme.successColor()));
style: TextStyle(color: MihColors.getGreenColor(context)));
} else if (access == "PENDING") {
accessWithColour = TextSpan(
text: "$access\n",
@@ -268,8 +268,7 @@ class _BuildPatientsListState extends State<BuildAccessRequestList> {
onPressed: () {
updateAccessAPICall(index, "approved");
},
buttonColor:
MzansiInnovationHub.of(context)!.theme.successColor(),
buttonColor: MihColors.getGreenColor(context),
width: 300,
child: Text(
"Approve",

View File

@@ -1,5 +1,6 @@
import 'package:flutter_speed_dial/flutter_speed_dial.dart';
import 'package:mzansi_innovation_hub/main.dart';
import 'package:mzansi_innovation_hub/mih_config/mih_colors.dart';
import 'package:mzansi_innovation_hub/mih_services/mih_alert_services.dart';
import 'package:mzansi_innovation_hub/mih_services/mih_mzansi_calendar_services.dart';
import 'package:mzansi_innovation_hub/mih_services/mih_validation_services.dart';
@@ -95,8 +96,7 @@ class _BuildAppointmentListState extends State<BuildAppointmentList> {
appointmentColor =
MzansiInnovationHub.of(context)!.theme.messageTextColor();
} else if (appointHour == hourNow) {
appointmentColor =
MzansiInnovationHub.of(context)!.theme.successColor();
appointmentColor = MihColors.getGreenColor(context);
}
} else if (DateTime.parse(appointDate).isBefore(DateTime.parse(date))) {
appointmentColor =
@@ -161,14 +161,12 @@ class _BuildAppointmentListState extends State<BuildAppointmentList> {
color: MzansiInnovationHub.of(context)!.theme.primaryColor(),
),
label: "Edit Appointment",
labelBackgroundColor:
MzansiInnovationHub.of(context)!.theme.successColor(),
labelBackgroundColor: MihColors.getGreenColor(context),
labelStyle: TextStyle(
color: MzansiInnovationHub.of(context)!.theme.primaryColor(),
fontWeight: FontWeight.bold,
),
backgroundColor:
MzansiInnovationHub.of(context)!.theme.successColor(),
backgroundColor: MihColors.getGreenColor(context),
onTap: () {
appointmentUpdateWindow(index, bodyWidth);
},
@@ -179,14 +177,12 @@ class _BuildAppointmentListState extends State<BuildAppointmentList> {
color: MzansiInnovationHub.of(context)!.theme.primaryColor(),
),
label: "Delete Appointment",
labelBackgroundColor:
MzansiInnovationHub.of(context)!.theme.successColor(),
labelBackgroundColor: MihColors.getGreenColor(context),
labelStyle: TextStyle(
color: MzansiInnovationHub.of(context)!.theme.primaryColor(),
fontWeight: FontWeight.bold,
),
backgroundColor:
MzansiInnovationHub.of(context)!.theme.successColor(),
backgroundColor: MihColors.getGreenColor(context),
onTap: () {
deleteAppointmentConfirmationWindow(index);
},
@@ -279,14 +275,12 @@ class _BuildAppointmentListState extends State<BuildAppointmentList> {
color: MzansiInnovationHub.of(context)!.theme.primaryColor(),
),
label: "Edit Appointment",
labelBackgroundColor:
MzansiInnovationHub.of(context)!.theme.successColor(),
labelBackgroundColor: MihColors.getGreenColor(context),
labelStyle: TextStyle(
color: MzansiInnovationHub.of(context)!.theme.primaryColor(),
fontWeight: FontWeight.bold,
),
backgroundColor:
MzansiInnovationHub.of(context)!.theme.successColor(),
backgroundColor: MihColors.getGreenColor(context),
onTap: () {
appointmentUpdateWindow(index, bodyWidth);
},
@@ -297,14 +291,12 @@ class _BuildAppointmentListState extends State<BuildAppointmentList> {
color: MzansiInnovationHub.of(context)!.theme.primaryColor(),
),
label: "Delete Appointment",
labelBackgroundColor:
MzansiInnovationHub.of(context)!.theme.successColor(),
labelBackgroundColor: MihColors.getGreenColor(context),
labelStyle: TextStyle(
color: MzansiInnovationHub.of(context)!.theme.primaryColor(),
fontWeight: FontWeight.bold,
),
backgroundColor:
MzansiInnovationHub.of(context)!.theme.successColor(),
backgroundColor: MihColors.getGreenColor(context),
onTap: () {
deleteAppointmentConfirmationWindow(index);
},

View File

@@ -1,5 +1,6 @@
import 'package:flutter_speed_dial/flutter_speed_dial.dart';
import 'package:mzansi_innovation_hub/mih_components/mih_package_components/mih_icons.dart';
import 'package:mzansi_innovation_hub/mih_config/mih_colors.dart';
import 'package:mzansi_innovation_hub/mih_services/mih_alert_services.dart';
import 'package:mzansi_innovation_hub/mih_services/mih_mzansi_calendar_services.dart';
import 'package:mzansi_innovation_hub/mih_services/mih_validation_services.dart';
@@ -403,14 +404,12 @@ class _PatientAccessRequestState extends State<Appointments> {
color: MzansiInnovationHub.of(context)!.theme.primaryColor(),
),
label: "Add Appointment",
labelBackgroundColor:
MzansiInnovationHub.of(context)!.theme.successColor(),
labelBackgroundColor: MihColors.getGreenColor(context),
labelStyle: TextStyle(
color: MzansiInnovationHub.of(context)!.theme.primaryColor(),
fontWeight: FontWeight.bold,
),
backgroundColor:
MzansiInnovationHub.of(context)!.theme.successColor(),
backgroundColor: MihColors.getGreenColor(context),
onTap: () {
addAppointmentWindow(width);
},