Implentata scansione barcode e lista articoli nel form scheda
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
using MudBlazor;
|
||||
using SteUp.Shared.Components.SingleElements.Modal;
|
||||
using SteUp.Shared.Components.SingleElements.Modal.ExceptionModal;
|
||||
using SteUp.Shared.Core.Dto;
|
||||
using SteUp.Shared.Core.Entities;
|
||||
|
||||
@@ -86,4 +87,48 @@ public abstract class ModalHelper
|
||||
|
||||
return await modal.Result;
|
||||
}
|
||||
|
||||
public static async Task<DialogResult?> OpenSelectArt(IDialogService dialog, List<ArticoliInGrigliaDto>? articoli)
|
||||
{
|
||||
var modal = await dialog.ShowAsync<ModalSelectArt>(
|
||||
"ModalSelectArt",
|
||||
new DialogParameters<ModalSelectArt>
|
||||
{
|
||||
{ x => x.Articoli, articoli }
|
||||
},
|
||||
new DialogOptions
|
||||
{
|
||||
FullScreen = false,
|
||||
CloseButton = false,
|
||||
NoHeader = true,
|
||||
BackdropClick = true,
|
||||
FullWidth = true,
|
||||
MaxWidth = MaxWidth.ExtraLarge
|
||||
}
|
||||
);
|
||||
|
||||
return await modal.Result;
|
||||
}
|
||||
|
||||
public static async Task ShowError(IDialogService dialog, string message)
|
||||
{
|
||||
var modal = await dialog.ShowAsync<ModalError>(
|
||||
"ModalError",
|
||||
new DialogParameters<ModalError>
|
||||
{
|
||||
{ x => x.ErrorMessage, message }
|
||||
},
|
||||
new DialogOptions
|
||||
{
|
||||
FullScreen = false,
|
||||
CloseButton = false,
|
||||
NoHeader = true,
|
||||
BackdropClick = true,
|
||||
FullWidth = true,
|
||||
MaxWidth = MaxWidth.ExtraLarge
|
||||
}
|
||||
);
|
||||
|
||||
await modal.Result;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user