33 lines
632 B
Plaintext
33 lines
632 B
Plaintext
@using JSMR.Application.VoiceWorks.Queries.Search
|
|
|
|
@if (Products is null)
|
|
{
|
|
<p>Loading…</p>
|
|
}
|
|
else if (Products.Length == 0)
|
|
{
|
|
<p>No results.</p>
|
|
}
|
|
else
|
|
{
|
|
<div class="j-product-items-container">
|
|
@foreach (var product in Products)
|
|
{
|
|
<JProduct Product="@product" ProductDeleted="OnProductDeleted"></JProduct>
|
|
}
|
|
</div>
|
|
}
|
|
|
|
@code {
|
|
[Parameter]
|
|
public VoiceWorkSearchResult[]? Products { get; set; }
|
|
|
|
[Parameter]
|
|
public EventCallback ProductDeleted { get; set; }
|
|
|
|
private async Task OnProductDeleted()
|
|
{
|
|
await ProductDeleted.InvokeAsync();
|
|
}
|
|
}
|