feat: 更新自定义搜索模型增加 Display 标签

This commit is contained in:
Argo-Tianyi 2021-12-13 15:17:35 +08:00
parent b14d9d5752
commit affbfe1d88
2 changed files with 14 additions and 9 deletions

View File

@ -1,15 +1,15 @@
<div class="row g-3 form-inline">
<div class="col-sm-6 col-md-6">
<BootstrapInput @bind-Value="Value.Name" ShowLabel="true" DisplayText="字典名称" />
<BootstrapInput @bind-Value="Value.Category" ShowLabel="true" />
</div>
<div class="col-sm-6 col-md-6">
<BootstrapInput @bind-Value="Value.Category" ShowLabel="true" DisplayText="字典标签" />
<BootstrapInput @bind-Value="Value.Name" ShowLabel="true" />
</div>
<div class="col-sm-6 col-md-6">
<BootstrapInput @bind-Value="Value.Code" ShowLabel="true" DisplayText="字典代码" />
<BootstrapInput @bind-Value="Value.Code" ShowLabel="true" />
</div>
<div class="col-sm-6 col-md-6">
<Select Items="@Items" @bind-Value="Value.Define" ShowLabel="true" DisplayText="字典类型" />
<Select Items="@Items" @bind-Value="Value.Define" ShowLabel="true" />
</div>
</div>

View File

@ -1,4 +1,5 @@
using BootstrapAdmin.DataAccess.Models;
using System.ComponentModel.DataAnnotations;
namespace BootstrapAdmin.Web.Models
{
@ -10,23 +11,27 @@ namespace BootstrapAdmin.Web.Models
/// <summary>
/// 获得/设置 字典标签
/// </summary>
[Display(Name = "字典标签")]
public string? Category { get; set; }
/// <summary>
/// 获得/设置 字典类型
/// </summary>
public EnumDictDefine? Define { get; set; }
/// <summary>
/// 获得/设置 字典名称
/// </summary>
[Display(Name = "字典名称")]
public string? Name { get; set; }
/// <summary>
/// 获得/设置 字典代码
/// </summary>
[Display(Name = "字典代码")]
public string? Code { get; set; }
/// <summary>
/// 获得/设置 字典类型
/// </summary>
[Display(Name = "字典类型")]
public EnumDictDefine? Define { get; set; }
/// <summary>
///
/// </summary>