LoginLog.razor 1.7 KB

1234567891011121314151617181920212223242526272829303132333435
  1. @page "/system/alllog/loginlog"
  2. @attribute [ReuseTabsPage(Title = "登录日志管理")]
  3. <Spin Spinning="Loading">
  4. <Table @ref="Table" AutoHeight TItem="SystemLogLogin" @bind-PageSize="Ps" @bind-PageIndex="Pi" Total="Total"
  5. DataSource="DataSource" @bind-SelectedRows="SelectedRows" OnChange="OnChange">
  6. <TitleTemplate>
  7. <Flex Justify="FlexJustify.Start" Gap="@("10")">
  8. <Input Width="300" Placeholder="输入名称" @bind-Value="@Q_Name" />
  9. <Button OnClick="Search">搜索</Button>
  10. <Button OnClick="ResetQuery">重置</Button>
  11. </Flex>
  12. </TitleTemplate>
  13. <ColumnDefinitions Context="row">
  14. <PropertyColumn Align="ColumnAlign.Center" Property="c=>c.Id" Width="100" Title="ID" />
  15. <PropertyColumn Align="ColumnAlign.Left" Property="c=>c.Info" Title="日志信息" />
  16. <PropertyColumn Align="ColumnAlign.Center" Property="c => c.CreateTime" Title="创建时间" Width="200">
  17. @{
  18. var formattedTime = row.CreateTime?.ToString("yyyy-MM-dd HH:mm:ss") ?? "N/A";
  19. }
  20. @formattedTime
  21. </PropertyColumn>
  22. </ColumnDefinitions>
  23. <PaginationTemplate>
  24. <Pagination Class="@(context.PaginationClass + " my-custom-pagination")"
  25. Total="context.Total"
  26. PageSize="context.PageSize"
  27. Current="context.PageIndex"
  28. ShowSizeChanger
  29. ShowQuickJumper
  30. ShowTotal="ShowTotal"
  31. OnChange="context.HandlePageChange" />
  32. </PaginationTemplate>
  33. </Table>
  34. </Spin>