57 lines
1.4 KiB
C#
57 lines
1.4 KiB
C#
using Microsoft.AspNetCore.Components;
|
|
using WebWindowComplex.DTO;
|
|
using WebWindowComplex.Models;
|
|
|
|
namespace WebWindowComplex.Compo
|
|
{
|
|
public partial class CardArcElement
|
|
{
|
|
#region Public Properties
|
|
|
|
/// <summary>
|
|
/// Frame corrente
|
|
/// </summary>
|
|
[Parameter]
|
|
public Frame CurrFrame { get; set; } = null!;
|
|
|
|
/// <summary>
|
|
/// Lista sash group
|
|
/// </summary>
|
|
[Parameter]
|
|
public List<Sash> SashList { get; set; } = null!;
|
|
|
|
[Parameter]
|
|
public EventCallback<DataUpdateFrame> EC_UpdatePreview { get; set; }
|
|
|
|
[Parameter]
|
|
public EventCallback<bool> EC_ReqClose { get; set; }
|
|
|
|
#endregion Public Properties
|
|
|
|
private Task UpdatePreview()
|
|
{
|
|
var args = new DataUpdateFrame { currFrame = CurrFrame };
|
|
return EC_UpdatePreview.InvokeAsync(args);
|
|
}
|
|
|
|
private async Task UpdatePreviewSash(Sash CurrSashGRoup)
|
|
{
|
|
var currRec = SashList.First(x => x.GroupId == CurrSashGRoup.GroupId);
|
|
if (currRec != null)
|
|
{
|
|
currRec = CurrSashGRoup;
|
|
var args = new DataUpdateFrame
|
|
{
|
|
currFrame = CurrFrame
|
|
};
|
|
await EC_UpdatePreview.InvokeAsync(args);
|
|
}
|
|
}
|
|
|
|
private void ReqClose()
|
|
{
|
|
_ = EC_ReqClose.InvokeAsync(true);
|
|
}
|
|
}
|
|
|
|
} |