2023-05-23 23:54:28 +08:00
|
|
|
|
@*
|
|
|
|
|
|
//------------------------------------------------------------------------------
|
|
|
|
|
|
// 此代码版权声明为全文件覆盖,如有原作者特别声明,会在下方手动补充
|
|
|
|
|
|
// 此代码版权(除特别声明外的代码)归作者本人Diego所有
|
|
|
|
|
|
// 源代码使用协议遵循本仓库的开源协议及附加协议
|
2023-07-16 18:07:31 +08:00
|
|
|
|
// Gitee源代码仓库:https://gitee.com/diego2098/ThingsGateway
|
2023-05-23 23:54:28 +08:00
|
|
|
|
// Github源代码仓库:https://github.com/kimdiego2098/ThingsGateway
|
2023-07-16 17:48:22 +08:00
|
|
|
|
// 使用文档:https://diego2098.gitee.io/thingsgateway-docs/
|
2023-05-23 23:54:28 +08:00
|
|
|
|
// QQ群:605534569
|
|
|
|
|
|
//------------------------------------------------------------------------------
|
|
|
|
|
|
*@
|
|
|
|
|
|
|
2023-08-07 15:09:53 +08:00
|
|
|
|
@page "/admin/vislog"
|
2023-03-04 18:41:11 +08:00
|
|
|
|
@using System.Linq.Expressions;
|
2023-08-07 15:09:53 +08:00
|
|
|
|
@using Microsoft.AspNetCore.Authorization;
|
|
|
|
|
|
@using ThingsGateway.Admin.Application;
|
2023-09-02 19:13:57 +08:00
|
|
|
|
|
2023-08-07 15:09:53 +08:00
|
|
|
|
@namespace ThingsGateway.Admin.Blazor
|
2023-03-04 18:41:11 +08:00
|
|
|
|
@attribute [Authorize]
|
|
|
|
|
|
@inject UserResoures UserResoures
|
2023-08-07 15:09:53 +08:00
|
|
|
|
@inherits BaseComponentBase
|
2023-03-04 18:41:11 +08:00
|
|
|
|
@layout MainLayout
|
2023-08-07 15:09:53 +08:00
|
|
|
|
<AppDataTable @ref="_datatable" TItem="SysVisitLog" SearchItem="VisitLogPageInput"
|
|
|
|
|
|
AddItem="object" EditItem="object" IsShowSelect=false
|
2023-03-04 18:41:11 +08:00
|
|
|
|
SearchModel="@search" IsShowOperCol=false
|
2023-08-07 15:09:53 +08:00
|
|
|
|
QueryCallAsync="QueryCallAsync"
|
|
|
|
|
|
IsShowQueryButton IsShowSearchKey>
|
2023-03-04 18:41:11 +08:00
|
|
|
|
<SearchTemplate>
|
|
|
|
|
|
<MSelect Style="max-width:200px;"
|
|
|
|
|
|
Class="my-1 mx-2 " @bind-Value="context.Category"
|
2023-05-22 18:40:50 +08:00
|
|
|
|
Outlined Label=@context.Description(x => x.Category)
|
2023-03-04 18:41:11 +08:00
|
|
|
|
Items=@(CategoryFilters) Clearable
|
|
|
|
|
|
MenuProps="@(props => { props.Bottom = true; props.OffsetY = true; })"
|
|
|
|
|
|
ItemText=@((u) =>u.Key)
|
|
|
|
|
|
ItemValue=@(u => u.Value)
|
|
|
|
|
|
HideDetails="true" Height="30"
|
2023-05-22 18:40:50 +08:00
|
|
|
|
Dense>
|
2023-03-04 18:41:11 +08:00
|
|
|
|
</MSelect>
|
|
|
|
|
|
<MSelect Style="max-width:200px;"
|
|
|
|
|
|
Class="my-1 mx-2 " @bind-Value="context.ExeStatus"
|
2023-05-22 18:40:50 +08:00
|
|
|
|
Outlined Label=@context.Description(x => x.ExeStatus)
|
2023-03-04 18:41:11 +08:00
|
|
|
|
Items=@(ExeStatus) Clearable
|
|
|
|
|
|
MenuProps="@(props => { props.Bottom = true; props.OffsetY = true; })"
|
|
|
|
|
|
ItemText=@((u) =>u.Key)
|
|
|
|
|
|
ItemValue=@(u => u.Value)
|
|
|
|
|
|
HideDetails="true" Height="30"
|
2023-05-22 18:40:50 +08:00
|
|
|
|
Dense>
|
2023-03-04 18:41:11 +08:00
|
|
|
|
</MSelect>
|
|
|
|
|
|
<MTextField Dense Style="max-width:200px;" HideDetails=@("auto") Class="my-1 mx-2 " @bind-Value="context.Account"
|
2023-05-22 18:40:50 +08:00
|
|
|
|
Outlined Label=@context.Description(x => x.Account) />
|
2023-03-04 18:41:11 +08:00
|
|
|
|
|
|
|
|
|
|
</SearchTemplate>
|
|
|
|
|
|
<OtherToolbarTemplate>
|
2023-08-07 15:09:53 +08:00
|
|
|
|
@if (@UserResoures.IsHasButtonWithRole("sysvislogclear"))
|
2023-03-04 18:41:11 +08:00
|
|
|
|
{
|
2023-08-07 15:09:53 +08:00
|
|
|
|
<MButton Color="error" Class="mx-2 my-1" OnClick=@(ClearClickAsync)>清空</MButton>
|
2023-03-04 18:41:11 +08:00
|
|
|
|
}
|
2023-08-07 15:09:53 +08:00
|
|
|
|
<MMenu OffsetY Context="menu">
|
|
|
|
|
|
<ActivatorContent>
|
|
|
|
|
|
<MButton @attributes="@menu.Attrs" Color="primary"
|
|
|
|
|
|
Class="my-1 mx-2 ">
|
|
|
|
|
|
导出
|
|
|
|
|
|
<AppChevronDown></AppChevronDown>
|
|
|
|
|
|
</MButton>
|
|
|
|
|
|
</ActivatorContent>
|
|
|
|
|
|
<ChildContent>
|
|
|
|
|
|
<MList>
|
|
|
|
|
|
<MListItem OnClick="()=>DownExportAsync()">导出全部</MListItem>
|
|
|
|
|
|
<MListItem OnClick="()=>DownExportAsync(search)">导出搜索项</MListItem>
|
|
|
|
|
|
</MList>
|
|
|
|
|
|
|
|
|
|
|
|
</ChildContent>
|
|
|
|
|
|
</MMenu>
|
2023-03-04 18:41:11 +08:00
|
|
|
|
</OtherToolbarTemplate>
|
|
|
|
|
|
|
|
|
|
|
|
</AppDataTable>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|