Initial commit - Common.RCL
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
@* @using System.Reflection
|
||||
@typeparam TModel
|
||||
|
||||
|
||||
|
||||
|
||||
@foreach (var model in models)
|
||||
{
|
||||
@foreach (var property in Properties.Where(x => ))
|
||||
{
|
||||
property.GetValue(model);
|
||||
}
|
||||
|
||||
|
||||
@foreach (var member in model.GetProperties())
|
||||
{
|
||||
member.GetValue(memb);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
@code {
|
||||
|
||||
|
||||
[Parameter]
|
||||
public List<string> Exclude { get; set; }
|
||||
|
||||
[Parameter] public Func<Task<List<TModel>>> GetDataFunc { get; set; }
|
||||
|
||||
IEnumerable<TModel> models;
|
||||
|
||||
PropertyInfo[] Properties = typeof(TModel).GetProperties();
|
||||
|
||||
protected override async Task OnInitializedAsync()
|
||||
{
|
||||
models = await GetDataFunc();
|
||||
}
|
||||
|
||||
} *@
|
||||
Reference in New Issue
Block a user