parent
e5847bbece
commit
5529457512
@ -1,3 +1,28 @@
|
||||
@page "/list"
|
||||
@using ProjetBlaser.Models
|
||||
|
||||
<h3>List</h3>
|
||||
<h3>List</h3>
|
||||
|
||||
<DataGrid TItem="Item"
|
||||
Data="@items"
|
||||
ReadData="@OnReadData"
|
||||
TotalItems="@totalItem"
|
||||
PageSize="10"
|
||||
ShowPager
|
||||
Responsive>
|
||||
<DataGridColumn TItem="Item" Field="@nameof(Item.Id)" Caption="#" />
|
||||
<DataGridColumn TItem="Item" Field="@nameof(Item.DisplayName)" Caption="Display name" />
|
||||
<DataGridColumn TItem="Item" Field="@nameof(Item.StackSize)" Caption="Stack size" />
|
||||
<DataGridColumn TItem="Item" Field="@nameof(Item.MaxDurability)" Caption="Maximum durability" />
|
||||
<DataGridColumn TItem="Item" Field="@nameof(Item.EnchantCategories)" Caption="Enchant categories">
|
||||
<DisplayTemplate>
|
||||
@(string.Join(", ", ((Item)context).EnchantCategories))
|
||||
</DisplayTemplate>
|
||||
</DataGridColumn>
|
||||
<DataGridColumn TItem="Item" Field="@nameof(Item.RepairWith)" Caption="Repair with">
|
||||
<DisplayTemplate>
|
||||
@(string.Join(", ", ((Item)context).RepairWith))
|
||||
</DisplayTemplate>
|
||||
</DataGridColumn>
|
||||
<DataGridColumn TItem="Item" Field="@nameof(Item.CreatedDate)" Caption="Created date" DisplayFormat="{0:d}" DisplayFormatProvider="@System.Globalization.CultureInfo.GetCultureInfo("fr-FR")" />
|
||||
</DataGrid>
|
@ -0,0 +1,35 @@
|
||||
[
|
||||
{
|
||||
"id": 1,
|
||||
"displayname": "Furnafix",
|
||||
"name": "furnafix",
|
||||
"stacksize": 36,
|
||||
"maxdurability": 32,
|
||||
"enchantcategories": [ " " ],
|
||||
"repairwith": [ " " ],
|
||||
"createddate": "2019-02-16",
|
||||
"updateddate": "2020-06-15"
|
||||
},
|
||||
{
|
||||
"id": 2,
|
||||
"displayname": "Deminimum",
|
||||
"name": "deminimum",
|
||||
"stacksize": 49,
|
||||
"maxdurability": 46,
|
||||
"enchantcategories": [ " " ],
|
||||
"repairwith": [ " " ],
|
||||
"createddate": "2020-06-14",
|
||||
"updateddate": "2020-06-15"
|
||||
},
|
||||
{
|
||||
"id": 3,
|
||||
"displayname": "Minecraft",
|
||||
"name": "minecraft",
|
||||
"stacksize": 50,
|
||||
"maxdurability": 40,
|
||||
"enchantcategories": [ "armor" ],
|
||||
"repairwith": [ "jungle_plants" ],
|
||||
"createddate": "2020-06-15",
|
||||
"updateddate": "2020-06-15"
|
||||
}
|
||||
]
|
Loading…
Reference in new issue