diff --git a/Justice.csproj b/Justice.csproj
index 5c4cf93..113dae0 100644
--- a/Justice.csproj
+++ b/Justice.csproj
@@ -81,9 +81,15 @@
MSBuild:Compile
+
+ MSBuild:Compile
+
MSBuild:Compile
+
+ MSBuild:Compile
+
MSBuild:Compile
diff --git a/Justice.csproj.user b/Justice.csproj.user
index 94c866c..c1f09fa 100644
--- a/Justice.csproj.user
+++ b/Justice.csproj.user
@@ -20,9 +20,15 @@
Designer
+
+ Designer
+
Designer
+
+ Designer
+
Designer
diff --git a/Models/Helpline.cs b/Models/Helpline.cs
new file mode 100644
index 0000000..16cf8a1
--- /dev/null
+++ b/Models/Helpline.cs
@@ -0,0 +1,15 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace Justice.Models
+{
+ public class Helpline
+ {
+ public string NumberType { get; set; }
+ public string AuthorityType { get; set; }
+ public string Number { get; set; }
+ }
+}
diff --git a/Services/HelplineService.cs b/Services/HelplineService.cs
new file mode 100644
index 0000000..05bd1ce
--- /dev/null
+++ b/Services/HelplineService.cs
@@ -0,0 +1,36 @@
+using Justice.Models;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace Justice.Services
+{
+ public class HelplineService
+ {
+ public static List GetHelplines()
+ {
+ return new List
+ {
+ new Helpline { NumberType = "General Emergency", AuthorityType = "Police", Number = "100" },
+ new Helpline { NumberType = "General Emergency", AuthorityType = "Fire Brigade", Number = "101" },
+ new Helpline { NumberType = "General Emergency", AuthorityType = "Ambulance", Number = "102" },
+ new Helpline { NumberType = "General Emergency", AuthorityType = "Traffic Control", Number = "103" },
+ new Helpline { NumberType = "General Emergency", AuthorityType = "Child Missing Emergency", Number = "104" },
+ new Helpline { NumberType = "Army And Security", AuthorityType = "Comission for Investigation of Abuse of Authority", Number = "107" },
+ new Helpline { NumberType = "Army And Security", AuthorityType = "Armed Police Force", Number = "1114" },
+ new Helpline { NumberType = "Army And Security", AuthorityType = "Nepal Army Headquarter", Number = "1113" },
+ new Helpline { NumberType = "Health and Child", AuthorityType = "Child Rights", Number = "1098" },
+ new Helpline { NumberType = "Health and Child", AuthorityType = "Health Emergency", Number= "1115" },
+ new Helpline { NumberType = "Health and Child", AuthorityType = "National Women Commission", Number = "1145" },
+ new Helpline { NumberType = "Health and Child", AuthorityType = "Human Trafficking Bureau", Number = "1177" },
+ new Helpline { NumberType = "Public Service", AuthorityType = "Nepal Electricity Authority", Number = "1150" },
+ new Helpline { NumberType = "Public Service", AuthorityType = "Nepal Red Cross Service", Number = "1130" },
+ new Helpline { NumberType = "Disaster and Tourism", AuthorityType = "Natural Disaster", Number= "1149" },
+ new Helpline { NumberType = "Disaster and Tourism", AuthorityType = "Tourist Police", Number = "1144" },
+ new Helpline { NumberType = "General Inquiries", AuthorityType = "Telephone Enquiry", Number = "197" },
+ };
+ }
+ }
+}
diff --git a/Views/DashboardPage.xaml b/Views/DashboardPage.xaml
index 25cbfc9..92adae4 100644
--- a/Views/DashboardPage.xaml
+++ b/Views/DashboardPage.xaml
@@ -65,7 +65,7 @@
-
+
@@ -84,7 +84,7 @@
-
+
@@ -118,7 +118,7 @@
-
+
diff --git a/Views/DashboardPage.xaml.cs b/Views/DashboardPage.xaml.cs
index 153c178..7d62a96 100644
--- a/Views/DashboardPage.xaml.cs
+++ b/Views/DashboardPage.xaml.cs
@@ -11,15 +11,16 @@ public partial class DashboardPage : ContentPage
InitializeComponent();
}
-
- private void OnInformationCenterClicked(object sender, EventArgs e)
- {
- DisplayAlert("Information button clicked","Information","OK");
- }
+
+ private async void OnInformationCenterClicked(object sender, EventArgs e)
+ {
+ await Navigation.PushAsync(new InformationCenterPage());
+ }
+
private void OnHelpLineNumberClicked(object sender, EventArgs e)
{
- DisplayAlert("Helpline Clicked button clicked", "HepLine Numbers", "OK");
+ Navigation.PushAsync(new HelplinePage());
}
private void OnViewReportClicked(object sender, EventArgs e)
{
diff --git a/Views/HelplinePage.xaml b/Views/HelplinePage.xaml
new file mode 100644
index 0000000..88920e8
--- /dev/null
+++ b/Views/HelplinePage.xaml
@@ -0,0 +1,48 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Views/HelplinePage.xaml.cs b/Views/HelplinePage.xaml.cs
new file mode 100644
index 0000000..b2e1cc6
--- /dev/null
+++ b/Views/HelplinePage.xaml.cs
@@ -0,0 +1,39 @@
+using Justice.Models;
+using Justice.Services;
+using Microsoft.Maui.ApplicationModel.Communication;
+using System;
+using System.Collections.ObjectModel;
+
+namespace Justice.Views
+{
+ public partial class HelplinePage : ContentPage
+ {
+ public ObservableCollection Helplines { get; set; }
+
+ public HelplinePage()
+ {
+ InitializeComponent();
+ Helplines = new ObservableCollection(HelplineService.GetHelplines());
+ HelplineListView.ItemsSource = Helplines;
+ }
+
+ private async void OnCallButtonClicked(object sender, EventArgs e)
+ {
+ if (sender is Button button && button.CommandParameter is string phoneNumber)
+ {
+ bool confirm = await DisplayAlert("Call Helpline", $"Do you want to call {phoneNumber}?", "Yes", "No");
+ if (confirm)
+ {
+ try
+ {
+ PhoneDialer.Open(phoneNumber);
+ }
+ catch (Exception ex)
+ {
+ await DisplayAlert("Error", $"Unable to make the call: {ex.Message}", "OK");
+ }
+ }
+ }
+ }
+ }
+}
diff --git a/Views/InformationCenterPage.xaml b/Views/InformationCenterPage.xaml
new file mode 100644
index 0000000..0c43f2e
--- /dev/null
+++ b/Views/InformationCenterPage.xaml
@@ -0,0 +1,53 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/Views/InformationCenterPage.xaml.cs b/Views/InformationCenterPage.xaml.cs
new file mode 100644
index 0000000..5e388a1
--- /dev/null
+++ b/Views/InformationCenterPage.xaml.cs
@@ -0,0 +1,9 @@
+namespace Justice.Views;
+
+public partial class InformationCenterPage : ContentPage
+{
+ public InformationCenterPage()
+ {
+ InitializeComponent();
+ }
+}
\ No newline at end of file
diff --git a/bin/Debug/net9.0-android/Justice.dll b/bin/Debug/net9.0-android/Justice.dll
index 427141d..c8f90d2 100644
Binary files a/bin/Debug/net9.0-android/Justice.dll and b/bin/Debug/net9.0-android/Justice.dll differ
diff --git a/bin/Debug/net9.0-android/Justice.pdb b/bin/Debug/net9.0-android/Justice.pdb
index cb930a0..19bdf0a 100644
Binary files a/bin/Debug/net9.0-android/Justice.pdb and b/bin/Debug/net9.0-android/Justice.pdb differ
diff --git a/bin/Debug/net9.0-android/com.companyname.justice-Signed.apk b/bin/Debug/net9.0-android/com.companyname.justice-Signed.apk
index 88bcc1c..65177e9 100644
Binary files a/bin/Debug/net9.0-android/com.companyname.justice-Signed.apk and b/bin/Debug/net9.0-android/com.companyname.justice-Signed.apk differ
diff --git a/bin/Debug/net9.0-android/com.companyname.justice-Signed.apk.idsig b/bin/Debug/net9.0-android/com.companyname.justice-Signed.apk.idsig
index abbc759..5befecb 100644
Binary files a/bin/Debug/net9.0-android/com.companyname.justice-Signed.apk.idsig and b/bin/Debug/net9.0-android/com.companyname.justice-Signed.apk.idsig differ
diff --git a/bin/Debug/net9.0-android/com.companyname.justice.apk b/bin/Debug/net9.0-android/com.companyname.justice.apk
index c04d6a7..fc82c0a 100644
Binary files a/bin/Debug/net9.0-android/com.companyname.justice.apk and b/bin/Debug/net9.0-android/com.companyname.justice.apk differ
diff --git a/bin/Debug/net9.0-ios/iossimulator-x64/Justice.dll b/bin/Debug/net9.0-ios/iossimulator-x64/Justice.dll
index ccfeeb2..090bc4d 100644
Binary files a/bin/Debug/net9.0-ios/iossimulator-x64/Justice.dll and b/bin/Debug/net9.0-ios/iossimulator-x64/Justice.dll differ
diff --git a/bin/Debug/net9.0-ios/iossimulator-x64/Justice.pdb b/bin/Debug/net9.0-ios/iossimulator-x64/Justice.pdb
index 477e778..ec084fc 100644
Binary files a/bin/Debug/net9.0-ios/iossimulator-x64/Justice.pdb and b/bin/Debug/net9.0-ios/iossimulator-x64/Justice.pdb differ
diff --git a/bin/Debug/net9.0-maccatalyst/maccatalyst-x64/Justice.dll b/bin/Debug/net9.0-maccatalyst/maccatalyst-x64/Justice.dll
index 1e9ce3a..5584efe 100644
Binary files a/bin/Debug/net9.0-maccatalyst/maccatalyst-x64/Justice.dll and b/bin/Debug/net9.0-maccatalyst/maccatalyst-x64/Justice.dll differ
diff --git a/bin/Debug/net9.0-maccatalyst/maccatalyst-x64/Justice.pdb b/bin/Debug/net9.0-maccatalyst/maccatalyst-x64/Justice.pdb
index ad03f72..2be5e0c 100644
Binary files a/bin/Debug/net9.0-maccatalyst/maccatalyst-x64/Justice.pdb and b/bin/Debug/net9.0-maccatalyst/maccatalyst-x64/Justice.pdb differ
diff --git a/bin/Debug/net9.0-windows10.0.19041.0/win10-x64/Justice.dll b/bin/Debug/net9.0-windows10.0.19041.0/win10-x64/Justice.dll
index 8ee2137..16841f1 100644
Binary files a/bin/Debug/net9.0-windows10.0.19041.0/win10-x64/Justice.dll and b/bin/Debug/net9.0-windows10.0.19041.0/win10-x64/Justice.dll differ
diff --git a/bin/Debug/net9.0-windows10.0.19041.0/win10-x64/Justice.exe b/bin/Debug/net9.0-windows10.0.19041.0/win10-x64/Justice.exe
index 0b8aeb3..ed8ee14 100644
Binary files a/bin/Debug/net9.0-windows10.0.19041.0/win10-x64/Justice.exe and b/bin/Debug/net9.0-windows10.0.19041.0/win10-x64/Justice.exe differ
diff --git a/bin/Debug/net9.0-windows10.0.19041.0/win10-x64/Justice.pdb b/bin/Debug/net9.0-windows10.0.19041.0/win10-x64/Justice.pdb
index a91338f..ab90902 100644
Binary files a/bin/Debug/net9.0-windows10.0.19041.0/win10-x64/Justice.pdb and b/bin/Debug/net9.0-windows10.0.19041.0/win10-x64/Justice.pdb differ