mirror of https://github.com/abpframework/abp.git
csharpabpc-sharpframeworkblazoraspnet-coredotnet-coreaspnetcorearchitecturesaasdomain-driven-designangularmulti-tenancy
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
33 lines
1.1 KiB
33 lines
1.1 KiB
using System;
|
|
using System.Collections.Generic;
|
|
using JetBrains.Annotations;
|
|
using Volo.Abp.SimpleStateChecking;
|
|
|
|
namespace Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Toolbars
|
|
{
|
|
public class ToolbarItem : IHasSimpleStateCheckers<ToolbarItem>
|
|
{
|
|
public Type ComponentType
|
|
{
|
|
get => _componentType;
|
|
set => _componentType = Check.NotNull(value, nameof(value));
|
|
}
|
|
private Type _componentType;
|
|
|
|
public int Order { get; set; }
|
|
|
|
[CanBeNull]
|
|
[Obsolete("Use RequirePermissions extension method.")]
|
|
public string RequiredPermissionName { get; set; }
|
|
|
|
public List<ISimpleStateChecker<ToolbarItem>> SimpleStateCheckers { get; }
|
|
|
|
public ToolbarItem([NotNull] Type componentType, int order = 0, string requiredPermissionName = null)
|
|
{
|
|
Order = order;
|
|
ComponentType = Check.NotNull(componentType, nameof(componentType));
|
|
RequiredPermissionName = requiredPermissionName;
|
|
SimpleStateCheckers = new List<ISimpleStateChecker<ToolbarItem>>();
|
|
}
|
|
}
|
|
}
|
|
|