😎1、修复前端常量转换 2、调整获取所有实体列bug 3、优化代码生成模板

This commit is contained in:
zuohuaijun 2024-12-05 11:43:01 +08:00
parent 8d65978e0f
commit 2e910f64ec
6 changed files with 6 additions and 6 deletions

View File

@ -27,6 +27,7 @@
<ItemGroup>
<ProjectReference Include="..\Admin.NET.Core\Admin.NET.Core.csproj" />
<ProjectReference Include="..\Plugins\Admin.NET.Plugin.GoView\Admin.NET.Plugin.GoView.csproj" />
<ProjectReference Include="..\Plugins\Admin.NET.Plugin.ReZero\Admin.NET.Plugin.ReZero.csproj" />
</ItemGroup>
</Project>

View File

@ -218,7 +218,7 @@ public class SysCodeGenService : IDynamicApiController, ITransient
var entityType = provider.DbMaintenance.GetTableInfoList(false).FirstOrDefault(u => u.Name == tableName);
if (entityType == null) return null;
var entityBasePropertyNames = _codeGenOptions.EntityBaseColumn[nameof(EntityTenant)];
var properties = GetEntityInfos().Result.First(u => u.DbTableName == tableName).Type.GetProperties()
var properties = GetEntityInfos().Result.First(u => u.DbTableName.ToLower() == tableName).Type.GetProperties()
.Where(e => e.GetCustomAttribute<SugarColumn>()?.IsIgnore == false).Select(u => new
{
PropertyName = u.Name,

View File

@ -13,5 +13,4 @@
</p>
</div>
<p>@ViewBag.Description</p>
<p><a href="https://gitee.com/zuohuaijun/Admin.NET" target="_blank">源码地址</a></p>
</div>

View File

@ -333,7 +333,7 @@ const checkTableColumnVisible = (tableColumnName: any) => {
// 设置列显隐
customConfig: {
visibleMethod({ column }) {
return useUserTableConfig().userTableList.includes(`@Model.LowerClassName:${column.field}`);
return checkTableColumnVisible(`@Model.LowerClassName:${column.field}`);
},
},
}

View File

@ -2,7 +2,7 @@
"name": "admin.net.pro",
"type": "module",
"version": "2.4.33",
"lastBuildTime": "2024.12.04",
"lastBuildTime": "2024.12.05",
"description": "Admin.NET 站在巨人肩膀上的 .NET 通用权限开发框架",
"author": "zuohuaijun",
"license": "MIT",
@ -74,7 +74,7 @@
"vue-router": "^4.5.0",
"vue-signature-pad": "^3.0.2",
"vue3-tree-org": "^4.2.2",
"vxe-pc-ui": "^4.3.14",
"vxe-pc-ui": "^4.3.15",
"vxe-table": "^4.8.10",
"vxe-table-plugin-element": "^4.0.4",
"vxe-table-plugin-export-xlsx": "^4.0.7",

View File

@ -42,7 +42,7 @@ export const useUserInfo = defineStore('userInfo', {
// 处理字典国际化
this.dictList[key].forEach((e: any) => setDictLangMessage(e));
if (key.endsWith('Enum')) {
this.dictList[key].forEach((e: any) => (e.code = Number(e.code)));
this.dictList[key].forEach((e: any) => (e.value = Number(e.value)));
}
}
},