Files
lux/Lux.Report.Manager/Components/Compo/RepoFileList.razor.cs
T
2026-04-07 18:39:46 +02:00

53 lines
1.3 KiB
C#

using Lux.Report.Data.DbModel;
using Lux.Report.Data.Services;
using Microsoft.AspNetCore.Components;
namespace Lux.Report.Manager.Components.Compo
{
public partial class RepoFileList
{
#region Public Properties
[Parameter]
public ReportModel CurrReport { get; set; } = null!;
[Parameter]
public EventCallback<string> EC_ReqEdit { get; set; }
#endregion Public Properties
#region Protected Methods
protected override void OnParametersSet()
{
//base.OnParametersSet();
string repPath = Path.Combine("reports", CurrReport.Name);
ListReports = FService.ListFile(repPath, "*.repx");
}
#endregion Protected Methods
#region Private Fields
private List<string> ListReports = new List<string>();
#endregion Private Fields
protected string FileName(string fullName)
{
return Path.GetFileName(fullName);
}
private async Task ReqEdit(string fullPath)
{
await EC_ReqEdit.InvokeAsync(fullPath);
}
#region Private Properties
[Inject]
private IFileService FService { get; set; } = null!;
#endregion Private Properties
}
}