From b2379f0a27da604de31869137f892629ce99a1da Mon Sep 17 00:00:00 2001 From: sunpengfei <i@angelzzz.com> Date: 星期三, 06 八月 2025 16:58:51 +0800 Subject: [PATCH] feat:字典开发 --- FlexJobApi.Core/Models/Main/Dictionaries/Queries/GetDictionaryDatasQuery.cs | 43 +++++++++++++++++++++++++++++++++++++++++-- 1 files changed, 41 insertions(+), 2 deletions(-) diff --git a/FlexJobApi.Core/Models/Main/Dictionaries/Queries/GetDictionaryDatasQuery.cs b/FlexJobApi.Core/Models/Main/Dictionaries/Queries/GetDictionaryDatasQuery.cs index 24345b6..4a7af33 100644 --- a/FlexJobApi.Core/Models/Main/Dictionaries/Queries/GetDictionaryDatasQuery.cs +++ b/FlexJobApi.Core/Models/Main/Dictionaries/Queries/GetDictionaryDatasQuery.cs @@ -1,4 +1,5 @@ -锘縰sing MediatR; +锘縰sing Mapster; +using MediatR; using System; using System.Collections.Generic; using System.ComponentModel.DataAnnotations; @@ -15,9 +16,14 @@ public class GetDictionaryDatasQuery : PagedListQuery<PagedListQueryResult<GetDictionaryDatasQueryResultItem>, GetDictionaryDatasQueryResultItem> { /// <summary> - /// 绫诲埆Id + /// 绫诲埆Id锛圛d/缂栧彿浜岄�変竴锛� /// </summary> public Guid? CategoryId { get; set; } + + /// <summary> + /// 绫诲埆缂栧彿锛圛d/缂栧彿浜岄�変竴锛� + /// </summary> + public string CategoryCode { get; set; } /// <summary> /// 鍏抽敭瀛� @@ -39,6 +45,23 @@ /// 绫诲埆Id /// </summary> public Guid CategoryId { get; set; } + + /// <summary> + /// 绫诲埆缂栧彿 + /// </summary> + [AdaptIgnore] + public string CategoryCode => Category?.Code; + + /// <summary> + /// 绫诲埆鍚嶇О + /// </summary> + [AdaptIgnore] + public string CategoryName => Category?.Name; + + /// <summary> + /// 绫诲埆 + /// </summary> + public GetDictionaryDatasQueryResultItemCategory Category { get; set; } /// <summary> /// 涓婄骇Id @@ -92,4 +115,20 @@ /// </summary> public bool IsDisabled { get; set; } } + + /// <summary> + /// 鑾峰彇鏁版嵁瀛楀吀鍒嗛〉鍒楄〃鏁版嵁-缁撴灉-琛屾暟鎹�-绫诲埆 + /// </summary> + public class GetDictionaryDatasQueryResultItemCategory + { + /// <summary> + /// 绫诲埆缂栧彿 + /// </summary> + public string Code { get; set; } + + /// <summary> + /// 鍚嶇О + /// </summary> + public string Name { get; set; } + } } -- Gitblit v1.9.1