Barcodes speichern

This commit is contained in:
2024-08-21 00:11:59 +02:00
parent a61aa38d24
commit 423e5f3cd2
12 changed files with 142 additions and 49 deletions

View File

@@ -7,19 +7,21 @@ namespace Jugenddienst_Stunden.ViewModels {
internal class AboutViewModel {
public string Title => AppInfo.Name;
public string Version => AppInfo.VersionString;
public string MoreInfoUrl => "https://aka.ms/maui";
public string Message => "This app is written in XAML and C# with .NET MAUI.";
public ICommand ShowMoreInfoCommand { get; }
public string Message => "Scanne den QR-Code von deinem Benutzerprofil auf der Stundenseite.";
public AboutViewModel() {
ShowMoreInfoCommand = new AsyncRelayCommand(ShowMoreInfo);
}
async Task ShowMoreInfo() =>
await Launcher.Default.OpenAsync(MoreInfoUrl);
//private void BarcodesDetected(object sender, ZXing.Net.Maui.BarcodeDetectionEventArgs e) {
// var first = e.Results?.FirstOrDefault();
// if (first is null) {
// return;
// }
// System.Windows.Application.Current.Dispatcher.DispatchAsync(async () => {
// await DisplayAlert("Scan-Ergebnis", $"Barcode: {first.Value}", "OK");
// });
//}
//private async void SetupBarcodeScanner() {
// try {
@@ -44,7 +46,7 @@ namespace Jugenddienst_Stunden.ViewModels {
// }
//}
}
}