Merge branch 'master' into haroon_dev

# Conflicts:
#	lib/presentation/medical_file/medical_file_page.dart
#	lib/presentation/my_family/widget/family_cards.dart
pull/91/head
haroon amjad 4 weeks ago
commit d3a8d545b2

@ -637,7 +637,7 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CLANG_ENABLE_MODULES = YES;
CODE_SIGN_ENTITLEMENTS = Runner/RunnerDebug.entitlements;
CODE_SIGN_ENTITLEMENTS = Runner/Runner.entitlements;
CURRENT_PROJECT_VERSION = 2;
DEVELOPMENT_TEAM = 3A359E86ZF;
ENABLE_BITCODE = NO;

@ -174,7 +174,7 @@ class ApiClientImp implements ApiClient {
}
// body['TokenID'] = "@dm!n";
// body['PatientID'] = 3966014;
// body['PatientID'] = 3111528;
// body['PatientTypeID'] = 1;
//
// body['PatientOutSA'] = 0;

@ -294,14 +294,13 @@ class _AppointmentDetailsPageState extends State<AppointmentDetailsPage> {
color: Colors.white,
borderRadius: 20.r,
),
child: Padding(
padding: EdgeInsets.all(16.w),
child: Column(
children: [
ListView.separated(
itemCount: prescriptionVM.prescriptionDetailsList.length,
shrinkWrap: true,
padding: const EdgeInsets.only(left: 0, right: 8),
padding: EdgeInsets.only(right: 8.w),
physics: NeverScrollableScrollPhysics(),
itemBuilder: (context, index) {
return AnimationConfiguration.staggeredList(
@ -323,20 +322,14 @@ class _AppointmentDetailsPageState extends State<AppointmentDetailsPage> {
children: [
Column(
children: [
SizedBox(
width: 150.w,
child: prescriptionVM.prescriptionDetailsList[index].itemDescription!
.toText12(isBold: true, maxLine: 1)),
SizedBox(
width: 150.h,
child:
prescriptionVM.prescriptionDetailsList[index].itemDescription!
.toText12(isBold: true, maxLine: 1),
"Prescribed By: ${widget.patientAppointmentHistoryResponseModel.doctorTitle} ${widget.patientAppointmentHistoryResponseModel.doctorNameObj}"
.needTranslation
.toText10(
weight: FontWeight.w500,
color: AppColors.greyTextColor,
letterSpacing: -0.4),
),
],
),
SizedBox(width: 68.w),
@ -370,7 +363,8 @@ class _AppointmentDetailsPageState extends State<AppointmentDetailsPage> {
SizedBox(height: 16.h),
const Divider(color: AppColors.dividerColor),
SizedBox(height: 16.h),
Row(
Wrap(
runSpacing: 6.w,
children: [
// Expanded(
// child: CustomButton(
@ -449,7 +443,6 @@ class _AppointmentDetailsPageState extends State<AppointmentDetailsPage> {
),
],
),
),
);
}),
],

@ -70,7 +70,6 @@ class AppointmentCard extends StatelessWidget {
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Expanded(child: _buildChips(context, appState)),
// Placeholder for future toggle / switch
],
);
}
@ -81,7 +80,7 @@ class AppointmentCard extends StatelessWidget {
return Wrap(
alignment: WrapAlignment.start,
direction: Axis.horizontal,
spacing: 6.h,
spacing: 6.w,
runSpacing: 6.h,
children: [
AppCustomChipWidget(

@ -35,7 +35,6 @@ class _LandingNavigationState extends State<LandingNavigation> {
],
),
bottomNavigationBar: BottomNavigation(
context: context,
currentIndex: _currentIndex,
onTap: (index) {
setState(() => _currentIndex = index);

@ -343,7 +343,7 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
Consumer<MyAppointmentsViewModel>(builder: (context, myAppointmentsVM, child) {
// Provide an explicit height so the horizontal ListView has a bounded height
return SizedBox(
height: 180.h,
height: 190.h,
child: myAppointmentsVM.isMyAppointmentsLoading
? MedicalFileAppointmentCard(
patientAppointmentHistoryResponseModel: PatientAppointmentHistoryResponseModel(),

@ -54,7 +54,10 @@ class _FamilyCardsState extends State<FamilyCards> {
children: [
Utils.buildSvgWithAssets(icon: AppAssets.alertSquare),
SizedBox(width: 8.h),
"Who can view my medical file ?".needTranslation.toText14(color: AppColors.textColor, isUnderLine: true, weight: FontWeight.w500).onPress(() {
"Who can view my medical file ?"
.needTranslation
.toText14(color: AppColors.textColor, isUnderLine: true, weight: FontWeight.w500)
.onPress(() {
dialogService.showFamilyBottomSheetWithoutHWithChild(
label: "Manage Family".needTranslation,
message: "",
@ -110,10 +113,17 @@ class _FamilyCardsState extends State<FamilyCards> {
? AppColors.textGreenColor
: AppColors.alertColor),
SizedBox(height: 8.h),
Wrap(alignment: WrapAlignment.start, crossAxisAlignment: WrapCrossAlignment.start, runAlignment: WrapAlignment.start, spacing: 0.h, children: [
Wrap(
alignment: WrapAlignment.start,
crossAxisAlignment: WrapCrossAlignment.start,
runAlignment: WrapAlignment.start,
spacing: 0.h,
children: [
(profile.patientName ?? "").toText14(isBold: false, isCenter: false, maxlines: 1, weight: FontWeight.w600),
(getStatusTextByRequest(FamilyFileEnum.values.firstWhere((e) => e.toInt == profile.status), profile.isRequestFromMySide ?? false))
.toText12(isBold: false, isCenter: false, maxLine: 1, fontWeight: FontWeight.w500, color: AppColors.greyTextColor),
(getStatusTextByRequest(
FamilyFileEnum.values.firstWhere((e) => e.toInt == profile.status), profile.isRequestFromMySide ?? false))
.toText12(
isBold: false, isCenter: false, maxLine: 1, fontWeight: FontWeight.w500, color: AppColors.greyTextColor),
]),
SizedBox(height: 8.h),
CustomChipWidget(
@ -141,7 +151,7 @@ class _FamilyCardsState extends State<FamilyCards> {
itemCount: widget.profiles.length,
gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
crossAxisCount: 2,
crossAxisSpacing: 10.h,
crossAxisSpacing: 10.w,
mainAxisSpacing: 10.h,
childAspectRatio: widget.isShowDetails ? 0.56.h : 0.65.h,
),
@ -168,7 +178,8 @@ class _FamilyCardsState extends State<FamilyCards> {
? ((profile.age ?? 0) < 7 ? AppAssets.babyBoyImg : AppAssets.male_img)
: (profile.age! < 7 ? AppAssets.babyGirlImg : AppAssets.femaleImg),
width: 72.h,
height: 70.h),
height: 70.h,
),
SizedBox(height: 8.h),
(profile.patientName ?? "Unknown").toText14(isBold: false, isCenter: true, maxlines: 1, weight: FontWeight.w600),
SizedBox(height: 8.h),
@ -282,7 +293,9 @@ class _FamilyCardsState extends State<FamilyCards> {
alignment: WrapAlignment.start,
children: [
(profile.patientName ?? "").toText14(isBold: false, isCenter: true, maxlines: 1, weight: FontWeight.w600),
(getStatusTextByRequest(FamilyFileEnum.values.firstWhere((e) => e.toInt == profile.status), profile.isRequestFromMySide ?? false)).toText14(
(getStatusTextByRequest(
FamilyFileEnum.values.firstWhere((e) => e.toInt == profile.status), profile.isRequestFromMySide ?? false))
.toText14(
isBold: false,
isCenter: true,
maxlines: 1,

@ -12,9 +12,8 @@ import 'package:hmg_patient_app_new/theme/colors.dart';
class BottomNavigation extends StatelessWidget {
final int currentIndex;
final ValueChanged<int> onTap;
BuildContext? context;
BottomNavigation({super.key, required this.currentIndex, required this.onTap, this.context});
const BottomNavigation({super.key, required this.currentIndex, required this.onTap});
@override
Widget build(BuildContext context) {
@ -30,7 +29,9 @@ class BottomNavigation extends StatelessWidget {
iconSize: 27,
isSpecial: true,
),
appState.isAuthenticated ? BottomNavItem(icon: AppAssets.toDoBottom, label: LocaleKeys.todoList.tr(context: context)) : BottomNavItem(icon: AppAssets.news, label: LocaleKeys.news.tr()),
appState.isAuthenticated
? BottomNavItem(icon: AppAssets.toDoBottom, label: LocaleKeys.todoList.tr(context: context))
: BottomNavItem(icon: AppAssets.news, label: LocaleKeys.news.tr()),
BottomNavItem(icon: AppAssets.servicesBottom, label: LocaleKeys.services2.tr(context: context)),
];
@ -65,11 +66,7 @@ class BottomNavigation extends StatelessWidget {
),
),
const SizedBox(height: 10),
item.label.toText12(
fontWeight: FontWeight.w500,
// color: Colors.black87,
// textAlign: TextAlign.center,
),
item.label.toText12(fontWeight: FontWeight.w500),
SizedBox(height: item.isSpecial ? 5 : 0)
],
),
@ -82,12 +79,14 @@ class BottomNavItem {
final String label;
final double iconSize;
final bool isSpecial;
final Color? color;
const BottomNavItem({
required this.icon,
required this.label,
this.iconSize = 21,
this.isSpecial = false,
this.color,
});
}

@ -63,13 +63,22 @@ class AppCustomChipWidget extends StatelessWidget {
child: icon.isNotEmpty
? Chip(
avatar: icon.isNotEmpty
? Utils.buildSvgWithAssets(
icon: icon, width: iconS, height: iconS, iconColor: iconHasColor ? iconColor : null, fit: BoxFit.contain)
? Padding(
padding: EdgeInsets.only(left: 8.w, right: 6.w),
child: Utils.buildSvgWithAssets(
icon: icon,
width: iconS,
height: iconS,
iconColor: iconHasColor ? iconColor : null,
fit: BoxFit.contain,
),
)
: SizedBox.shrink(),
avatarBoxConstraints: BoxConstraints(),
label: richText ?? labelText!.toText10(weight: FontWeight.w500, letterSpacing: 0, color: textColor),
padding: padding,
padding: EdgeInsets.zero,
materialTapTargetSize: MaterialTapTargetSize.shrinkWrap,
labelPadding: labelPadding ?? EdgeInsetsDirectional.only(start: 2.w, end: deleteIcon?.isNotEmpty == true ? 2.w : 8.w),
labelPadding: EdgeInsetsDirectional.only(end: 8.w),
backgroundColor: backgroundColor,
shape: shape ??
SmoothRectangleBorder(
@ -98,7 +107,7 @@ class AppCustomChipWidget extends StatelessWidget {
smoothness: 10,
side: BorderSide(color: AppColors.transparent, width: 1.5),
),
labelPadding: labelPadding ?? EdgeInsetsDirectional.only(start: 2.w, end: deleteIcon?.isNotEmpty == true ? 2.w : 8.w),
labelPadding: EdgeInsetsDirectional.only(start: 8.w, end: 8.w),
deleteIcon: deleteIcon?.isNotEmpty == true
? Utils.buildSvgWithAssets(icon: deleteIcon!, width: iconS, height: iconS, iconColor: deleteIconHasColor ? deleteIconColor : null)
: null,

Loading…
Cancel
Save