mirror of
https://gitlab.com/fabinfra/fabaccess/borepin.git
synced 2025-03-12 14:51:44 +01:00
Fixed QR-Code
This commit is contained in:
parent
1e2604486c
commit
530112ccc6
@ -2,10 +2,12 @@
|
||||
using Prism.Commands;
|
||||
using Prism.Navigation;
|
||||
using Prism.Services;
|
||||
using System.Collections.Generic;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Input;
|
||||
using Xamarin.Forms;
|
||||
using ZXing;
|
||||
using ZXing.Mobile;
|
||||
|
||||
namespace Borepin.PageModel
|
||||
{
|
||||
@ -40,6 +42,23 @@ namespace Borepin.PageModel
|
||||
#endregion
|
||||
|
||||
#region Fields
|
||||
public MobileBarcodeScanningOptions ScanOptions
|
||||
{
|
||||
get
|
||||
{
|
||||
return new MobileBarcodeScanningOptions()
|
||||
{
|
||||
PossibleFormats = new List<BarcodeFormat>()
|
||||
{
|
||||
BarcodeFormat.QR_CODE,
|
||||
BarcodeFormat.EAN_13,
|
||||
},
|
||||
AutoRotate = true,
|
||||
DelayBetweenContinuousScans = 300,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
private Result _ScanResult;
|
||||
public Result ScanResult
|
||||
{
|
||||
@ -73,7 +92,6 @@ namespace Borepin.PageModel
|
||||
public void ScannedCommandExecute()
|
||||
{
|
||||
IsScanning = false;
|
||||
IsVisible = false;
|
||||
|
||||
INavigationParameters parameters = new NavigationParameters()
|
||||
{
|
||||
@ -96,7 +114,6 @@ namespace Borepin.PageModel
|
||||
public async Task CancelCommandExecute()
|
||||
{
|
||||
IsScanning = false;
|
||||
IsVisible = false;
|
||||
|
||||
INavigationParameters parameters = new NavigationParameters()
|
||||
{
|
||||
|
@ -34,14 +34,14 @@ namespace Borepin.PageModel
|
||||
return new MobileBarcodeScanningOptions()
|
||||
{
|
||||
PossibleFormats = new List<BarcodeFormat>()
|
||||
{
|
||||
{
|
||||
BarcodeFormat.QR_CODE,
|
||||
BarcodeFormat.EAN_13,
|
||||
// TODO add more Barcode Formats if needed
|
||||
},
|
||||
AutoRotate = true,
|
||||
DelayBetweenContinuousScans = 300,
|
||||
};
|
||||
}
|
||||
//set => SetProperty(ref _ScanOptions, value);
|
||||
}
|
||||
|
||||
private Result _ScanResult;
|
||||
@ -146,7 +146,6 @@ namespace Borepin.PageModel
|
||||
public async Task CancelCommandExecute()
|
||||
{
|
||||
IsScanning = false;
|
||||
IsVisible = false;
|
||||
|
||||
await _NavigationService.GoBackAsync().ConfigureAwait(false);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user