From 87b6e055da529dc2030c578750822aeda4c3e9c8 Mon Sep 17 00:00:00 2001 From: tahaalam Date: Wed, 13 May 2026 12:48:31 +0300 Subject: [PATCH] organs added for the medication input --- .../data/organ_mapping_data.dart | 420 +++++++++++++++++- 1 file changed, 405 insertions(+), 15 deletions(-) diff --git a/lib/features/symptoms_checker/data/organ_mapping_data.dart b/lib/features/symptoms_checker/data/organ_mapping_data.dart index d1a0b83b..d284aeb5 100644 --- a/lib/features/symptoms_checker/data/organ_mapping_data.dart +++ b/lib/features/symptoms_checker/data/organ_mapping_data.dart @@ -1,4 +1,3 @@ - import 'package:hmg_patient_app_new/core/enums.dart'; import 'package:hmg_patient_app_new/features/symptoms_checker/models/organ_model.dart'; @@ -37,12 +36,65 @@ class OrganData { id: 'nose_mouth', name: 'oral_cavity', nameAr: 'تجويف_الفم', - description: 'Nose/Mouth', - descriptionAr: 'الأنف/الفم', + description: 'Mouth', + descriptionAr: 'الفم', + bodyView: BodyView.front, + position: OrganPosition(x: 0.50, y: 0.135), + ), + + // ========== EARS (NEW) ========== + OrganModel( + id: 'left_ear', + name: 'ears', + nameAr: 'الأذن', + description: 'Left Ear', + descriptionAr: 'الأذن اليسرى', + bodyView: BodyView.front, + position: OrganPosition(x: 0.4, y: 0.1), + ), + OrganModel( + id: 'right_ear', + name: 'ears', + nameAr: 'الأذن', + description: 'Right Ear', + descriptionAr: 'الأذن اليمنى', + bodyView: BodyView.front, + position: OrganPosition(x: 0.64, y: 0.1), + ), + + // ========== NOSE (NEW) ========== + OrganModel( + id: 'nose', + name: 'nose', + nameAr: 'الأنف', + description: 'Nose', + descriptionAr: 'الأنف', bodyView: BodyView.front, - position: OrganPosition(x: 0.50, y: 0.09), + position: OrganPosition(x: 0.50, y: 0.095), ), + // ========== HEAD – SPECIFIC (NEW) ========== + // OrganModel( + // id: 'front_head', + // name: 'head', + // nameAr: 'الرأس', + // description: 'Front Head', + // descriptionAr: 'مقدمة الرأس', + // bodyView: BodyView.front, + // position: OrganPosition(x: 0.50, y: 0.04), + // ), + + // // ========== BEHAVIOR / THOUGHTS (NEW) ========== + // OrganModel( + // id: 'behavior_thoughts', + // name: 'problem_concerning_behavior_or_thoughts', + // nameAr: 'مشكلة_سلوكية_أو_نفسية', + // description: 'Behavior / Thoughts', + // descriptionAr: 'سلوك / أفكار', + // bodyView: BodyView.front, + // position: OrganPosition(x: 0.50, y: 0.02), + // ), + // ========== NECK ========== OrganModel( id: 'throat', @@ -51,7 +103,27 @@ class OrganData { description: 'Throat', descriptionAr: 'الحلق', bodyView: BodyView.front, - position: OrganPosition(x: 0.50, y: 0.15), + position: OrganPosition(x: 0.50, y: 0.17), + ), + + // ========== HALF NECK (NEW) ========== + OrganModel( + id: 'left_halfneck', + name: 'halfneck', + nameAr: 'نصف_الرقبة', + description: 'Left Half Neck', + descriptionAr: 'نصف الرقبة الأيسر', + bodyView: BodyView.front, + position: OrganPosition(x: 0.42, y: 0.15), + ), + OrganModel( + id: 'right_halfneck', + name: 'halfneck', + nameAr: 'نصف_الرقبة', + description: 'Right Half Neck', + descriptionAr: 'نصف الرقبة الأيمن', + bodyView: BodyView.front, + position: OrganPosition(x: 0.58, y: 0.15), ), // ========== SHOULDERS ========== @@ -74,6 +146,26 @@ class OrganData { position: OrganPosition(x: 0.8, y: 0.22), ), + // ========== UPPER LIMB (NEW) ========== + OrganModel( + id: 'left_upper_limb', + name: 'upper_limb', + nameAr: 'الطرف_العلوي', + description: 'Left Upper Limb', + descriptionAr: 'الطرف العلوي الأيسر', + bodyView: BodyView.front, + position: OrganPosition(x: 0.20, y: 0.30), + ), + OrganModel( + id: 'right_upper_limb', + name: 'upper_limb', + nameAr: 'الطرف_العلوي', + description: 'Right Upper Limb', + descriptionAr: 'الطرف العلوي الأيمن', + bodyView: BodyView.front, + position: OrganPosition(x: 0.80, y: 0.30), + ), + // ========== CHEST ========== OrganModel( id: 'left_chest', @@ -152,6 +244,28 @@ class OrganData { position: OrganPosition(x: 0.51, y: 0.44), ), + // ========== ABDOMEN – GENERAL (NEW) ========== + // OrganModel( + // id: 'abdomin', + // name: 'abdomin', + // nameAr: 'البطن_العام', + // description: 'Abdomen', + // descriptionAr: 'البطن', + // bodyView: BodyView.front, + // position: OrganPosition(x: 0.51, y: 0.36), + // ), + + // ========== SKIN (NEW) ========== + // OrganModel( + // id: 'skin', + // name: 'skin', + // nameAr: 'الجلد', + // description: 'Skin', + // descriptionAr: 'الجلد', + // bodyView: BodyView.front, + // position: OrganPosition(x: 0.50, y: 0.50), + // ), + // ========== PELVIS ========== OrganModel( id: 'left_groin', @@ -173,7 +287,6 @@ class OrganData { ), // ========== LEFT ARM ========== - OrganModel( id: 'left_elbow', name: 'elbow', @@ -203,7 +316,6 @@ class OrganData { ), // ========== RIGHT ARM ========== - OrganModel( id: 'right_elbow', name: 'elbow', @@ -307,7 +419,69 @@ class OrganData { bodyView: BodyView.front, position: OrganPosition(x: 0.57, y: 0.91), ), + + + // ========== UPPER LEG (NEW) ========== + OrganModel( + id: 'left_upperleg', + name: 'upperleg', + nameAr: 'الجزء_العلوي_من_الساق', + description: 'Left Upper Leg', + descriptionAr: 'الجزء العلوي من الساق الأيسر', + bodyView: BodyView.front, + position: OrganPosition(x: 0.40, y: 0.63), + ), + OrganModel( + id: 'right_upperleg', + name: 'upperleg', + nameAr: 'الجزء_العلوي_من_الساق', + description: 'Right Upper Leg', + descriptionAr: 'الجزء العلوي من الساق الأيمن', + bodyView: BodyView.front, + position: OrganPosition(x: 0.60, y: 0.63), + ), + + // ========== LOWER LEG – lowerleg key (NEW) ========== + OrganModel( + id: 'left_lowerleg', + name: 'lowerleg', + nameAr: 'الجزء_السفلي_من_الساق', + description: 'Left Lower Leg', + descriptionAr: 'الجزء السفلي من الساق الأيسر', + bodyView: BodyView.front, + position: OrganPosition(x: 0.41, y: 0.78), + ), + OrganModel( + id: 'right_lowerleg', + name: 'lowerleg', + nameAr: 'الجزء_السفلي_من_الساق', + description: 'Right Lower Leg', + descriptionAr: 'الجزء السفلي من الساق الأيمن', + bodyView: BodyView.front, + position: OrganPosition(x: 0.57, y: 0.78), + ), + + // ========== LOWER LIMB (NEW) ========== + OrganModel( + id: 'left_lower_limb', + name: 'lower_limb', + nameAr: 'الطرف_السفلي', + description: 'Left Lower Limb', + descriptionAr: 'الطرف السفلي الأيسر', + bodyView: BodyView.front, + position: OrganPosition(x: 0.40, y: 0.67), + ), + OrganModel( + id: 'right_lower_limb', + name: 'lower_limb', + nameAr: 'الطرف_السفلي', + description: 'Right Lower Limb', + descriptionAr: 'الطرف السفلي الأيمن', + bodyView: BodyView.front, + position: OrganPosition(x: 0.60, y: 0.67), + ), ]; + static const List frontViewOrgansForFemale = [ // ========== HEAD & FACE ========== OrganModel( @@ -341,12 +515,65 @@ class OrganData { id: 'nose_mouth', name: 'oral_cavity', nameAr: 'تجويف_الفم', - description: 'Nose/Mouth', + description: 'Mouth', descriptionAr: 'الأنف/الفم', bodyView: BodyView.front, - position: OrganPosition(x: 0.54, y: 0.12), + position: OrganPosition(x: 0.54, y: 0.14), ), + // ========== EARS (NEW) ========== + OrganModel( + id: 'left_ear', + name: 'ears', + nameAr: 'الأذن', + description: 'Left Ear', + descriptionAr: 'الأذن اليسرى', + bodyView: BodyView.front, + position: OrganPosition(x: 0.43, y: 0.12), + ), + OrganModel( + id: 'right_ear', + name: 'ears', + nameAr: 'الأذن', + description: 'Right Ear', + descriptionAr: 'الأذن اليمنى', + bodyView: BodyView.front, + position: OrganPosition(x: 0.656, y: 0.12), + ), + + // ========== NOSE (NEW) ========== + OrganModel( + id: 'nose', + name: 'nose', + nameAr: 'الأنف', + description: 'Nose', + descriptionAr: 'الأنف', + bodyView: BodyView.front, + position: OrganPosition(x: 0.54, y: 0.115), + ), + + // ========== HEAD – SPECIFIC (NEW) ========== + OrganModel( + id: 'front_head', + name: 'head', + nameAr: 'الرأس', + description: 'Front Head', + descriptionAr: 'مقدمة الرأس', + bodyView: BodyView.front, + position: OrganPosition(x: 0.54, y: 0.05), + ), + + // // ========== BEHAVIOR / THOUGHTS (NEW) ========== + // OrganModel( + // id: 'behavior_thoughts', + // name: 'problem_concerning_behavior_or_thoughts', + // nameAr: 'مشكلة_سلوكية_أو_نفسية', + // description: 'Behavior / Thoughts', + // descriptionAr: 'سلوك / أفكار', + // bodyView: BodyView.front, + // position: OrganPosition(x: 0.54, y: 0.02), + // ), + // ========== NECK ========== OrganModel( id: 'throat', @@ -358,6 +585,26 @@ class OrganData { position: OrganPosition(x: 0.54, y: 0.17), ), + // ========== HALF NECK (NEW) ========== + OrganModel( + id: 'left_halfneck', + name: 'halfneck', + nameAr: 'نصف_الرقبة', + description: 'Left Half Neck', + descriptionAr: 'نصف الرقبة الأيسر', + bodyView: BodyView.front, + position: OrganPosition(x: 0.48, y: 0.175), + ), + OrganModel( + id: 'right_halfneck', + name: 'halfneck', + nameAr: 'نصف_الرقبة', + description: 'Right Half Neck', + descriptionAr: 'نصف الرقبة الأيمن', + bodyView: BodyView.front, + position: OrganPosition(x: 0.60, y: 0.175), + ), + // ========== SHOULDERS ========== OrganModel( id: 'left_shoulder', @@ -378,6 +625,26 @@ class OrganData { position: OrganPosition(x: 0.75, y: 0.22), ), + // ========== UPPER LIMB (NEW) ========== + OrganModel( + id: 'left_upper_limb', + name: 'upper_limb', + nameAr: 'الطرف_العلوي', + description: 'Left Upper Limb', + descriptionAr: 'الطرف العلوي الأيسر', + bodyView: BodyView.front, + position: OrganPosition(x: 0.26, y: 0.30), + ), + OrganModel( + id: 'right_upper_limb', + name: 'upper_limb', + nameAr: 'الطرف_العلوي', + description: 'Right Upper Limb', + descriptionAr: 'الطرف العلوي الأيمن', + bodyView: BodyView.front, + position: OrganPosition(x: 0.76, y: 0.30), + ), + // ========== CHEST ========== OrganModel( id: 'left_chest', @@ -407,6 +674,26 @@ class OrganData { position: OrganPosition(x: 0.65, y: 0.22), ), + // ========== BREASTS (NEW – female only) ========== + OrganModel( + id: 'left_breast', + name: 'breasts', + nameAr: 'الثدي', + description: 'Left Breast', + descriptionAr: 'الثدي الأيسر', + bodyView: BodyView.front, + position: OrganPosition(x: 0.4, y: 0.27), + ), + OrganModel( + id: 'right_breast', + name: 'breasts', + nameAr: 'الثدي', + description: 'Right Breast', + descriptionAr: 'الثدي الأيمن', + bodyView: BodyView.front, + position: OrganPosition(x: 0.62, y: 0.27), + ), + // ========== RIBS ========== OrganModel( id: 'left_ribs', @@ -456,6 +743,28 @@ class OrganData { position: OrganPosition(x: 0.51, y: 0.44), ), + // ========== ABDOMEN – GENERAL (NEW) ========== + // OrganModel( + // id: 'abdomin', + // name: 'abdomin', + // nameAr: 'البطن_العام', + // description: 'Abdomen', + // descriptionAr: 'البطن', + // bodyView: BodyView.front, + // position: OrganPosition(x: 0.54, y: 0.36), + // ), + + // ========== SKIN (NEW) ========== + // OrganModel( + // id: 'skin', + // name: 'skin', + // nameAr: 'الجلد', + // description: 'Skin', + // descriptionAr: 'الجلد', + // bodyView: BodyView.front, + // position: OrganPosition(x: 0.54, y: 0.50), + // ), + // ========== PELVIS ========== OrganModel( id: 'left_groin', @@ -477,7 +786,6 @@ class OrganData { ), // ========== LEFT ARM ========== - OrganModel( id: 'left_elbow', name: 'elbow', @@ -507,7 +815,6 @@ class OrganData { ), // ========== RIGHT ARM ========== - OrganModel( id: 'right_elbow', name: 'elbow', @@ -611,6 +918,68 @@ class OrganData { bodyView: BodyView.front, position: OrganPosition(x: 0.57, y: 0.91), ), + + + + // ========== UPPER LEG (NEW) ========== + OrganModel( + id: 'left_upperleg', + name: 'upperleg', + nameAr: 'الجزء_العلوي_من_الساق', + description: 'Left Upper Leg', + descriptionAr: 'الجزء العلوي من الساق الأيسر', + bodyView: BodyView.front, + position: OrganPosition(x: 0.40, y: 0.63), + ), + OrganModel( + id: 'right_upperleg', + name: 'upperleg', + nameAr: 'الجزء_العلوي_من_الساق', + description: 'Right Upper Leg', + descriptionAr: 'الجزء العلوي من الساق الأيمن', + bodyView: BodyView.front, + position: OrganPosition(x: 0.65, y: 0.63), + ), + + // ========== LOWER LEG – lowerleg key (NEW) ========== + OrganModel( + id: 'left_lowerleg', + name: 'lowerleg', + nameAr: 'الجزء_السفلي_من_الساق', + description: 'Left Lower Leg', + descriptionAr: 'الجزء السفلي من الساق الأيسر', + bodyView: BodyView.front, + position: OrganPosition(x: 0.41, y: 0.78), + ), + OrganModel( + id: 'right_lowerleg', + name: 'lowerleg', + nameAr: 'الجزء_السفلي_من_الساق', + description: 'Right Lower Leg', + descriptionAr: 'الجزء السفلي من الساق الأيمن', + bodyView: BodyView.front, + position: OrganPosition(x: 0.59, y: 0.78), + ), + + // ========== LOWER LIMB (NEW) ========== + OrganModel( + id: 'left_lower_limb', + name: 'lower_limb', + nameAr: 'الطرف_السفلي', + description: 'Left Lower Limb', + descriptionAr: 'الطرف السفلي الأيسر', + bodyView: BodyView.front, + position: OrganPosition(x: 0.40, y: 0.67), + ), + OrganModel( + id: 'right_lower_limb', + name: 'lower_limb', + nameAr: 'الطرف_السفلي', + description: 'Right Lower Limb', + descriptionAr: 'الطرف السفلي الأيمن', + bodyView: BodyView.front, + position: OrganPosition(x: 0.65, y: 0.67), + ), ]; // ==================== BACK VIEW ==================== @@ -742,6 +1111,16 @@ class OrganData { position: OrganPosition(x: 0.60, y: 0.43), ), + // ========== ANUS (NEW) ========== + OrganModel( + id: 'anus', + name: 'anus', + nameAr: 'فتحة_الشرج', + description: 'Anus', + descriptionAr: 'فتحة الشرج', + bodyView: BodyView.back, + position: OrganPosition(x: 0.525, y: 0.5), + ), // ========== GLUTES ========== OrganModel( id: 'sacrum', @@ -750,7 +1129,7 @@ class OrganData { description: 'Sacrum', descriptionAr: 'العجز', bodyView: BodyView.back, - position: OrganPosition(x: 0.50, y: 0.52), + position: OrganPosition(x: 0.50, y: 0.46), ), OrganModel( id: 'left_glute', @@ -809,6 +1188,7 @@ class OrganData { position: OrganPosition(x: 0.57, y: 0.79), ), ]; + static const List backViewOrgansForFemale = [ // ========== HEAD & NECK ========== OrganModel( @@ -879,6 +1259,17 @@ class OrganData { position: OrganPosition(x: 0.62, y: 0.28), ), + // // ========== SKIN – BACK (NEW) ========== + // OrganModel( + // id: 'skin_back', + // name: 'skin', + // nameAr: 'الجلد', + // description: 'Skin', + // descriptionAr: 'الجلد', + // bodyView: BodyView.back, + // position: OrganPosition(x: 0.50, y: 0.30), + // ), + // ========== MID BACK ========== OrganModel( id: 'mid_spine', @@ -945,7 +1336,7 @@ class OrganData { description: 'Sacrum', descriptionAr: 'العجز', bodyView: BodyView.back, - position: OrganPosition(x: 0.50, y: 0.5), + position: OrganPosition(x: 0.50, y: 0.47), ), OrganModel( id: 'left_glute', @@ -1010,7 +1401,6 @@ class OrganData { static List getOrgansForView(BodyView view, {String? genderKey}) { final bool isFemale = genderKey != null && (genderKey.toLowerCase() == 'female' || genderKey == 'أنثى' || genderKey == '2'); - if (view == BodyView.front) { return isFemale ? frontViewOrgansForFemale : frontViewOrgansForMale; } else { @@ -1039,4 +1429,4 @@ class OrganData { return null; } } -} +} \ No newline at end of file