:zap:代码生成优化

This commit is contained in:
不做码农
2023-12-17 16:25:56 +08:00
parent d67d401f14
commit 7c78ce8ed5
4 changed files with 36 additions and 58 deletions
+2 -21
View File
@@ -1,5 +1,4 @@
using System.Collections.Generic;
using ZR.Model.System.Generate;
using ZR.Model.System.Generate;
namespace ZR.Model.System.Dto
{
@@ -24,28 +23,10 @@ namespace ZR.Model.System.Dto
/// <summary>
/// 额外参数
/// </summary>
public Options Params { get; set; }
public CodeOptions Params { get; set; }
public List<GenTableColumnDto> Columns { get; set; }
}
/// <summary>
/// 额外参数
/// ****注意里面参数统一首字母小写*****
/// </summary>
public class Params
{
public string TreeCode { get; set; }
public string TreeName { get; set; }
public string TreeParentCode { get; set; }
public int? ParentMenuId { get; set; }
public string SortField { get; set; }
public string SortType { get; set; }
/// <summary>
/// 额外参数字符串
/// </summary>
public string CheckedBtn { get; set; }
public string PermissionPrefix { get; set; }
}
public class GenTableColumnDto
{
public int ColumnId { get; set; }
+3 -6
View File
@@ -1,7 +1,4 @@
using SqlSugar;
using System.Collections.Generic;
namespace ZR.Model.System.Generate
namespace ZR.Model.System.Generate
{
/// <summary>
/// 代码生成表
@@ -86,7 +83,7 @@ namespace ZR.Model.System.Generate
/// 其他生成选项
/// </summary>
[SugarColumn(IsJson = true)]
public Options Options { get; set; }
public CodeOptions Options { get; set; }
#region 表额外字段
/// <summary>
@@ -103,7 +100,7 @@ namespace ZR.Model.System.Generate
#endregion
}
public class Options
public class CodeOptions
{
public long ParentMenuId { get; set; }
public string SortType { get; set; } = "asc";