mirror of
https://github.com/nsnail/NetAdmin.git
synced 2025-09-13 17:25:34 +08:00
@@ -18,6 +18,8 @@ indent_size = 2 # 对于 JSON 和 YAML 文件,缩进大小为 2 个空格
|
||||
|
||||
[*.cs]
|
||||
dotnet_analyzer_diagnostic.severity = warning # 设置 C# 文件中所有 dotnet_analyzer_diagnostic 的严重性级别为 warning
|
||||
[{*.g.cs,*.generated.cs}]
|
||||
dotnet_analyzer_diagnostic.severity = none # 对于生成的文件,取消所有 dotnet_analyzer_diagnostic 的警告
|
||||
|
||||
# ReSharper properties
|
||||
resharper_align_linq_query = true # 启用对LINQ查询的对齐
|
||||
|
331
CHANGELOG.md
331
CHANGELOG.md
@@ -1,10 +1,10 @@
|
||||
# Changelog
|
||||
|
||||
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
||||
All notable changes to this project will be documented in this file.
|
||||
See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
||||
|
||||
## [2.4.0](https://github.com/nsnail/NetAdmin/compare/v2.1.0...v2.4.0) (2025-07-02)
|
||||
|
||||
|
||||
### ⚠ BREAKING CHANGES
|
||||
|
||||
* [skip ci]
|
||||
@@ -14,38 +14,46 @@ All notable changes to this project will be documented in this file. See [standa
|
||||
* ✨ 表格操作栏按钮下拉菜单 ([51cc9fa](https://github.com/nsnail/NetAdmin/commit/51cc9fa80ca296fa6c320d0a47ed51ee0aaef1ce))
|
||||
* ✨ 表格右键菜单增加排序功能 ([a202595](https://github.com/nsnail/NetAdmin/commit/a2025956878d4e8fb935659f4db0adee02cd8071))
|
||||
* ✨ 财务管理 ([94d0b70](https://github.com/nsnail/NetAdmin/commit/94d0b7028f8a0d31af67b435f5ed14f7eb2de0b4))
|
||||
* ✨ 菜单复制 ([#214](https://github.com/nsnail/NetAdmin/issues/214)) ([81d9b0b](https://github.com/nsnail/NetAdmin/commit/81d9b0b3bb280661ceffa61aa6e9d612fb7ec52c))
|
||||
* ✨
|
||||
菜单复制 ([#214](https://github.com/nsnail/NetAdmin/issues/214)) ([81d9b0b](https://github.com/nsnail/NetAdmin/commit/81d9b0b3bb280661ceffa61aa6e9d612fb7ec52c))
|
||||
* ✨ 分组统计功能 ([0b036e9](https://github.com/nsnail/NetAdmin/commit/0b036e9d67ffdf7a07c772606009f02744e6a3c3))
|
||||
* ✨ 框架代码同步 ([098cfc1](https://github.com/nsnail/NetAdmin/commit/098cfc135e781a0cf172cd1289e5e871c7a76419))
|
||||
* ✨ 框架代码同步 ([7256626](https://github.com/nsnail/NetAdmin/commit/725662693b7b47f6fae4c1917dd8d80220c7640a))
|
||||
* ✨ 文档管理 ([#221](https://github.com/nsnail/NetAdmin/issues/221)) ([7ed3040](https://github.com/nsnail/NetAdmin/commit/7ed30406c9f721a12f0b756ec8884a1882242b93))
|
||||
* ✨
|
||||
文档管理 ([#221](https://github.com/nsnail/NetAdmin/issues/221)) ([7ed3040](https://github.com/nsnail/NetAdmin/commit/7ed30406c9f721a12f0b756ec8884a1882242b93))
|
||||
* ✨ 移动国家代码 ([2ff1466](https://github.com/nsnail/NetAdmin/commit/2ff146664e539c395d98530856783f33d3bbd6f2))
|
||||
* ✨ 营销管理 ([62ac779](https://github.com/nsnail/NetAdmin/commit/62ac7790e80408c9194a71b032f7597c5d8c16cf))
|
||||
* ✨ 营销管理-返佣比率 ([e5a0f92](https://github.com/nsnail/NetAdmin/commit/e5a0f925a0650a263b79de0e5793b8db2348a7ae))
|
||||
* ✨ 自助充值 ([e621532](https://github.com/nsnail/NetAdmin/commit/e62153289fd13c5588518a5ee7cfc05c799df6b9))
|
||||
* ✨ 作业增加请求地址显示查询 ([585f8f4](https://github.com/nsnail/NetAdmin/commit/585f8f4e43ae7fe0c9c387cc41f629f4f279740a))
|
||||
* ✨ select-filter badge icon ([#217](https://github.com/nsnail/NetAdmin/issues/217)) ([4d857f1](https://github.com/nsnail/NetAdmin/commit/4d857f1861b1256980e7cc59e2ab6a5f7d966da2))
|
||||
|
||||
* ✨ select-filter badge
|
||||
icon ([#217](https://github.com/nsnail/NetAdmin/issues/217)) ([4d857f1](https://github.com/nsnail/NetAdmin/commit/4d857f1861b1256980e7cc59e2ab6a5f7d966da2))
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* 🐛 按钮文字提示 ([#227](https://github.com/nsnail/NetAdmin/issues/227)) ([c88c8d2](https://github.com/nsnail/NetAdmin/commit/c88c8d293d44f2707f3b5232e6a40a141af9981c))
|
||||
* 🐛
|
||||
按钮文字提示 ([#227](https://github.com/nsnail/NetAdmin/issues/227)) ([c88c8d2](https://github.com/nsnail/NetAdmin/commit/c88c8d293d44f2707f3b5232e6a40a141af9981c))
|
||||
* 🐛 初次访问时前端js错误 ([9b6e053](https://github.com/nsnail/NetAdmin/commit/9b6e053721c95cf5fbdfa11112892a51e047af59))
|
||||
* 🐛 档案管理空列表loading状态 ([ac4bb50](https://github.com/nsnail/NetAdmin/commit/ac4bb50b66034f9841ba2398a168ed746c673aea))
|
||||
* 🐛 导出界面报错 ([#213](https://github.com/nsnail/NetAdmin/issues/213)) ([ef2f0de](https://github.com/nsnail/NetAdmin/commit/ef2f0de095e314f34bec21c0a2ccdb51423a163b))
|
||||
* 🐛 导出文件的responseType ([#205](https://github.com/nsnail/NetAdmin/issues/205)) ([841a419](https://github.com/nsnail/NetAdmin/commit/841a4195e77aa96e3c6c72626c1add3f71a310aa))
|
||||
* 🐛
|
||||
导出界面报错 ([#213](https://github.com/nsnail/NetAdmin/issues/213)) ([ef2f0de](https://github.com/nsnail/NetAdmin/commit/ef2f0de095e314f34bec21c0a2ccdb51423a163b))
|
||||
* 🐛
|
||||
导出文件的responseType ([#205](https://github.com/nsnail/NetAdmin/issues/205)) ([841a419](https://github.com/nsnail/NetAdmin/commit/841a4195e77aa96e3c6c72626c1add3f71a310aa))
|
||||
* 🐛 个性主题色冲突 ([4e4a1d0](https://github.com/nsnail/NetAdmin/commit/4e4a1d0dff7f3698e9a9cfcf46368260cfd70cbd))
|
||||
* 🐛 前端警告 ([9c81ce6](https://github.com/nsnail/NetAdmin/commit/9c81ce6f9fe9573c33a99eb86fcf727ed0cbf9f0))
|
||||
* 🐛 请求日志批量插入,漏写了登录日志 ([#210](https://github.com/nsnail/NetAdmin/issues/210)) ([6c71c74](https://github.com/nsnail/NetAdmin/commit/6c71c74a27617c7d0530a5f6eaff650ecfd4eaec))
|
||||
* 🐛
|
||||
请求日志批量插入,漏写了登录日志 ([#210](https://github.com/nsnail/NetAdmin/issues/210)) ([6c71c74](https://github.com/nsnail/NetAdmin/commit/6c71c74a27617c7d0530a5f6eaff650ecfd4eaec))
|
||||
* 🐛 文件下载编码匹配 ([541c061](https://github.com/nsnail/NetAdmin/commit/541c0616bf5d405a62eac0c5eb967f0ddd4c5139))
|
||||
* 🐛 修复一些样式问题 ([442a69f](https://github.com/nsnail/NetAdmin/commit/442a69f90de179539f78c01d967572f83bd2eff8))
|
||||
* 🐛 样式问题 ([377c28c](https://github.com/nsnail/NetAdmin/commit/377c28c57049d453108f9da41b168e1fdb64d7e1))
|
||||
* 🐛 用户选择器报错 ([#220](https://github.com/nsnail/NetAdmin/issues/220)) ([71bfdaa](https://github.com/nsnail/NetAdmin/commit/71bfdaafa8176cf686b03244ee758de058080a71))
|
||||
* 🐛
|
||||
用户选择器报错 ([#220](https://github.com/nsnail/NetAdmin/issues/220)) ([71bfdaa](https://github.com/nsnail/NetAdmin/commit/71bfdaafa8176cf686b03244ee758de058080a71))
|
||||
* 🐛 种子数据 ([f6aee1b](https://github.com/nsnail/NetAdmin/commit/f6aee1be0f05113cf1b798e23a176c02686348b5))
|
||||
* 🐛 build err ([60e8451](https://github.com/nsnail/NetAdmin/commit/60e8451048a42cfa47d7c82b038eb8db7e017697))
|
||||
* 🐛 build error ([278e10d](https://github.com/nsnail/NetAdmin/commit/278e10d8fc750eeb0933a86b64d69f5cc7e0b1cb))
|
||||
* 🐛 editUser ([ef2a0c3](https://github.com/nsnail/NetAdmin/commit/ef2a0c3280532ac24889279e4780a1b1a2561a6b))
|
||||
* 🐛 idd ([#208](https://github.com/nsnail/NetAdmin/issues/208)) ([4e9f605](https://github.com/nsnail/NetAdmin/commit/4e9f605ea2cc6fe394068cfea5638e51920b9096))
|
||||
* 🐛
|
||||
idd ([#208](https://github.com/nsnail/NetAdmin/issues/208)) ([4e9f605](https://github.com/nsnail/NetAdmin/commit/4e9f605ea2cc6fe394068cfea5638e51920b9096))
|
||||
* 🐛 scTable dataChanged ([52e7f93](https://github.com/nsnail/NetAdmin/commit/52e7f93cc2de967a7a90448813b4c1030996d170))
|
||||
* 🐛 version 条件重复指定 ([01058ba](https://github.com/nsnail/NetAdmin/commit/01058ba7288bcc645f66de2f78e1d659d55333cf))
|
||||
* 🐛 version lock ([4eecc0b](https://github.com/nsnail/NetAdmin/commit/4eecc0b4ce09f620f83109949e4c2b67b7f8ba90))
|
||||
@@ -54,233 +62,302 @@ All notable changes to this project will be documented in this file. See [standa
|
||||
|
||||
### [2.3.1](https://github.com/nsnail/NetAdmin/compare/v2.1.0...v2.3.1) (2024-12-13)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* ✨ 菜单复制 ([#214](https://github.com/nsnail/NetAdmin/issues/214)) ([81d9b0b](https://github.com/nsnail/NetAdmin/commit/81d9b0b3bb280661ceffa61aa6e9d612fb7ec52c))
|
||||
* ✨
|
||||
菜单复制 ([#214](https://github.com/nsnail/NetAdmin/issues/214)) ([81d9b0b](https://github.com/nsnail/NetAdmin/commit/81d9b0b3bb280661ceffa61aa6e9d612fb7ec52c))
|
||||
* ✨ 分组统计功能 ([0b036e9](https://github.com/nsnail/NetAdmin/commit/0b036e9d67ffdf7a07c772606009f02744e6a3c3))
|
||||
* ✨ 框架代码同步 ([098cfc1](https://github.com/nsnail/NetAdmin/commit/098cfc135e781a0cf172cd1289e5e871c7a76419))
|
||||
* ✨ 框架代码同步 ([7256626](https://github.com/nsnail/NetAdmin/commit/725662693b7b47f6fae4c1917dd8d80220c7640a))
|
||||
* ✨ 文档管理 ([#221](https://github.com/nsnail/NetAdmin/issues/221)) ([7ed3040](https://github.com/nsnail/NetAdmin/commit/7ed30406c9f721a12f0b756ec8884a1882242b93))
|
||||
* ✨ select-filter badge icon ([#217](https://github.com/nsnail/NetAdmin/issues/217)) ([4d857f1](https://github.com/nsnail/NetAdmin/commit/4d857f1861b1256980e7cc59e2ab6a5f7d966da2))
|
||||
|
||||
* ✨
|
||||
文档管理 ([#221](https://github.com/nsnail/NetAdmin/issues/221)) ([7ed3040](https://github.com/nsnail/NetAdmin/commit/7ed30406c9f721a12f0b756ec8884a1882242b93))
|
||||
* ✨ select-filter badge
|
||||
icon ([#217](https://github.com/nsnail/NetAdmin/issues/217)) ([4d857f1](https://github.com/nsnail/NetAdmin/commit/4d857f1861b1256980e7cc59e2ab6a5f7d966da2))
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* 🐛 按钮文字提示 ([#227](https://github.com/nsnail/NetAdmin/issues/227)) ([c88c8d2](https://github.com/nsnail/NetAdmin/commit/c88c8d293d44f2707f3b5232e6a40a141af9981c))
|
||||
* 🐛 导出界面报错 ([#213](https://github.com/nsnail/NetAdmin/issues/213)) ([ef2f0de](https://github.com/nsnail/NetAdmin/commit/ef2f0de095e314f34bec21c0a2ccdb51423a163b))
|
||||
* 🐛 导出文件的responseType ([#205](https://github.com/nsnail/NetAdmin/issues/205)) ([841a419](https://github.com/nsnail/NetAdmin/commit/841a4195e77aa96e3c6c72626c1add3f71a310aa))
|
||||
* 🐛
|
||||
按钮文字提示 ([#227](https://github.com/nsnail/NetAdmin/issues/227)) ([c88c8d2](https://github.com/nsnail/NetAdmin/commit/c88c8d293d44f2707f3b5232e6a40a141af9981c))
|
||||
* 🐛
|
||||
导出界面报错 ([#213](https://github.com/nsnail/NetAdmin/issues/213)) ([ef2f0de](https://github.com/nsnail/NetAdmin/commit/ef2f0de095e314f34bec21c0a2ccdb51423a163b))
|
||||
* 🐛
|
||||
导出文件的responseType ([#205](https://github.com/nsnail/NetAdmin/issues/205)) ([841a419](https://github.com/nsnail/NetAdmin/commit/841a4195e77aa96e3c6c72626c1add3f71a310aa))
|
||||
* 🐛 个性主题色冲突 ([4e4a1d0](https://github.com/nsnail/NetAdmin/commit/4e4a1d0dff7f3698e9a9cfcf46368260cfd70cbd))
|
||||
* 🐛 请求日志批量插入,漏写了登录日志 ([#210](https://github.com/nsnail/NetAdmin/issues/210)) ([6c71c74](https://github.com/nsnail/NetAdmin/commit/6c71c74a27617c7d0530a5f6eaff650ecfd4eaec))
|
||||
* 🐛
|
||||
请求日志批量插入,漏写了登录日志 ([#210](https://github.com/nsnail/NetAdmin/issues/210)) ([6c71c74](https://github.com/nsnail/NetAdmin/commit/6c71c74a27617c7d0530a5f6eaff650ecfd4eaec))
|
||||
* 🐛 修复一些样式问题 ([442a69f](https://github.com/nsnail/NetAdmin/commit/442a69f90de179539f78c01d967572f83bd2eff8))
|
||||
* 🐛 用户选择器报错 ([#220](https://github.com/nsnail/NetAdmin/issues/220)) ([71bfdaa](https://github.com/nsnail/NetAdmin/commit/71bfdaafa8176cf686b03244ee758de058080a71))
|
||||
* 🐛
|
||||
用户选择器报错 ([#220](https://github.com/nsnail/NetAdmin/issues/220)) ([71bfdaa](https://github.com/nsnail/NetAdmin/commit/71bfdaafa8176cf686b03244ee758de058080a71))
|
||||
* 🐛 editUser ([ef2a0c3](https://github.com/nsnail/NetAdmin/commit/ef2a0c3280532ac24889279e4780a1b1a2561a6b))
|
||||
* 🐛 idd ([#208](https://github.com/nsnail/NetAdmin/issues/208)) ([4e9f605](https://github.com/nsnail/NetAdmin/commit/4e9f605ea2cc6fe394068cfea5638e51920b9096))
|
||||
* 🐛
|
||||
idd ([#208](https://github.com/nsnail/NetAdmin/issues/208)) ([4e9f605](https://github.com/nsnail/NetAdmin/commit/4e9f605ea2cc6fe394068cfea5638e51920b9096))
|
||||
* 🐛 version 条件重复指定 ([01058ba](https://github.com/nsnail/NetAdmin/commit/01058ba7288bcc645f66de2f78e1d659d55333cf))
|
||||
* 🐛 version lock ([4eecc0b](https://github.com/nsnail/NetAdmin/commit/4eecc0b4ce09f620f83109949e4c2b67b7f8ba90))
|
||||
|
||||
## [2.3.0](https://github.com/nsnail/NetAdmin/compare/v2.1.0...v2.3.0) (2024-12-12)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* ✨ 菜单复制 ([#214](https://github.com/nsnail/NetAdmin/issues/214)) ([81d9b0b](https://github.com/nsnail/NetAdmin/commit/81d9b0b3bb280661ceffa61aa6e9d612fb7ec52c))
|
||||
* ✨
|
||||
菜单复制 ([#214](https://github.com/nsnail/NetAdmin/issues/214)) ([81d9b0b](https://github.com/nsnail/NetAdmin/commit/81d9b0b3bb280661ceffa61aa6e9d612fb7ec52c))
|
||||
* ✨ 分组统计功能 ([0b036e9](https://github.com/nsnail/NetAdmin/commit/0b036e9d67ffdf7a07c772606009f02744e6a3c3))
|
||||
* ✨ 框架代码同步 ([098cfc1](https://github.com/nsnail/NetAdmin/commit/098cfc135e781a0cf172cd1289e5e871c7a76419))
|
||||
* ✨ 框架代码同步 ([7256626](https://github.com/nsnail/NetAdmin/commit/725662693b7b47f6fae4c1917dd8d80220c7640a))
|
||||
* ✨ 文档管理 ([#221](https://github.com/nsnail/NetAdmin/issues/221)) ([7ed3040](https://github.com/nsnail/NetAdmin/commit/7ed30406c9f721a12f0b756ec8884a1882242b93))
|
||||
* ✨ select-filter badge icon ([#217](https://github.com/nsnail/NetAdmin/issues/217)) ([4d857f1](https://github.com/nsnail/NetAdmin/commit/4d857f1861b1256980e7cc59e2ab6a5f7d966da2))
|
||||
|
||||
* ✨
|
||||
文档管理 ([#221](https://github.com/nsnail/NetAdmin/issues/221)) ([7ed3040](https://github.com/nsnail/NetAdmin/commit/7ed30406c9f721a12f0b756ec8884a1882242b93))
|
||||
* ✨ select-filter badge
|
||||
icon ([#217](https://github.com/nsnail/NetAdmin/issues/217)) ([4d857f1](https://github.com/nsnail/NetAdmin/commit/4d857f1861b1256980e7cc59e2ab6a5f7d966da2))
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* 🐛 按钮文字提示 ([#227](https://github.com/nsnail/NetAdmin/issues/227)) ([c88c8d2](https://github.com/nsnail/NetAdmin/commit/c88c8d293d44f2707f3b5232e6a40a141af9981c))
|
||||
* 🐛 导出界面报错 ([#213](https://github.com/nsnail/NetAdmin/issues/213)) ([ef2f0de](https://github.com/nsnail/NetAdmin/commit/ef2f0de095e314f34bec21c0a2ccdb51423a163b))
|
||||
* 🐛 导出文件的responseType ([#205](https://github.com/nsnail/NetAdmin/issues/205)) ([841a419](https://github.com/nsnail/NetAdmin/commit/841a4195e77aa96e3c6c72626c1add3f71a310aa))
|
||||
* 🐛
|
||||
按钮文字提示 ([#227](https://github.com/nsnail/NetAdmin/issues/227)) ([c88c8d2](https://github.com/nsnail/NetAdmin/commit/c88c8d293d44f2707f3b5232e6a40a141af9981c))
|
||||
* 🐛
|
||||
导出界面报错 ([#213](https://github.com/nsnail/NetAdmin/issues/213)) ([ef2f0de](https://github.com/nsnail/NetAdmin/commit/ef2f0de095e314f34bec21c0a2ccdb51423a163b))
|
||||
* 🐛
|
||||
导出文件的responseType ([#205](https://github.com/nsnail/NetAdmin/issues/205)) ([841a419](https://github.com/nsnail/NetAdmin/commit/841a4195e77aa96e3c6c72626c1add3f71a310aa))
|
||||
* 🐛 个性主题色冲突 ([4e4a1d0](https://github.com/nsnail/NetAdmin/commit/4e4a1d0dff7f3698e9a9cfcf46368260cfd70cbd))
|
||||
* 🐛 请求日志批量插入,漏写了登录日志 ([#210](https://github.com/nsnail/NetAdmin/issues/210)) ([6c71c74](https://github.com/nsnail/NetAdmin/commit/6c71c74a27617c7d0530a5f6eaff650ecfd4eaec))
|
||||
* 🐛 用户选择器报错 ([#220](https://github.com/nsnail/NetAdmin/issues/220)) ([71bfdaa](https://github.com/nsnail/NetAdmin/commit/71bfdaafa8176cf686b03244ee758de058080a71))
|
||||
* 🐛
|
||||
请求日志批量插入,漏写了登录日志 ([#210](https://github.com/nsnail/NetAdmin/issues/210)) ([6c71c74](https://github.com/nsnail/NetAdmin/commit/6c71c74a27617c7d0530a5f6eaff650ecfd4eaec))
|
||||
* 🐛
|
||||
用户选择器报错 ([#220](https://github.com/nsnail/NetAdmin/issues/220)) ([71bfdaa](https://github.com/nsnail/NetAdmin/commit/71bfdaafa8176cf686b03244ee758de058080a71))
|
||||
* 🐛 editUser ([ef2a0c3](https://github.com/nsnail/NetAdmin/commit/ef2a0c3280532ac24889279e4780a1b1a2561a6b))
|
||||
* 🐛 idd ([#208](https://github.com/nsnail/NetAdmin/issues/208)) ([4e9f605](https://github.com/nsnail/NetAdmin/commit/4e9f605ea2cc6fe394068cfea5638e51920b9096))
|
||||
* 🐛
|
||||
idd ([#208](https://github.com/nsnail/NetAdmin/issues/208)) ([4e9f605](https://github.com/nsnail/NetAdmin/commit/4e9f605ea2cc6fe394068cfea5638e51920b9096))
|
||||
* 🐛 version 条件重复指定 ([01058ba](https://github.com/nsnail/NetAdmin/commit/01058ba7288bcc645f66de2f78e1d659d55333cf))
|
||||
* 🐛 version lock ([4eecc0b](https://github.com/nsnail/NetAdmin/commit/4eecc0b4ce09f620f83109949e4c2b67b7f8ba90))
|
||||
|
||||
### [2.2.1](https://github.com/nsnail/NetAdmin/compare/v2.1.0...v2.2.1) (2024-12-04)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* ✨ 菜单复制 ([#214](https://github.com/nsnail/NetAdmin/issues/214)) ([81d9b0b](https://github.com/nsnail/NetAdmin/commit/81d9b0b3bb280661ceffa61aa6e9d612fb7ec52c))
|
||||
* ✨ 文档管理 ([#221](https://github.com/nsnail/NetAdmin/issues/221)) ([7ed3040](https://github.com/nsnail/NetAdmin/commit/7ed30406c9f721a12f0b756ec8884a1882242b93))
|
||||
* ✨ select-filter badge icon ([#217](https://github.com/nsnail/NetAdmin/issues/217)) ([4d857f1](https://github.com/nsnail/NetAdmin/commit/4d857f1861b1256980e7cc59e2ab6a5f7d966da2))
|
||||
|
||||
* ✨
|
||||
菜单复制 ([#214](https://github.com/nsnail/NetAdmin/issues/214)) ([81d9b0b](https://github.com/nsnail/NetAdmin/commit/81d9b0b3bb280661ceffa61aa6e9d612fb7ec52c))
|
||||
* ✨
|
||||
文档管理 ([#221](https://github.com/nsnail/NetAdmin/issues/221)) ([7ed3040](https://github.com/nsnail/NetAdmin/commit/7ed30406c9f721a12f0b756ec8884a1882242b93))
|
||||
* ✨ select-filter badge
|
||||
icon ([#217](https://github.com/nsnail/NetAdmin/issues/217)) ([4d857f1](https://github.com/nsnail/NetAdmin/commit/4d857f1861b1256980e7cc59e2ab6a5f7d966da2))
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* 🐛 按钮文字提示 ([#227](https://github.com/nsnail/NetAdmin/issues/227)) ([c88c8d2](https://github.com/nsnail/NetAdmin/commit/c88c8d293d44f2707f3b5232e6a40a141af9981c))
|
||||
* 🐛 导出界面报错 ([#213](https://github.com/nsnail/NetAdmin/issues/213)) ([ef2f0de](https://github.com/nsnail/NetAdmin/commit/ef2f0de095e314f34bec21c0a2ccdb51423a163b))
|
||||
* 🐛 导出文件的responseType ([#205](https://github.com/nsnail/NetAdmin/issues/205)) ([841a419](https://github.com/nsnail/NetAdmin/commit/841a4195e77aa96e3c6c72626c1add3f71a310aa))
|
||||
* 🐛 请求日志批量插入,漏写了登录日志 ([#210](https://github.com/nsnail/NetAdmin/issues/210)) ([6c71c74](https://github.com/nsnail/NetAdmin/commit/6c71c74a27617c7d0530a5f6eaff650ecfd4eaec))
|
||||
* 🐛 用户选择器报错 ([#220](https://github.com/nsnail/NetAdmin/issues/220)) ([71bfdaa](https://github.com/nsnail/NetAdmin/commit/71bfdaafa8176cf686b03244ee758de058080a71))
|
||||
* 🐛
|
||||
按钮文字提示 ([#227](https://github.com/nsnail/NetAdmin/issues/227)) ([c88c8d2](https://github.com/nsnail/NetAdmin/commit/c88c8d293d44f2707f3b5232e6a40a141af9981c))
|
||||
* 🐛
|
||||
导出界面报错 ([#213](https://github.com/nsnail/NetAdmin/issues/213)) ([ef2f0de](https://github.com/nsnail/NetAdmin/commit/ef2f0de095e314f34bec21c0a2ccdb51423a163b))
|
||||
* 🐛
|
||||
导出文件的responseType ([#205](https://github.com/nsnail/NetAdmin/issues/205)) ([841a419](https://github.com/nsnail/NetAdmin/commit/841a4195e77aa96e3c6c72626c1add3f71a310aa))
|
||||
* 🐛
|
||||
请求日志批量插入,漏写了登录日志 ([#210](https://github.com/nsnail/NetAdmin/issues/210)) ([6c71c74](https://github.com/nsnail/NetAdmin/commit/6c71c74a27617c7d0530a5f6eaff650ecfd4eaec))
|
||||
* 🐛
|
||||
用户选择器报错 ([#220](https://github.com/nsnail/NetAdmin/issues/220)) ([71bfdaa](https://github.com/nsnail/NetAdmin/commit/71bfdaafa8176cf686b03244ee758de058080a71))
|
||||
* 🐛 editUser ([ef2a0c3](https://github.com/nsnail/NetAdmin/commit/ef2a0c3280532ac24889279e4780a1b1a2561a6b))
|
||||
* 🐛 idd ([#208](https://github.com/nsnail/NetAdmin/issues/208)) ([4e9f605](https://github.com/nsnail/NetAdmin/commit/4e9f605ea2cc6fe394068cfea5638e51920b9096))
|
||||
* 🐛
|
||||
idd ([#208](https://github.com/nsnail/NetAdmin/issues/208)) ([4e9f605](https://github.com/nsnail/NetAdmin/commit/4e9f605ea2cc6fe394068cfea5638e51920b9096))
|
||||
* 🐛 version 条件重复指定 ([01058ba](https://github.com/nsnail/NetAdmin/commit/01058ba7288bcc645f66de2f78e1d659d55333cf))
|
||||
* 🐛 version lock ([4eecc0b](https://github.com/nsnail/NetAdmin/commit/4eecc0b4ce09f620f83109949e4c2b67b7f8ba90))
|
||||
|
||||
## [2.2.0](https://github.com/nsnail/NetAdmin/compare/v2.1.0...v2.2.0) (2024-11-27)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* ✨ 菜单复制 ([#214](https://github.com/nsnail/NetAdmin/issues/214)) ([81d9b0b](https://github.com/nsnail/NetAdmin/commit/81d9b0b3bb280661ceffa61aa6e9d612fb7ec52c))
|
||||
* ✨ 文档管理 ([#221](https://github.com/nsnail/NetAdmin/issues/221)) ([7ed3040](https://github.com/nsnail/NetAdmin/commit/7ed30406c9f721a12f0b756ec8884a1882242b93))
|
||||
* ✨ select-filter badge icon ([#217](https://github.com/nsnail/NetAdmin/issues/217)) ([4d857f1](https://github.com/nsnail/NetAdmin/commit/4d857f1861b1256980e7cc59e2ab6a5f7d966da2))
|
||||
|
||||
* ✨
|
||||
菜单复制 ([#214](https://github.com/nsnail/NetAdmin/issues/214)) ([81d9b0b](https://github.com/nsnail/NetAdmin/commit/81d9b0b3bb280661ceffa61aa6e9d612fb7ec52c))
|
||||
* ✨
|
||||
文档管理 ([#221](https://github.com/nsnail/NetAdmin/issues/221)) ([7ed3040](https://github.com/nsnail/NetAdmin/commit/7ed30406c9f721a12f0b756ec8884a1882242b93))
|
||||
* ✨ select-filter badge
|
||||
icon ([#217](https://github.com/nsnail/NetAdmin/issues/217)) ([4d857f1](https://github.com/nsnail/NetAdmin/commit/4d857f1861b1256980e7cc59e2ab6a5f7d966da2))
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* 🐛 导出界面报错 ([#213](https://github.com/nsnail/NetAdmin/issues/213)) ([ef2f0de](https://github.com/nsnail/NetAdmin/commit/ef2f0de095e314f34bec21c0a2ccdb51423a163b))
|
||||
* 🐛 导出文件的responseType ([#205](https://github.com/nsnail/NetAdmin/issues/205)) ([841a419](https://github.com/nsnail/NetAdmin/commit/841a4195e77aa96e3c6c72626c1add3f71a310aa))
|
||||
* 🐛 请求日志批量插入,漏写了登录日志 ([#210](https://github.com/nsnail/NetAdmin/issues/210)) ([6c71c74](https://github.com/nsnail/NetAdmin/commit/6c71c74a27617c7d0530a5f6eaff650ecfd4eaec))
|
||||
* 🐛 用户选择器报错 ([#220](https://github.com/nsnail/NetAdmin/issues/220)) ([71bfdaa](https://github.com/nsnail/NetAdmin/commit/71bfdaafa8176cf686b03244ee758de058080a71))
|
||||
* 🐛 idd ([#208](https://github.com/nsnail/NetAdmin/issues/208)) ([4e9f605](https://github.com/nsnail/NetAdmin/commit/4e9f605ea2cc6fe394068cfea5638e51920b9096))
|
||||
* 🐛
|
||||
导出界面报错 ([#213](https://github.com/nsnail/NetAdmin/issues/213)) ([ef2f0de](https://github.com/nsnail/NetAdmin/commit/ef2f0de095e314f34bec21c0a2ccdb51423a163b))
|
||||
* 🐛
|
||||
导出文件的responseType ([#205](https://github.com/nsnail/NetAdmin/issues/205)) ([841a419](https://github.com/nsnail/NetAdmin/commit/841a4195e77aa96e3c6c72626c1add3f71a310aa))
|
||||
* 🐛
|
||||
请求日志批量插入,漏写了登录日志 ([#210](https://github.com/nsnail/NetAdmin/issues/210)) ([6c71c74](https://github.com/nsnail/NetAdmin/commit/6c71c74a27617c7d0530a5f6eaff650ecfd4eaec))
|
||||
* 🐛
|
||||
用户选择器报错 ([#220](https://github.com/nsnail/NetAdmin/issues/220)) ([71bfdaa](https://github.com/nsnail/NetAdmin/commit/71bfdaafa8176cf686b03244ee758de058080a71))
|
||||
* 🐛
|
||||
idd ([#208](https://github.com/nsnail/NetAdmin/issues/208)) ([4e9f605](https://github.com/nsnail/NetAdmin/commit/4e9f605ea2cc6fe394068cfea5638e51920b9096))
|
||||
|
||||
## [2.1.0](https://github.com/nsnail/NetAdmin/compare/v2.0.0...v2.1.0) (2024-11-15)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* ✨ 首页仪表板自定义布局 ([#201](https://github.com/nsnail/NetAdmin/issues/201)) ([2f30028](https://github.com/nsnail/NetAdmin/commit/2f300285aa2afbfaea1fd9ffe299cc2badf98e0f))
|
||||
* ✨ 用户选择器 ([#189](https://github.com/nsnail/NetAdmin/issues/189)) ([8479f69](https://github.com/nsnail/NetAdmin/commit/8479f69bdccac93a497e039dd01e18333ec2bbdc))
|
||||
|
||||
* ✨
|
||||
首页仪表板自定义布局 ([#201](https://github.com/nsnail/NetAdmin/issues/201)) ([2f30028](https://github.com/nsnail/NetAdmin/commit/2f300285aa2afbfaea1fd9ffe299cc2badf98e0f))
|
||||
* ✨
|
||||
用户选择器 ([#189](https://github.com/nsnail/NetAdmin/issues/189)) ([8479f69](https://github.com/nsnail/NetAdmin/commit/8479f69bdccac93a497e039dd01e18333ec2bbdc))
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* 🐛 --el-color-primary 变量有闪烁现象 ([#194](https://github.com/nsnail/NetAdmin/issues/194)) ([26e3698](https://github.com/nsnail/NetAdmin/commit/26e3698f57a2986f3b727fa38f293ca40c89f3ab))
|
||||
* 🐛 404 ([#198](https://github.com/nsnail/NetAdmin/issues/198)) ([d8dbb28](https://github.com/nsnail/NetAdmin/commit/d8dbb28cfc8ad427062eb8d81be67cc25ded6fb6))
|
||||
* 🐛 module name ([#193](https://github.com/nsnail/NetAdmin/issues/193)) ([3069b8f](https://github.com/nsnail/NetAdmin/commit/3069b8fbc451c4c257becf0523ab6ea6cc9af7e2))
|
||||
* 🐛 --el-color-primary
|
||||
变量有闪烁现象 ([#194](https://github.com/nsnail/NetAdmin/issues/194)) ([26e3698](https://github.com/nsnail/NetAdmin/commit/26e3698f57a2986f3b727fa38f293ca40c89f3ab))
|
||||
* 🐛
|
||||
404 ([#198](https://github.com/nsnail/NetAdmin/issues/198)) ([d8dbb28](https://github.com/nsnail/NetAdmin/commit/d8dbb28cfc8ad427062eb8d81be67cc25ded6fb6))
|
||||
* 🐛 module
|
||||
name ([#193](https://github.com/nsnail/NetAdmin/issues/193)) ([3069b8f](https://github.com/nsnail/NetAdmin/commit/3069b8fbc451c4c257becf0523ab6ea6cc9af7e2))
|
||||
|
||||
## [2.0.0](https://github.com/nsnail/NetAdmin/compare/v1.6.0...v2.0.0) (2024-11-04)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* ✨ 查询过滤器保存 ([779d8e5](https://github.com/nsnail/NetAdmin/commit/779d8e511a84d2be91d74ea308c22b969d6963f3))
|
||||
* ✨ 框架代码同步 ([#173](https://github.com/nsnail/NetAdmin/issues/173)) ([c088492](https://github.com/nsnail/NetAdmin/commit/c088492cfabada198ad563e43278ab7e869029bc))
|
||||
* ✨ 框架代码同步 ([#178](https://github.com/nsnail/NetAdmin/issues/178)) ([58e4572](https://github.com/nsnail/NetAdmin/commit/58e4572723ba68700fb6414167cb27b03c864db1))
|
||||
|
||||
* ✨
|
||||
框架代码同步 ([#173](https://github.com/nsnail/NetAdmin/issues/173)) ([c088492](https://github.com/nsnail/NetAdmin/commit/c088492cfabada198ad563e43278ab7e869029bc))
|
||||
* ✨
|
||||
框架代码同步 ([#178](https://github.com/nsnail/NetAdmin/issues/178)) ([58e4572](https://github.com/nsnail/NetAdmin/commit/58e4572723ba68700fb6414167cb27b03c864db1))
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* 🐛 public const int SECS_CACHE_LOGIN_BY_USER_ID = 3600 * 24 * 30; // 秒:缓存时间-通过用户编号登录的用户信息 ([#179](https://github.com/nsnail/NetAdmin/issues/179)) ([000e3d6](https://github.com/nsnail/NetAdmin/commit/000e3d68a85eaee7758b4160d1d0ffa52aa4aae0))
|
||||
* 🐛 public const int SECS_CACHE_LOGIN_BY_USER_ID = 3600 * 24 * 30;
|
||||
秒:缓存时间-通过用户编号登录的用户信息 ([#179](https://github.com/nsnail/NetAdmin/issues/179)) ([000e3d6](https://github.com/nsnail/NetAdmin/commit/000e3d68a85eaee7758b4160d1d0ffa52aa4aae0))
|
||||
|
||||
## [1.6.0](https://github.com/nsnail/NetAdmin/compare/v1.5.0...v1.6.0) (2024-08-12)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* ✨ 移除RedLocker,更改为自实现 ([#169](https://github.com/nsnail/NetAdmin/issues/169)) ([cd8ed67](https://github.com/nsnail/NetAdmin/commit/cd8ed674e0615b33fc0e025b9412c2f16d252f0f))
|
||||
|
||||
* ✨
|
||||
移除RedLocker,更改为自实现 ([#169](https://github.com/nsnail/NetAdmin/issues/169)) ([cd8ed67](https://github.com/nsnail/NetAdmin/commit/cd8ed674e0615b33fc0e025b9412c2f16d252f0f))
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* 🐛 站内信角标颜色 ([#167](https://github.com/nsnail/NetAdmin/issues/167)) ([e00c30c](https://github.com/nsnail/NetAdmin/commit/e00c30c96123769d8a9e6f30cc9a2c3e8099e34c))
|
||||
* 🐛 ip归属地查询接口地址更新 ([#168](https://github.com/nsnail/NetAdmin/issues/168)) ([4733ade](https://github.com/nsnail/NetAdmin/commit/4733adede5e8993f741e9b94541aafeb6a733859))
|
||||
* 🐛 ip显示问题 ([#166](https://github.com/nsnail/NetAdmin/issues/166)) ([6b63250](https://github.com/nsnail/NetAdmin/commit/6b6325003924b1605b610f759b2131c15013ffa0))
|
||||
* 🐛 trimSuffix ([#163](https://github.com/nsnail/NetAdmin/issues/163)) ([7c56c8d](https://github.com/nsnail/NetAdmin/commit/7c56c8d571d4f29fcb20f238893dbf61e5e538f0))
|
||||
* 🐛
|
||||
站内信角标颜色 ([#167](https://github.com/nsnail/NetAdmin/issues/167)) ([e00c30c](https://github.com/nsnail/NetAdmin/commit/e00c30c96123769d8a9e6f30cc9a2c3e8099e34c))
|
||||
* 🐛
|
||||
ip归属地查询接口地址更新 ([#168](https://github.com/nsnail/NetAdmin/issues/168)) ([4733ade](https://github.com/nsnail/NetAdmin/commit/4733adede5e8993f741e9b94541aafeb6a733859))
|
||||
* 🐛
|
||||
ip显示问题 ([#166](https://github.com/nsnail/NetAdmin/issues/166)) ([6b63250](https://github.com/nsnail/NetAdmin/commit/6b6325003924b1605b610f759b2131c15013ffa0))
|
||||
* 🐛
|
||||
trimSuffix ([#163](https://github.com/nsnail/NetAdmin/issues/163)) ([7c56c8d](https://github.com/nsnail/NetAdmin/commit/7c56c8d571d4f29fcb20f238893dbf61e5e538f0))
|
||||
|
||||
## [1.5.0](https://github.com/nsnail/NetAdmin/compare/v1.4.0...v1.5.0) (2024-07-26)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* ✨ 登录日志独立存储 ([#161](https://github.com/nsnail/NetAdmin/issues/161)) ([faaf5aa](https://github.com/nsnail/NetAdmin/commit/faaf5aa0fc5299633ca4f384d6287171bb241ff4))
|
||||
* ✨ 框架代码同步 ([#158](https://github.com/nsnail/NetAdmin/issues/158)) ([1a28e8d](https://github.com/nsnail/NetAdmin/commit/1a28e8d5a62aeab7e4fda5049b4f733a16480b67))
|
||||
* ✨ 请求日志增加TraceId ([#154](https://github.com/nsnail/NetAdmin/issues/154)) ([aaea283](https://github.com/nsnail/NetAdmin/commit/aaea28389a56566e055b6651cf48a89194a72cb7))
|
||||
* ✨ cron表达式的自然语言表达 ([#156](https://github.com/nsnail/NetAdmin/issues/156)) ([6d4ccf3](https://github.com/nsnail/NetAdmin/commit/6d4ccf344595e128a445f1cb7596a7a1c28fd4cd))
|
||||
* ✨ logoBar显示程序版本号 ([#153](https://github.com/nsnail/NetAdmin/issues/153)) ([be5b9a1](https://github.com/nsnail/NetAdmin/commit/be5b9a160d1f06cfdf36cea4e5eb95908523fed2))
|
||||
|
||||
* ✨
|
||||
登录日志独立存储 ([#161](https://github.com/nsnail/NetAdmin/issues/161)) ([faaf5aa](https://github.com/nsnail/NetAdmin/commit/faaf5aa0fc5299633ca4f384d6287171bb241ff4))
|
||||
* ✨
|
||||
框架代码同步 ([#158](https://github.com/nsnail/NetAdmin/issues/158)) ([1a28e8d](https://github.com/nsnail/NetAdmin/commit/1a28e8d5a62aeab7e4fda5049b4f733a16480b67))
|
||||
* ✨
|
||||
请求日志增加TraceId ([#154](https://github.com/nsnail/NetAdmin/issues/154)) ([aaea283](https://github.com/nsnail/NetAdmin/commit/aaea28389a56566e055b6651cf48a89194a72cb7))
|
||||
* ✨
|
||||
cron表达式的自然语言表达 ([#156](https://github.com/nsnail/NetAdmin/issues/156)) ([6d4ccf3](https://github.com/nsnail/NetAdmin/commit/6d4ccf344595e128a445f1cb7596a7a1c28fd4cd))
|
||||
* ✨
|
||||
logoBar显示程序版本号 ([#153](https://github.com/nsnail/NetAdmin/issues/153)) ([be5b9a1](https://github.com/nsnail/NetAdmin/commit/be5b9a160d1f06cfdf36cea4e5eb95908523fed2))
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* 🐛 error CS0117: 'Numbers' does not contain a definition for 'SECS_CACHE_DIC_CATALOG_CODE' ([#155](https://github.com/nsnail/NetAdmin/issues/155)) ([1733802](https://github.com/nsnail/NetAdmin/commit/1733802e02b7e69e4c8646f259da5098b87888f7))
|
||||
* 🐛 error CS0117: 'Numbers' does not contain a definition for '
|
||||
SECS_CACHE_DIC_CATALOG_CODE' ([#155](https://github.com/nsnail/NetAdmin/issues/155)) ([1733802](https://github.com/nsnail/NetAdmin/commit/1733802e02b7e69e4c8646f259da5098b87888f7))
|
||||
|
||||
## [1.4.0](https://github.com/nsnail/NetAdmin/compare/v1.3.0...v1.4.0) (2024-07-03)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* ✨ 框架代码同步 ([#150](https://github.com/nsnail/NetAdmin/issues/150)) ([e1b0030](https://github.com/nsnail/NetAdmin/commit/e1b0030193556fa0564ea059657b4b43c98085c2))
|
||||
* ✨
|
||||
框架代码同步 ([#150](https://github.com/nsnail/NetAdmin/issues/150)) ([e1b0030](https://github.com/nsnail/NetAdmin/commit/e1b0030193556fa0564ea059657b4b43c98085c2))
|
||||
|
||||
## [1.3.0](https://github.com/nsnail/NetAdmin/compare/v1.2.0...v1.3.0) (2024-06-24)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* ✨ 补充多语种文件 ([#146](https://github.com/nsnail/NetAdmin/issues/146)) ([1442e0a](https://github.com/nsnail/NetAdmin/commit/1442e0a37cb2f27d8ba7b77bed91feaa5d7b1fdd))
|
||||
* ✨ 更新实体增加sql过滤参数 ([#140](https://github.com/nsnail/NetAdmin/issues/140)) ([a3ab970](https://github.com/nsnail/NetAdmin/commit/a3ab97019dd1fc2267db987ade80fa6749e24e4d))
|
||||
* ✨ 框架代码同步 ([#139](https://github.com/nsnail/NetAdmin/issues/139)) ([608a1de](https://github.com/nsnail/NetAdmin/commit/608a1ded5c0e9987161444efd48597a687c693e1))
|
||||
* ✨ 框架代码同步 ([#144](https://github.com/nsnail/NetAdmin/issues/144)) ([ae2d1c4](https://github.com/nsnail/NetAdmin/commit/ae2d1c4932bf1229ea36d28d486beaee8de16d53))
|
||||
* ✨ 框架代码同步 ([#148](https://github.com/nsnail/NetAdmin/issues/148)) ([8bc8aa9](https://github.com/nsnail/NetAdmin/commit/8bc8aa960cdd1ed5036927bd508fce4c218618c7))
|
||||
* ✨ 前端版本更新器 ([#145](https://github.com/nsnail/NetAdmin/issues/145)) ([6100e9e](https://github.com/nsnail/NetAdmin/commit/6100e9e9c88005d6a2f3c2706ca750a6ad62d2c7))
|
||||
|
||||
* ✨
|
||||
补充多语种文件 ([#146](https://github.com/nsnail/NetAdmin/issues/146)) ([1442e0a](https://github.com/nsnail/NetAdmin/commit/1442e0a37cb2f27d8ba7b77bed91feaa5d7b1fdd))
|
||||
* ✨
|
||||
更新实体增加sql过滤参数 ([#140](https://github.com/nsnail/NetAdmin/issues/140)) ([a3ab970](https://github.com/nsnail/NetAdmin/commit/a3ab97019dd1fc2267db987ade80fa6749e24e4d))
|
||||
* ✨
|
||||
框架代码同步 ([#139](https://github.com/nsnail/NetAdmin/issues/139)) ([608a1de](https://github.com/nsnail/NetAdmin/commit/608a1ded5c0e9987161444efd48597a687c693e1))
|
||||
* ✨
|
||||
框架代码同步 ([#144](https://github.com/nsnail/NetAdmin/issues/144)) ([ae2d1c4](https://github.com/nsnail/NetAdmin/commit/ae2d1c4932bf1229ea36d28d486beaee8de16d53))
|
||||
* ✨
|
||||
框架代码同步 ([#148](https://github.com/nsnail/NetAdmin/issues/148)) ([8bc8aa9](https://github.com/nsnail/NetAdmin/commit/8bc8aa960cdd1ed5036927bd508fce4c218618c7))
|
||||
* ✨
|
||||
前端版本更新器 ([#145](https://github.com/nsnail/NetAdmin/issues/145)) ([6100e9e](https://github.com/nsnail/NetAdmin/commit/6100e9e9c88005d6a2f3c2706ca750a6ad62d2c7))
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* 🐛 补充多语种文件 ([#147](https://github.com/nsnail/NetAdmin/issues/147)) ([d00f0d2](https://github.com/nsnail/NetAdmin/commit/d00f0d2d9cc2243908a8b6979b9c4a5811b2a57e))
|
||||
* 🐛 操作日志不显示userName ([#141](https://github.com/nsnail/NetAdmin/issues/141)) ([705d027](https://github.com/nsnail/NetAdmin/commit/705d027da44af159d29db9c93e47b549317c793e))
|
||||
* 🐛
|
||||
补充多语种文件 ([#147](https://github.com/nsnail/NetAdmin/issues/147)) ([d00f0d2](https://github.com/nsnail/NetAdmin/commit/d00f0d2d9cc2243908a8b6979b9c4a5811b2a57e))
|
||||
* 🐛
|
||||
操作日志不显示userName ([#141](https://github.com/nsnail/NetAdmin/issues/141)) ([705d027](https://github.com/nsnail/NetAdmin/commit/705d027da44af159d29db9c93e47b549317c793e))
|
||||
|
||||
## [1.2.0](https://github.com/nsnail/NetAdmin/compare/v1.1.1...v1.2.0) (2024-06-06)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* ✨ 计划作业-上次执行耗时 ([#133](https://github.com/nsnail/NetAdmin/issues/133)) ([57b71e1](https://github.com/nsnail/NetAdmin/commit/57b71e1354ab8b0be995b5f563dd8c3fb7965d5f))
|
||||
* ✨ 框架代码同步 ([#129](https://github.com/nsnail/NetAdmin/issues/129)) ([b01b8b2](https://github.com/nsnail/NetAdmin/commit/b01b8b24ba574c08ba5605e103ff2ccf15e5830a))
|
||||
* ✨ 框架代码同步 ([#130](https://github.com/nsnail/NetAdmin/issues/130)) ([5edcf63](https://github.com/nsnail/NetAdmin/commit/5edcf63e24f6b13f5515e01ee8cf120b1a814d40))
|
||||
* ✨ 默认头像根据用户名绘制svg ([#132](https://github.com/nsnail/NetAdmin/issues/132)) ([127f6e9](https://github.com/nsnail/NetAdmin/commit/127f6e9f6c8c12974e5340e9697281250737bed3))
|
||||
* ✨ 手动执行计划作业 ([#122](https://github.com/nsnail/NetAdmin/issues/122)) ([3b83361](https://github.com/nsnail/NetAdmin/commit/3b8336105a908ba6bc300bec6ac4f49747ea66e9))
|
||||
* ✨ 增强作业执行记录页面 ([#135](https://github.com/nsnail/NetAdmin/issues/135)) ([7ae473d](https://github.com/nsnail/NetAdmin/commit/7ae473d492b9ba60cbb1c355894917d14f5ffa8f))
|
||||
* ✨ naColId组件 ([#118](https://github.com/nsnail/NetAdmin/issues/118)) ([47e67dd](https://github.com/nsnail/NetAdmin/commit/47e67dd503dd0ba6818e8b798e41c62420363f58))
|
||||
* **frontend:** ✨ 手机端分页控件显示总条数 ([#124](https://github.com/nsnail/NetAdmin/issues/124)) ([e0d15f8](https://github.com/nsnail/NetAdmin/commit/e0d15f8039a74a9826a0395983960ab620308899))
|
||||
|
||||
* ✨
|
||||
计划作业-上次执行耗时 ([#133](https://github.com/nsnail/NetAdmin/issues/133)) ([57b71e1](https://github.com/nsnail/NetAdmin/commit/57b71e1354ab8b0be995b5f563dd8c3fb7965d5f))
|
||||
* ✨
|
||||
框架代码同步 ([#129](https://github.com/nsnail/NetAdmin/issues/129)) ([b01b8b2](https://github.com/nsnail/NetAdmin/commit/b01b8b24ba574c08ba5605e103ff2ccf15e5830a))
|
||||
* ✨
|
||||
框架代码同步 ([#130](https://github.com/nsnail/NetAdmin/issues/130)) ([5edcf63](https://github.com/nsnail/NetAdmin/commit/5edcf63e24f6b13f5515e01ee8cf120b1a814d40))
|
||||
* ✨
|
||||
默认头像根据用户名绘制svg ([#132](https://github.com/nsnail/NetAdmin/issues/132)) ([127f6e9](https://github.com/nsnail/NetAdmin/commit/127f6e9f6c8c12974e5340e9697281250737bed3))
|
||||
* ✨
|
||||
手动执行计划作业 ([#122](https://github.com/nsnail/NetAdmin/issues/122)) ([3b83361](https://github.com/nsnail/NetAdmin/commit/3b8336105a908ba6bc300bec6ac4f49747ea66e9))
|
||||
* ✨
|
||||
增强作业执行记录页面 ([#135](https://github.com/nsnail/NetAdmin/issues/135)) ([7ae473d](https://github.com/nsnail/NetAdmin/commit/7ae473d492b9ba60cbb1c355894917d14f5ffa8f))
|
||||
* ✨
|
||||
naColId组件 ([#118](https://github.com/nsnail/NetAdmin/issues/118)) ([47e67dd](https://github.com/nsnail/NetAdmin/commit/47e67dd503dd0ba6818e8b798e41c62420363f58))
|
||||
* **frontend:** ✨
|
||||
手机端分页控件显示总条数 ([#124](https://github.com/nsnail/NetAdmin/issues/124)) ([e0d15f8](https://github.com/nsnail/NetAdmin/commit/e0d15f8039a74a9826a0395983960ab620308899))
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* 🐛 字段顺序 ([#131](https://github.com/nsnail/NetAdmin/issues/131)) ([d1951db](https://github.com/nsnail/NetAdmin/commit/d1951dbcb5fa50a7ff308f6b6d554da5f791bcf2))
|
||||
* 🐛 字段长度 ([#134](https://github.com/nsnail/NetAdmin/issues/134)) ([c20a6c3](https://github.com/nsnail/NetAdmin/commit/c20a6c369d7b6d6dcfd07b3f3eaeab0fa309e766))
|
||||
* 🐛
|
||||
字段顺序 ([#131](https://github.com/nsnail/NetAdmin/issues/131)) ([d1951db](https://github.com/nsnail/NetAdmin/commit/d1951dbcb5fa50a7ff308f6b6d554da5f791bcf2))
|
||||
* 🐛
|
||||
字段长度 ([#134](https://github.com/nsnail/NetAdmin/issues/134)) ([c20a6c3](https://github.com/nsnail/NetAdmin/commit/c20a6c369d7b6d6dcfd07b3f3eaeab0fa309e766))
|
||||
* 🐛 take count ([c08ea62](https://github.com/nsnail/NetAdmin/commit/c08ea62064cc522d7cca9c90a5f15f23d833b6e3))
|
||||
* **backend:** 🐛 更新计划作业在sqlite数据库环境报错 ([#120](https://github.com/nsnail/NetAdmin/issues/120)) ([3152a8d](https://github.com/nsnail/NetAdmin/commit/3152a8d3e8054524470883c336fb6e93903a8426))
|
||||
* **backend:** 🐛
|
||||
更新计划作业在sqlite数据库环境报错 ([#120](https://github.com/nsnail/NetAdmin/issues/120)) ([3152a8d](https://github.com/nsnail/NetAdmin/commit/3152a8d3e8054524470883c336fb6e93903a8426))
|
||||
|
||||
### [1.1.1](https://github.com/nsnail/NetAdmin/compare/v1.1.0...v1.1.1) (2024-04-29)
|
||||
|
||||
## [1.1.0](https://github.com/nsnail/NetAdmin/compare/v1.0.0...v1.1.0) (2024-04-29)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* ✨ 版本更新日志组件 ([#96](https://github.com/nsnail/NetAdmin/issues/96)) ([a37acc4](https://github.com/nsnail/NetAdmin/commit/a37acc4b55c91d57d51c7fa079da8700530412a5))
|
||||
* ✨ 计划作业 ([#87](https://github.com/nsnail/NetAdmin/issues/87)) ([8293ec0](https://github.com/nsnail/NetAdmin/commit/8293ec0297875ebc9ad75cce9465bd587929c0bf))
|
||||
* ✨ 计划作业执行记录 ([#89](https://github.com/nsnail/NetAdmin/issues/89)) ([6f89015](https://github.com/nsnail/NetAdmin/commit/6f890151989ad733e35653933b7597eec478cc3b))
|
||||
* ✨ 将数据库结构同步和种子数据初始化作为命令行开关 ([#78](https://github.com/nsnail/NetAdmin/issues/78)) ([05ed3d3](https://github.com/nsnail/NetAdmin/commit/05ed3d3746aa274a0f88f7afadfea12a3c8a80ff))
|
||||
* ✨ 快捷启用/禁用用户 ([#91](https://github.com/nsnail/NetAdmin/issues/91)) ([6c2d167](https://github.com/nsnail/NetAdmin/commit/6c2d1676e45b9f1ecf3be3ae5a172db49b62a81d))
|
||||
* ✨ 前端表格高级筛选 ([#100](https://github.com/nsnail/NetAdmin/issues/100)) ([3847d6f](https://github.com/nsnail/NetAdmin/commit/3847d6fdbbd27efb53921bcc8374157f0da47155))
|
||||
* ✨ 日志管理独立出来、增加登录日志界面 ([#65](https://github.com/nsnail/NetAdmin/issues/65)) ([9134c4f](https://github.com/nsnail/NetAdmin/commit/9134c4fe01165a87ebc7e2cbd0a2abff3c9fb3ea))
|
||||
* ✨ 首页仪表面板 ([#103](https://github.com/nsnail/NetAdmin/issues/103)) ([149e1af](https://github.com/nsnail/NetAdmin/commit/149e1afa533b142a3666a325ec84a091d53c1840))
|
||||
* ✨ cron表达式选择器 ([#92](https://github.com/nsnail/NetAdmin/issues/92)) ([bde9fb1](https://github.com/nsnail/NetAdmin/commit/bde9fb1ea264bd0b786ac68d590691892d7ce067))
|
||||
|
||||
* ✨
|
||||
版本更新日志组件 ([#96](https://github.com/nsnail/NetAdmin/issues/96)) ([a37acc4](https://github.com/nsnail/NetAdmin/commit/a37acc4b55c91d57d51c7fa079da8700530412a5))
|
||||
* ✨
|
||||
计划作业 ([#87](https://github.com/nsnail/NetAdmin/issues/87)) ([8293ec0](https://github.com/nsnail/NetAdmin/commit/8293ec0297875ebc9ad75cce9465bd587929c0bf))
|
||||
* ✨
|
||||
计划作业执行记录 ([#89](https://github.com/nsnail/NetAdmin/issues/89)) ([6f89015](https://github.com/nsnail/NetAdmin/commit/6f890151989ad733e35653933b7597eec478cc3b))
|
||||
* ✨
|
||||
将数据库结构同步和种子数据初始化作为命令行开关 ([#78](https://github.com/nsnail/NetAdmin/issues/78)) ([05ed3d3](https://github.com/nsnail/NetAdmin/commit/05ed3d3746aa274a0f88f7afadfea12a3c8a80ff))
|
||||
* ✨
|
||||
快捷启用/禁用用户 ([#91](https://github.com/nsnail/NetAdmin/issues/91)) ([6c2d167](https://github.com/nsnail/NetAdmin/commit/6c2d1676e45b9f1ecf3be3ae5a172db49b62a81d))
|
||||
* ✨
|
||||
前端表格高级筛选 ([#100](https://github.com/nsnail/NetAdmin/issues/100)) ([3847d6f](https://github.com/nsnail/NetAdmin/commit/3847d6fdbbd27efb53921bcc8374157f0da47155))
|
||||
* ✨
|
||||
日志管理独立出来、增加登录日志界面 ([#65](https://github.com/nsnail/NetAdmin/issues/65)) ([9134c4f](https://github.com/nsnail/NetAdmin/commit/9134c4fe01165a87ebc7e2cbd0a2abff3c9fb3ea))
|
||||
* ✨
|
||||
首页仪表面板 ([#103](https://github.com/nsnail/NetAdmin/issues/103)) ([149e1af](https://github.com/nsnail/NetAdmin/commit/149e1afa533b142a3666a325ec84a091d53c1840))
|
||||
* ✨
|
||||
cron表达式选择器 ([#92](https://github.com/nsnail/NetAdmin/issues/92)) ([bde9fb1](https://github.com/nsnail/NetAdmin/commit/bde9fb1ea264bd0b786ac68d590691892d7ce067))
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* 🐛 'Numbers' does not contain a definition for 'CACHE_SECS_DEFAULT' ([#102](https://github.com/nsnail/NetAdmin/issues/102)) ([8f69c29](https://github.com/nsnail/NetAdmin/commit/8f69c2907be282b1b39f4a179badb11502aa2403))
|
||||
* 🐛 低版本jetbrains.resharper.globaltools搞乱了代码 ([#97](https://github.com/nsnail/NetAdmin/issues/97)) ([c117ddf](https://github.com/nsnail/NetAdmin/commit/c117ddfe7a433215b3449cdd6b19318a1f3cbf37))
|
||||
* 🐛 前端样式问题 ([#84](https://github.com/nsnail/NetAdmin/issues/84)) ([6615df3](https://github.com/nsnail/NetAdmin/commit/6615df339934f6d19880c9822b44d5305c2f2a75))
|
||||
* 🐛 请求日志客户端IP显示不正确 ([#60](https://github.com/nsnail/NetAdmin/issues/60)) ([ec698ce](https://github.com/nsnail/NetAdmin/commit/ec698ce4db49861eaaeb8bf5080764939e6d7231))
|
||||
* 🐛 时区问题 ([#107](https://github.com/nsnail/NetAdmin/issues/107)) ([59c85ce](https://github.com/nsnail/NetAdmin/commit/59c85cef217c121b36d52993b6b5a774fe22df9e))
|
||||
* 🐛 小问题 ([#76](https://github.com/nsnail/NetAdmin/issues/76)) ([52ddf27](https://github.com/nsnail/NetAdmin/commit/52ddf273c856d8f7e363ce23e5886b9eedf4604f))
|
||||
* 🐛 在弹窗界面中引用的列表组件,点击重置搜索条件按钮时,会关闭弹窗的bug ([#95](https://github.com/nsnail/NetAdmin/issues/95)) ([8fee14c](https://github.com/nsnail/NetAdmin/commit/8fee14cd6ebd86456956fc59bbb61c545faa1fdd))
|
||||
* 🐛 tinymce editor css 加载路径错误 ([#93](https://github.com/nsnail/NetAdmin/issues/93)) ([5fe7387](https://github.com/nsnail/NetAdmin/commit/5fe73878a2a53dc5e7e2dcbcbf22f91ffb4376dd))
|
||||
* 🐛 tinymce editor css 加载路径错误 ([#94](https://github.com/nsnail/NetAdmin/issues/94)) ([802251e](https://github.com/nsnail/NetAdmin/commit/802251e42347bfe4fa0bcb4867b615d7c03abf19))
|
||||
* 🐛 'Numbers' does not contain a definition for '
|
||||
CACHE_SECS_DEFAULT' ([#102](https://github.com/nsnail/NetAdmin/issues/102)) ([8f69c29](https://github.com/nsnail/NetAdmin/commit/8f69c2907be282b1b39f4a179badb11502aa2403))
|
||||
* 🐛
|
||||
低版本jetbrains.resharper.globaltools搞乱了代码 ([#97](https://github.com/nsnail/NetAdmin/issues/97)) ([c117ddf](https://github.com/nsnail/NetAdmin/commit/c117ddfe7a433215b3449cdd6b19318a1f3cbf37))
|
||||
* 🐛
|
||||
前端样式问题 ([#84](https://github.com/nsnail/NetAdmin/issues/84)) ([6615df3](https://github.com/nsnail/NetAdmin/commit/6615df339934f6d19880c9822b44d5305c2f2a75))
|
||||
* 🐛
|
||||
请求日志客户端IP显示不正确 ([#60](https://github.com/nsnail/NetAdmin/issues/60)) ([ec698ce](https://github.com/nsnail/NetAdmin/commit/ec698ce4db49861eaaeb8bf5080764939e6d7231))
|
||||
* 🐛
|
||||
时区问题 ([#107](https://github.com/nsnail/NetAdmin/issues/107)) ([59c85ce](https://github.com/nsnail/NetAdmin/commit/59c85cef217c121b36d52993b6b5a774fe22df9e))
|
||||
* 🐛
|
||||
小问题 ([#76](https://github.com/nsnail/NetAdmin/issues/76)) ([52ddf27](https://github.com/nsnail/NetAdmin/commit/52ddf273c856d8f7e363ce23e5886b9eedf4604f))
|
||||
* 🐛
|
||||
在弹窗界面中引用的列表组件,点击重置搜索条件按钮时,会关闭弹窗的bug ([#95](https://github.com/nsnail/NetAdmin/issues/95)) ([8fee14c](https://github.com/nsnail/NetAdmin/commit/8fee14cd6ebd86456956fc59bbb61c545faa1fdd))
|
||||
* 🐛 tinymce editor css
|
||||
加载路径错误 ([#93](https://github.com/nsnail/NetAdmin/issues/93)) ([5fe7387](https://github.com/nsnail/NetAdmin/commit/5fe73878a2a53dc5e7e2dcbcbf22f91ffb4376dd))
|
||||
* 🐛 tinymce editor css
|
||||
加载路径错误 ([#94](https://github.com/nsnail/NetAdmin/issues/94)) ([802251e](https://github.com/nsnail/NetAdmin/commit/802251e42347bfe4fa0bcb4867b615d7c03abf19))
|
||||
|
||||
## 1.0.0 (2023-11-17)
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
FROM mcr.microsoft.com/dotnet/aspnet:9.0.7 AS base
|
||||
FROM mcr.microsoft.com/dotnet/aspnet:9.0.8 AS base
|
||||
WORKDIR /app
|
||||
EXPOSE 8080
|
||||
RUN apt update
|
||||
|
@@ -16,18 +16,57 @@
|
||||
<s:String x:Key="/Default/CodeInspection/Highlighting/InspectionSeverities/=TooWideLocalVariableScope/@EntryIndexedValue">HINT</s:String>
|
||||
<s:String x:Key="/Default/CodeInspection/Highlighting/InspectionSeverities/=UnusedAutoPropertyAccessor_002EGlobal/@EntryIndexedValue">DO_NOT_SHOW</s:String>
|
||||
<s:String x:Key="/Default/CodeInspection/Highlighting/InspectionSeverities/=UnusedAutoPropertyAccessor_002ELocal/@EntryIndexedValue">DO_NOT_SHOW</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/INDENT_PREPROCESSOR_IF/@EntryValue">USUAL_INDENT</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/INDENT_PREPROCESSOR_OTHER/@EntryValue">USUAL_INDENT</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/INVOCABLE_DECLARATION_BRACES/@EntryValue">END_OF_LINE</s:String>
|
||||
|
||||
<!-- CodeStyle-->
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/KEEP_EXISTING_DECLARATION_PARENS_ARRANGEMENT/@EntryValue">False</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/KEEP_EXISTING_EMBEDDED_ARRANGEMENT/@EntryValue">False</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/KEEP_EXISTING_EXPR_MEMBER_ARRANGEMENT/@EntryValue">False</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/KEEP_EXISTING_INITIALIZER_ARRANGEMENT/@EntryValue">False</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/KEEP_EXISTING_INVOCATION_PARENS_ARRANGEMENT/@EntryValue">False</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/KEEP_EXISTING_LIST_PATTERNS_ARRANGEMENT/@EntryValue">False</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/KEEP_EXISTING_PRIMARY_CONSTRUCTOR_DECLARATION_PARENS_ARRANGEMENT/@EntryValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/KEEP_EXISTING_PROPERTY_PATTERNS_ARRANGEMENT/@EntryValue">False</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/KEEP_EXISTING_SWITCH_EXPRESSION_ARRANGEMENT/@EntryValue">False</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/KEEP_USER_LINEBREAKS/@EntryValue">False</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/PLACE_CONSTRUCTOR_INITIALIZER_ON_SAME_LINE/@EntryValue">False</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/PLACE_LINQ_INTO_ON_NEW_LINE/@EntryValue">False</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/PLACE_TYPE_CONSTRAINTS_ON_SAME_LINE/@EntryValue">False</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_AFTER_DECLARATION_LPAR/@EntryValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_AFTER_INVOCATION_LPAR/@EntryValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_BEFORE_BINARY_OPSIGN/@EntryValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_BEFORE_COMMA/@EntryValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_BEFORE_DECLARATION_RPAR/@EntryValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_BEFORE_EQ/@EntryValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_BEFORE_FIRST_METHOD_CALL/@EntryValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_BEFORE_FIRST_TYPE_PARAMETER_CONSTRAINT/@EntryValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_BEFORE_INVOCATION_RPAR/@EntryValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_BEFORE_LINQ_EXPRESSION/@EntryValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_BEFORE_PRIMARY_CONSTRUCTOR_DECLARATION_LPAR/@EntryValue">False</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_BEFORE_PRIMARY_CONSTRUCTOR_DECLARATION_RPAR/@EntryValue">False</s:Boolean>
|
||||
<s:Int64 x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/KEEP_BLANK_LINES_IN_CODE/@EntryValue">1</s:Int64>
|
||||
<s:Int64 x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/KEEP_BLANK_LINES_IN_DECLARATIONS/@EntryValue">1</s:Int64>
|
||||
<s:Int64 x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/MAX_FORMAL_PARAMETERS_ON_LINE/@EntryValue">1</s:Int64>
|
||||
<s:Int64 x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/MAX_INVOCATION_ARGUMENTS_ON_LINE/@EntryValue">10000</s:Int64>
|
||||
<s:Int64 x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/MAX_PRIMARY_CONSTRUCTOR_PARAMETERS_ON_LINE/@EntryValue">10000</s:Int64>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpCodeStyle/BRACES_FOR_FOR/@EntryValue">Required</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpCodeStyle/BRACES_FOR_FOREACH/@EntryValue">Required</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpCodeStyle/BRACES_FOR_IFELSE/@EntryValue">Required</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpCodeStyle/BRACES_FOR_WHILE/@EntryValue">Required</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/NESTED_TERNARY_STYLE/@EntryValue">EXPANDED</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/OTHER_BRACES/@EntryValue">END_OF_LINE</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/PLACE_ACCESSORHOLDER_ATTRIBUTE_ON_SAME_LINE_EX/@EntryValue">NEVER</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/PLACE_ACCESSOR_ATTRIBUTE_ON_SAME_LINE_EX/@EntryValue">NEVER</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/PLACE_FIELD_ATTRIBUTE_ON_SAME_LINE_EX/@EntryValue">NEVER</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/PLACE_RECORD_FIELD_ATTRIBUTE_ON_SAME_LINE_EX/@EntryValue">NEVER</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_ARGUMENTS_STYLE/@EntryValue">WRAP_IF_LONG</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_CHAINED_BINARY_EXPRESSIONS/@EntryValue">CHOP_IF_LONG</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_CHAINED_BINARY_PATTERNS/@EntryValue">CHOP_IF_LONG</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_CHAINED_METHOD_CALLS/@EntryValue">CHOP_IF_LONG</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_MULTIPLE_TYPE_PARAMEER_CONSTRAINTS_STYLE/@EntryValue">CHOP_ALWAYS</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_PARAMETERS_STYLE/@EntryValue">CHOP_IF_LONG</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=AD/@EntryIndexedValue">AD</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=AE/@EntryIndexedValue">AE</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=AF/@EntryIndexedValue">AF</s:String>
|
||||
@@ -262,6 +301,7 @@
|
||||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=UG/@EntryIndexedValue">UG</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=UM/@EntryIndexedValue">UM</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=US/@EntryIndexedValue">US</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=USDT/@EntryIndexedValue">USDT</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=UY/@EntryIndexedValue">UY</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=UZ/@EntryIndexedValue">UZ</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=VA/@EntryIndexedValue">VA</s:String>
|
||||
|
@@ -21,6 +21,7 @@ USDT
|
||||
以什么结束
|
||||
作业名称
|
||||
作业状态
|
||||
佣金收入
|
||||
信息
|
||||
倒序排序
|
||||
充值成功
|
||||
@@ -28,6 +29,7 @@ USDT
|
||||
全部数据
|
||||
公告
|
||||
共青团员
|
||||
内部错误
|
||||
出生证
|
||||
创建时间
|
||||
初中
|
||||
@@ -123,6 +125,7 @@ USDT
|
||||
登录日志导出
|
||||
硕士
|
||||
离异
|
||||
私信
|
||||
空闲
|
||||
站内信导出
|
||||
等于
|
||||
|
@@ -97,12 +97,12 @@
|
||||
"Type": 1,
|
||||
},
|
||||
{
|
||||
"Component": "sys/finance/order",
|
||||
"Component": "sys/finance/deposit",
|
||||
"Icon": "el-icon-shopping-cart",
|
||||
"Id": 690907673255944,
|
||||
"Name": "sys/finance/order",
|
||||
"Name": "sys/finance/deposit",
|
||||
"ParentId": 690906994118665,
|
||||
"Path": "/finance/order",
|
||||
"Path": "/finance/deposit",
|
||||
"Sort": 98,
|
||||
"Title": "自助充值",
|
||||
"Type": 1,
|
||||
|
@@ -1,15 +1,18 @@
|
||||
[
|
||||
{
|
||||
"Id": 370942943322181,
|
||||
"SelfDepositAllowed": true,
|
||||
},
|
||||
{
|
||||
"Id": 560217289236492,
|
||||
"OwnerDeptId": 372119301627909,
|
||||
"OwnerId": 370942943322181,
|
||||
"SelfDepositAllowed": true,
|
||||
},
|
||||
{
|
||||
"Id": 664362432344581,
|
||||
"OwnerDeptId": 372119301627909,
|
||||
"OwnerId": 370942943322181,
|
||||
"SelfDepositAllowed": true,
|
||||
}
|
||||
]
|
@@ -16,7 +16,7 @@
|
||||
<Rule Id="SA1006" Action="Warning"/> <!-- Preprocessor keywords should not be preceded by space -->
|
||||
<Rule Id="SA1007" Action="Warning"/> <!-- Operator keyword should be followed by space -->
|
||||
<Rule Id="SA1008" Action="None"/> <!-- Opening parenthesis should be spaced correctly -->
|
||||
<Rule Id="SA1009" Action="Warning"/> <!-- Closing parenthesis should be spaced correctly -->
|
||||
<Rule Id="SA1009" Action="None"/> <!-- Closing parenthesis should be spaced correctly -->
|
||||
<Rule Id="SA1010" Action="Warning"/> <!-- Opening square brackets should be spaced correctly -->
|
||||
<Rule Id="SA1011" Action="Warning"/> <!-- Closing square brackets should be spaced correctly -->
|
||||
<Rule Id="SA1012" Action="Warning"/> <!-- Opening braces should be spaced correctly -->
|
||||
@@ -56,7 +56,7 @@
|
||||
<Rule Id="SA1109" Action="Warning"/> <!-- Block statements should not contain embedded regions -->
|
||||
<Rule Id="SA1110"
|
||||
Action="Warning"/> <!-- Opening parenthesis or bracket should be on declaration line -->
|
||||
<Rule Id="SA1111" Action="Warning"/> <!-- Closing parenthesis should be on line of last parameter -->
|
||||
<Rule Id="SA1111" Action="None"/> <!-- Closing parenthesis should be on line of last parameter -->
|
||||
<Rule Id="SA1112"
|
||||
Action="Warning"/> <!-- Closing parenthesis should be on line of opening parenthesis -->
|
||||
<Rule Id="SA1113" Action="None"/> <!-- Comma should be on the same line as previous parameter -->
|
||||
|
26
scripts/fn_GetChannelDealer.sql
Normal file
26
scripts/fn_GetChannelDealer.sql
Normal file
@@ -0,0 +1,26 @@
|
||||
CREATE FUNCTION [RM].[fn_GetChannelDealer] (@UserId BIGINT) RETURNS TABLE AS RETURN (
|
||||
WITH [as_tree_cte] AS (
|
||||
SELECT
|
||||
0 AS cte_level,
|
||||
a.[Id],
|
||||
a.[OwnerId]
|
||||
FROM
|
||||
[RM].[Sys_UserInvite] a
|
||||
WHERE
|
||||
(a.[Id] = @UserId) UNION ALL
|
||||
SELECT
|
||||
wct1.cte_level + 1 AS cte_level,
|
||||
wct2.[Id],
|
||||
wct2.[OwnerId]
|
||||
FROM
|
||||
[as_tree_cte] wct1
|
||||
INNER JOIN [RM].[Sys_UserInvite] wct2 ON wct2.[Id] = wct1.[OwnerId]
|
||||
) SELECT TOP
|
||||
1 a.[Id] AS ChannelDealerId
|
||||
FROM
|
||||
[as_tree_cte] a
|
||||
WHERE
|
||||
a.id <> 370942943322181
|
||||
ORDER BY
|
||||
a.cte_level DESC
|
||||
)
|
@@ -6,7 +6,6 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
@@ -64,14 +63,12 @@ public sealed class Ln
|
||||
<#
|
||||
var xml = new XmlDocument();
|
||||
xml.Load("../assets/res/Ln.resx");
|
||||
foreach (XmlNode data in xml.SelectNodes("//root/data")!)
|
||||
{
|
||||
foreach (XmlNode data in xml.SelectNodes("//root/data")!) {
|
||||
#>
|
||||
/// <summary>
|
||||
/// <#= data.SelectSingleNode("value")?.InnerText #>
|
||||
/// </summary>
|
||||
public static string <#=
|
||||
data.Attributes!["name"].Value.Replace(" ", "_") #> => ResourceManager.GetString("<#= data.Attributes!["name"].Value #>", Culture);
|
||||
public static string <#= data.Attributes!["name"].Value.Replace(" ", "_") #> => ResourceManager.GetString("<#= data.Attributes!["name"].Value #>", Culture);
|
||||
<#
|
||||
}
|
||||
#>
|
||||
|
@@ -29,8 +29,7 @@
|
||||
</resheader>
|
||||
<#
|
||||
var regex = new Regex(@"^\d", RegexOptions.Compiled);
|
||||
foreach (var line in Directory.GetFiles("../assets/res/", "*.ln").SelectMany(x => File.ReadLines(x)).Distinct())
|
||||
{
|
||||
foreach (var line in Directory.GetFiles("../assets/res/", "*.ln").SelectMany(x => File.ReadLines(x)).Distinct()) {
|
||||
#>
|
||||
<data name="<#= regex.IsMatch(line) ? "_" : "" #><#= line #>" xml:space="preserve"><value><#= line #></value></data>
|
||||
<#
|
||||
|
@@ -11,12 +11,16 @@ public static class ISelectExtensions
|
||||
/// <summary>
|
||||
/// 附加其他过滤条件
|
||||
/// </summary>
|
||||
public static ISelect<T> AppendOtherFilters<T, TQuery>(this ISelect<T> me, QueryReq<TQuery> req)
|
||||
where TQuery : DataAbstraction, new()
|
||||
{
|
||||
public static ISelect<T> AppendOtherFilters<T, TQuery>(
|
||||
this ISelect<T> me
|
||||
, QueryReq<TQuery> req
|
||||
)
|
||||
where TQuery : DataAbstraction, new() {
|
||||
if (req.IgnoreOwner) {
|
||||
me = me.DisableGlobalFilter(Chars.FLG_FREE_SQL_GLOBAL_FILTER_SELF, Chars.FLG_FREE_SQL_GLOBAL_FILTER_DEPT
|
||||
, Chars.FLG_FREE_SQL_GLOBAL_FILTER_DEPT_WITH_CHILDREN, Chars.FLG_FREE_SQL_GLOBAL_FILTER_DEPT_WITH_SON);
|
||||
me = me.DisableGlobalFilter(
|
||||
Chars.FLG_FREE_SQL_GLOBAL_FILTER_SELF, Chars.FLG_FREE_SQL_GLOBAL_FILTER_DEPT, Chars.FLG_FREE_SQL_GLOBAL_FILTER_DEPT_WITH_CHILDREN
|
||||
, Chars.FLG_FREE_SQL_GLOBAL_FILTER_DEPT_WITH_SON
|
||||
);
|
||||
}
|
||||
|
||||
return me;
|
||||
|
@@ -8,11 +8,14 @@ public static class UnitOfWorkManagerExtensions
|
||||
/// <summary>
|
||||
/// 事务操作
|
||||
/// </summary>
|
||||
public static async Task AtomicOperateAsync(this UnitOfWorkManager me, Func<Task> handle, Func<Task> onErrorHandle = null)
|
||||
{
|
||||
var logger = LogHelper.Get<UnitOfWorkManager>();
|
||||
public static async Task AtomicOperateAsync(
|
||||
this UnitOfWorkManager me
|
||||
, Func<Task> handle
|
||||
, Func<Task> onErrorHandle = null
|
||||
) {
|
||||
var logger = LogHelper.Get<UnitOfWorkManager>();
|
||||
using var unitOfWork = me.Begin();
|
||||
var hashCode = unitOfWork.GetHashCode();
|
||||
var hashCode = unitOfWork.GetHashCode();
|
||||
try {
|
||||
#if DEBUG
|
||||
logger?.Debug($"{Ln.开始事务}: {hashCode}");
|
||||
|
@@ -8,7 +8,7 @@ namespace NetAdmin.Application.Repositories;
|
||||
/// </summary>
|
||||
public sealed class BasicRepository<TEntity, TPrimary>(IFreeSql fSql, UnitOfWorkManager uowManger, ContextUserToken userToken)
|
||||
: DefaultRepository<TEntity, TPrimary>(fSql, uowManger)
|
||||
where TEntity : EntityBase<TPrimary> //
|
||||
where TEntity : EntityBase<TPrimary>
|
||||
where TPrimary : IEquatable<TPrimary>
|
||||
{
|
||||
/// <summary>
|
||||
|
@@ -13,31 +13,33 @@ namespace NetAdmin.Application.Services;
|
||||
/// </remarks>
|
||||
public abstract class RedisService<TEntity, TPrimary, TLogger>(BasicRepository<TEntity, TPrimary> rpo)
|
||||
: RepositoryService<TEntity, TPrimary, TLogger>(rpo)
|
||||
where TEntity : EntityBase<TPrimary> //
|
||||
where TEntity : EntityBase<TPrimary>
|
||||
where TPrimary : IEquatable<TPrimary>
|
||||
{
|
||||
/// <summary>
|
||||
/// Redis Database
|
||||
/// </summary>
|
||||
protected IDatabase RedisDatabase { get; } //
|
||||
= App.GetService<IConnectionMultiplexer>()
|
||||
.GetDatabase(App.GetOptions<RedisOptions>().Instances.First(x => x.Name == Chars.FLG_REDIS_INSTANCE_DATA_CACHE).Database);
|
||||
protected IDatabase RedisDatabase { get; } = App
|
||||
.GetService<IConnectionMultiplexer>()
|
||||
.GetDatabase(App.GetOptions<RedisOptions>().Instances.First(x => x.Name == Chars.FLG_REDIS_INSTANCE_DATA_CACHE).Database);
|
||||
|
||||
/// <summary>
|
||||
/// 获取锁
|
||||
/// </summary>
|
||||
protected Task<RedisLocker> GetLockerAsync(string lockerName)
|
||||
{
|
||||
return RedisLocker.GetLockerAsync(RedisDatabase, lockerName, TimeSpan.FromSeconds(Numbers.SECS_REDIS_LOCK_EXPIRY)
|
||||
, Numbers.MAX_LIMIT_RETRY_CNT_REDIS_LOCK, TimeSpan.FromSeconds(Numbers.SECS_REDIS_LOCK_RETRY_DELAY));
|
||||
protected Task<RedisLocker> GetLockerAsync(string lockerName) {
|
||||
return RedisLocker.GetLockerAsync(
|
||||
RedisDatabase, lockerName, TimeSpan.FromSeconds(Numbers.SECS_REDIS_LOCK_EXPIRY), Numbers.MAX_LIMIT_RETRY_CNT_REDIS_LOCK
|
||||
, TimeSpan.FromSeconds(Numbers.SECS_REDIS_LOCK_RETRY_DELAY)
|
||||
);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取锁(仅获取一次)
|
||||
/// </summary>
|
||||
protected Task<RedisLocker> GetLockerOnceAsync(string lockerName)
|
||||
{
|
||||
return RedisLocker.GetLockerAsync(RedisDatabase, lockerName, TimeSpan.FromSeconds(Numbers.SECS_REDIS_LOCK_EXPIRY), 1
|
||||
, TimeSpan.FromSeconds(Numbers.SECS_REDIS_LOCK_RETRY_DELAY));
|
||||
protected Task<RedisLocker> GetLockerOnceAsync(string lockerName) {
|
||||
return RedisLocker.GetLockerAsync(
|
||||
RedisDatabase, lockerName, TimeSpan.FromSeconds(Numbers.SECS_REDIS_LOCK_EXPIRY), 1
|
||||
, TimeSpan.FromSeconds(Numbers.SECS_REDIS_LOCK_RETRY_DELAY)
|
||||
);
|
||||
}
|
||||
}
|
@@ -1,5 +1,3 @@
|
||||
using CsvHelper;
|
||||
using Microsoft.Net.Http.Headers;
|
||||
using NetAdmin.Application.Repositories;
|
||||
using NetAdmin.Domain;
|
||||
using NetAdmin.Domain.Contexts;
|
||||
@@ -17,7 +15,7 @@ namespace NetAdmin.Application.Services;
|
||||
/// <typeparam name="TPrimary">主键类型</typeparam>
|
||||
/// <typeparam name="TLogger">日志类型</typeparam>
|
||||
public abstract class RepositoryService<TEntity, TPrimary, TLogger>(BasicRepository<TEntity, TPrimary> rpo) : ServiceBase<TLogger>
|
||||
where TEntity : EntityBase<TPrimary> //
|
||||
where TEntity : EntityBase<TPrimary>
|
||||
where TPrimary : IEquatable<TPrimary>
|
||||
{
|
||||
/// <summary>
|
||||
@@ -28,7 +26,8 @@ public abstract class RepositoryService<TEntity, TPrimary, TLogger>(BasicReposit
|
||||
/// <summary>
|
||||
/// 启用级联保存
|
||||
/// </summary>
|
||||
protected bool EnableCascadeSave {
|
||||
protected bool EnableCascadeSave
|
||||
{
|
||||
get => Rpo.DbContextOptions.EnableCascadeSave;
|
||||
set => Rpo.DbContextOptions.EnableCascadeSave = value;
|
||||
}
|
||||
@@ -36,11 +35,13 @@ public abstract class RepositoryService<TEntity, TPrimary, TLogger>(BasicReposit
|
||||
/// <summary>
|
||||
/// 导出实体
|
||||
/// </summary>
|
||||
protected static async Task<IActionResult> ExportAsync<TQuery, TExport>( //
|
||||
Func<QueryReq<TQuery>, ISelectGrouping<TEntity, TEntity>> selector, QueryReq<TQuery> query, string fileName
|
||||
, Expression<Func<ISelectGroupingAggregate<TEntity, TEntity>, object>> listExp = null)
|
||||
where TQuery : DataAbstraction, new()
|
||||
{
|
||||
protected static async Task<IActionResult> ExportAsync<TQuery, TExport>(
|
||||
Func<QueryReq<TQuery>, ISelectGrouping<TEntity, TEntity>> selector
|
||||
, QueryReq<TQuery> query
|
||||
, string fileName
|
||||
, Expression<Func<ISelectGroupingAggregate<TEntity, TEntity>, object>> listExp = null
|
||||
)
|
||||
where TQuery : DataAbstraction, new() {
|
||||
var list = await selector(query).Take(Numbers.MAX_LIMIT_EXPORT).ToListAsync(listExp).ConfigureAwait(false);
|
||||
return await GetExportFileStreamAsync<TExport>(fileName, list).ConfigureAwait(false);
|
||||
}
|
||||
@@ -48,11 +49,14 @@ public abstract class RepositoryService<TEntity, TPrimary, TLogger>(BasicReposit
|
||||
/// <summary>
|
||||
/// 导出实体
|
||||
/// </summary>
|
||||
protected static async Task<IActionResult> ExportAsync<TQuery, TExport>( //
|
||||
Func<QueryReq<TQuery>, ISelect<TEntity>> selector, QueryReq<TQuery> query, string fileName, Expression<Func<TEntity, object>> listExp = null
|
||||
, Func<object, object> listHandle = null)
|
||||
where TQuery : DataAbstraction, new()
|
||||
{
|
||||
protected static async Task<IActionResult> ExportAsync<TQuery, TExport>(
|
||||
Func<QueryReq<TQuery>, ISelect<TEntity>> selector
|
||||
, QueryReq<TQuery> query
|
||||
, string fileName
|
||||
, Expression<Func<TEntity, object>> listExp = null
|
||||
, Func<object, object> listHandle = null
|
||||
)
|
||||
where TQuery : DataAbstraction, new() {
|
||||
var select = selector(query).WithNoLockNoWait().Take(Numbers.MAX_LIMIT_EXPORT);
|
||||
|
||||
object list = listExp == null ? await select.ToListAsync().ConfigureAwait(false) : await select.ToListAsync(listExp).ConfigureAwait(false);
|
||||
@@ -65,14 +69,16 @@ public abstract class RepositoryService<TEntity, TPrimary, TLogger>(BasicReposit
|
||||
/// <summary>
|
||||
/// 唯一索引冲突处理
|
||||
/// </summary>
|
||||
protected static async Task OnUniqueIndexConflictAsync(Func<Task> actionTry, Func<Task> actionCatch = null)
|
||||
{
|
||||
protected static async Task OnUniqueIndexConflictAsync(
|
||||
Func<Task> actionTry
|
||||
, Func<Task> actionCatch = null
|
||||
) {
|
||||
try {
|
||||
await actionTry().ConfigureAwait(false);
|
||||
}
|
||||
catch (Exception ex) when (ex.Message.Contains(Chars.FLG_DB_EXCEPTION_PRIMARY_KEY_CONFLICT) ||
|
||||
ex.Message.Contains(Chars.FLG_DB_EXCEPTION_UNIQUE_CONSTRAINT_CONFLICT) ||
|
||||
ex.Message.Contains(Chars.FLG_DB_EXCEPTION_IDX)) {
|
||||
catch (Exception ex) when (ex.Message.Contains(Chars.FLG_DB_EXCEPTION_PRIMARY_KEY_CONFLICT)
|
||||
|| ex.Message.Contains(Chars.FLG_DB_EXCEPTION_UNIQUE_CONSTRAINT_CONFLICT)
|
||||
|| ex.Message.Contains(Chars.FLG_DB_EXCEPTION_IDX)) {
|
||||
if (actionCatch != null) {
|
||||
await actionCatch().ConfigureAwait(false);
|
||||
}
|
||||
@@ -90,20 +96,23 @@ public abstract class RepositoryService<TEntity, TPrimary, TLogger>(BasicReposit
|
||||
/// <param name="ignoreVersion">是否忽略版本锁</param>
|
||||
/// <param name="disableGlobalDataFilter">是否忽略全局数据权限过滤</param>
|
||||
/// <returns>更新行数</returns>
|
||||
protected Task<int> UpdateAsync( //
|
||||
TEntity newValue //
|
||||
, List<string> includeFields = null //
|
||||
, List<string> excludeFields = null //
|
||||
, Expression<Func<TEntity, bool>> whereExp = null //
|
||||
, string whereSql = null //
|
||||
, bool ignoreVersion = false, bool disableGlobalDataFilter = false)
|
||||
{
|
||||
protected Task<int> UpdateAsync(
|
||||
TEntity newValue
|
||||
, List<string> includeFields = null
|
||||
, List<string> excludeFields = null
|
||||
, Expression<Func<TEntity, bool>> whereExp = null
|
||||
, string whereSql = null
|
||||
, bool ignoreVersion = false
|
||||
, bool disableGlobalDataFilter = false
|
||||
) {
|
||||
// 默认匹配主键
|
||||
whereExp ??= a => a.Id.Equals(newValue.Id);
|
||||
var update = BuildUpdate(newValue, includeFields, excludeFields, ignoreVersion).Where(whereExp).Where(whereSql);
|
||||
if (disableGlobalDataFilter) {
|
||||
update = update.DisableGlobalFilter(Chars.FLG_FREE_SQL_GLOBAL_FILTER_SELF, Chars.FLG_FREE_SQL_GLOBAL_FILTER_DEPT
|
||||
, Chars.FLG_FREE_SQL_GLOBAL_FILTER_DEPT_WITH_CHILDREN, Chars.FLG_FREE_SQL_GLOBAL_FILTER_DEPT_WITH_SON);
|
||||
update = update.DisableGlobalFilter(
|
||||
Chars.FLG_FREE_SQL_GLOBAL_FILTER_SELF, Chars.FLG_FREE_SQL_GLOBAL_FILTER_DEPT, Chars.FLG_FREE_SQL_GLOBAL_FILTER_DEPT_WITH_CHILDREN
|
||||
, Chars.FLG_FREE_SQL_GLOBAL_FILTER_DEPT_WITH_SON
|
||||
);
|
||||
}
|
||||
|
||||
return update.ExecuteEffectsAsync();
|
||||
@@ -120,50 +129,59 @@ public abstract class RepositoryService<TEntity, TPrimary, TLogger>(BasicReposit
|
||||
/// <param name="whereSql">查询sql</param>
|
||||
/// <param name="ignoreVersion">是否忽略版本锁</param>
|
||||
/// <returns>更新后的实体列表</returns>
|
||||
protected Task<List<TEntity>> UpdateReturnListAsync( //
|
||||
TEntity newValue //
|
||||
, List<string> includeFields = null //
|
||||
, List<string> excludeFields = null //
|
||||
, Expression<Func<TEntity, bool>> whereExp = null //
|
||||
, string whereSql = null //
|
||||
, bool ignoreVersion = false)
|
||||
{
|
||||
protected Task<List<TEntity>> UpdateReturnListAsync(
|
||||
TEntity newValue
|
||||
, List<string> includeFields = null
|
||||
, List<string> excludeFields = null
|
||||
, Expression<Func<TEntity, bool>> whereExp = null
|
||||
, string whereSql = null
|
||||
, bool ignoreVersion = false
|
||||
) {
|
||||
// 默认匹配主键
|
||||
whereExp ??= a => a.Id.Equals(newValue.Id);
|
||||
return BuildUpdate(newValue, includeFields, excludeFields, ignoreVersion).Where(whereExp).Where(whereSql).ExecuteUpdatedAsync();
|
||||
}
|
||||
#endif
|
||||
|
||||
private static async Task<IActionResult> GetExportFileStreamAsync<TExport>(string fileName, object list)
|
||||
{
|
||||
var listTyped = list.Adapt<List<TExport>>();
|
||||
var stream = new MemoryStream();
|
||||
var writer = new StreamWriter(stream);
|
||||
var csv = new CsvWriter(writer, CultureInfo.InvariantCulture);
|
||||
csv.WriteHeader<TExport>();
|
||||
await csv.NextRecordAsync().ConfigureAwait(false);
|
||||
#pragma warning disable S2326
|
||||
private static Task<IActionResult> GetExportFileStreamAsync<TExport>(
|
||||
string fileName
|
||||
, object list
|
||||
) {
|
||||
#pragma warning restore S2326
|
||||
throw new NotImplementedException();
|
||||
|
||||
foreach (var item in listTyped) {
|
||||
csv.WriteRecord(item);
|
||||
await csv.NextRecordAsync().ConfigureAwait(false);
|
||||
}
|
||||
|
||||
await csv.FlushAsync().ConfigureAwait(false);
|
||||
_ = stream.Seek(0, SeekOrigin.Begin);
|
||||
|
||||
App.HttpContext.Response.Headers.ContentDisposition
|
||||
= new ContentDispositionHeaderValue(Chars.FLG_HTTP_HEADER_VALUE_ATTACHMENT) {
|
||||
FileNameStar
|
||||
= $"{fileName}_{DateTime.Now:yyyy.MM.dd-HH.mm.ss}.csv"
|
||||
}.ToString();
|
||||
|
||||
return new FileStreamResult(stream, Chars.FLG_HTTP_HEADER_VALUE_APPLICATION_OCTET_STREAM);
|
||||
// var listTyped = list.Adapt<List<TExport>>();
|
||||
// var stream = new MemoryStream();
|
||||
// var writer = new StreamWriter(stream);
|
||||
// var csv = new CsvWriter(writer, CultureInfo.InvariantCulture);
|
||||
// csv.WriteHeader<TExport>();
|
||||
// await csv.NextRecordAsync().ConfigureAwait(false);
|
||||
//
|
||||
// foreach (var item in listTyped) {
|
||||
// csv.WriteRecord(item);
|
||||
// await csv.NextRecordAsync().ConfigureAwait(false);
|
||||
// }
|
||||
//
|
||||
// await csv.FlushAsync().ConfigureAwait(false);
|
||||
// _ = stream.Seek(0, SeekOrigin.Begin);
|
||||
//
|
||||
// App.HttpContext.Response.Headers.ContentDisposition
|
||||
// = new ContentDispositionHeaderValue(Chars.FLG_HTTP_HEADER_VALUE_ATTACHMENT)
|
||||
// {
|
||||
// FileNameStar = $"{fileName}_{DateTime.Now:yyyy.MM.dd-HH.mm.ss}.csv"
|
||||
// }.ToString();
|
||||
//
|
||||
// return new FileStreamResult(stream, Chars.FLG_HTTP_HEADER_VALUE_APPLICATION_OCTET_STREAM);
|
||||
}
|
||||
|
||||
private static Dictionary<string, object> IncludeToDictionary(TEntity entity, List<string> includeFields)
|
||||
{
|
||||
private static Dictionary<string, object> IncludeToDictionary(
|
||||
TEntity entity
|
||||
, List<string> includeFields
|
||||
) {
|
||||
var ret = includeFields!.ToDictionary(
|
||||
x => x, x => typeof(TEntity).GetProperty(x, BindingFlags.Public | BindingFlags.Instance)!.GetValue(entity));
|
||||
x => x, x => typeof(TEntity).GetProperty(x, BindingFlags.Public | BindingFlags.Instance)!.GetValue(entity)
|
||||
);
|
||||
|
||||
// ReSharper disable once ConvertIfStatementToSwitchStatement
|
||||
if (entity is IFieldModifiedUser) {
|
||||
@@ -172,7 +190,7 @@ public abstract class RepositoryService<TEntity, TPrimary, TLogger>(BasicReposit
|
||||
return ret;
|
||||
}
|
||||
|
||||
ret.Add(nameof(IFieldModifiedUser.ModifiedUserId), userInfo.Id);
|
||||
ret.Add(nameof(IFieldModifiedUser.ModifiedUserId), userInfo.Id);
|
||||
ret.Add(nameof(IFieldModifiedUser.ModifiedUserName), userInfo.UserName);
|
||||
}
|
||||
|
||||
@@ -184,8 +202,12 @@ public abstract class RepositoryService<TEntity, TPrimary, TLogger>(BasicReposit
|
||||
return ret;
|
||||
}
|
||||
|
||||
private IUpdate<TEntity> BuildUpdate(TEntity entity, List<string> includeFields, List<string> excludeFields, bool ignoreVersion)
|
||||
{
|
||||
private IUpdate<TEntity> BuildUpdate(
|
||||
TEntity entity
|
||||
, List<string> includeFields
|
||||
, List<string> excludeFields
|
||||
, bool ignoreVersion
|
||||
) {
|
||||
IUpdate<TEntity> updateExp;
|
||||
if (includeFields.NullOrEmpty()) {
|
||||
updateExp = Rpo.UpdateDiy.SetSource(entity);
|
||||
|
@@ -8,8 +8,7 @@ public abstract class ServiceBase<TLogger> : ServiceBase
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="ServiceBase{TLogger}" /> class.
|
||||
/// </summary>
|
||||
protected ServiceBase() //
|
||||
{
|
||||
protected ServiceBase() {
|
||||
Logger = S<ILogger<TLogger>>();
|
||||
}
|
||||
|
||||
@@ -27,8 +26,7 @@ public abstract class ServiceBase : IScoped, IService
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="ServiceBase" /> class.
|
||||
/// </summary>
|
||||
protected ServiceBase()
|
||||
{
|
||||
protected ServiceBase() {
|
||||
UserToken = S<ContextUserToken>();
|
||||
ServiceId = Guid.NewGuid();
|
||||
}
|
||||
@@ -44,8 +42,7 @@ public abstract class ServiceBase : IScoped, IService
|
||||
/// </summary>
|
||||
protected static T S<T>()
|
||||
#pragma warning restore S2325, CA1822
|
||||
where T : class
|
||||
{
|
||||
where T : class {
|
||||
return App.GetService<T>();
|
||||
}
|
||||
}
|
@@ -18,8 +18,12 @@ public abstract class DistributedCache<TService>(IDistributedCache cache, TServi
|
||||
/// <param name="slideLifeTime">滑动过期时间</param>
|
||||
/// <typeparam name="T">缓存对象类型</typeparam>
|
||||
/// <returns>缓存对象</returns>
|
||||
protected Task CreateAsync<T>(string key, T createObj, TimeSpan? absLifeTime = null, TimeSpan? slideLifeTime = null)
|
||||
{
|
||||
protected Task CreateAsync<T>(
|
||||
string key
|
||||
, T createObj
|
||||
, TimeSpan? absLifeTime = null
|
||||
, TimeSpan? slideLifeTime = null
|
||||
) {
|
||||
var cacheWrite = createObj.ToJson();
|
||||
|
||||
var options = new DistributedCacheEntryOptions();
|
||||
@@ -37,8 +41,7 @@ public abstract class DistributedCache<TService>(IDistributedCache cache, TServi
|
||||
/// <summary>
|
||||
/// 获取缓存
|
||||
/// </summary>
|
||||
protected async Task<T> GetAsync<T>(string key)
|
||||
{
|
||||
protected async Task<T> GetAsync<T>(string key) {
|
||||
var cacheRead = await Cache.GetStringAsync(key).ConfigureAwait(false);
|
||||
try {
|
||||
return cacheRead != null ? cacheRead.ToObject<T>() : default;
|
||||
@@ -51,8 +54,10 @@ public abstract class DistributedCache<TService>(IDistributedCache cache, TServi
|
||||
/// <summary>
|
||||
/// 获取缓存键
|
||||
/// </summary>
|
||||
protected string GetCacheKey(string id = "0", [CallerMemberName] string memberName = null)
|
||||
{
|
||||
protected string GetCacheKey(
|
||||
string id = "0"
|
||||
, [CallerMemberName] string memberName = null
|
||||
) {
|
||||
return $"{GetType().FullName}.{memberName}.{id}";
|
||||
}
|
||||
|
||||
@@ -65,8 +70,12 @@ public abstract class DistributedCache<TService>(IDistributedCache cache, TServi
|
||||
/// <param name="slideLifeTime">滑动过期时间</param>
|
||||
/// <typeparam name="T">缓存对象类型</typeparam>
|
||||
/// <returns>缓存对象</returns>
|
||||
protected async Task<T> GetOrCreateAsync<T>(string key, Func<Task<T>> createProc, TimeSpan? absLifeTime = null, TimeSpan? slideLifeTime = null)
|
||||
{
|
||||
protected async Task<T> GetOrCreateAsync<T>(
|
||||
string key
|
||||
, Func<Task<T>> createProc
|
||||
, TimeSpan? absLifeTime = null
|
||||
, TimeSpan? slideLifeTime = null
|
||||
) {
|
||||
var cacheRead = await GetAsync<T>(key).ConfigureAwait(false);
|
||||
if (cacheRead is not null && App.HttpContext?.Request.Headers.CacheControl.FirstOrDefault() != Chars.FLG_HTTP_HEADER_VALUE_NO_CACHE) {
|
||||
return cacheRead;
|
||||
@@ -86,8 +95,7 @@ public abstract class DistributedCache<TService>(IDistributedCache cache, TServi
|
||||
/// <summary>
|
||||
/// 删除缓存
|
||||
/// </summary>
|
||||
protected Task RemoveAsync(string key)
|
||||
{
|
||||
protected Task RemoveAsync(string key) {
|
||||
return Cache.RemoveAsync(key);
|
||||
}
|
||||
}
|
@@ -9,15 +9,13 @@ public sealed class AlipayAttribute : ValidationAttribute
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="AlipayAttribute" /> class.
|
||||
/// </summary>
|
||||
public AlipayAttribute()
|
||||
{
|
||||
public AlipayAttribute() {
|
||||
ErrorMessageResourceName = nameof(Ln.支付宝账号);
|
||||
ErrorMessageResourceType = typeof(Ln);
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public override bool IsValid(object value)
|
||||
{
|
||||
public override bool IsValid(object value) {
|
||||
return new MobileAttribute().IsValid(value) || new EmailAddressAttribute().IsValid(value);
|
||||
}
|
||||
}
|
@@ -9,10 +9,13 @@ namespace NetAdmin.Domain.Attributes.DataValidation;
|
||||
public sealed class ApiIdAttribute : ValidationAttribute
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override ValidationResult IsValid(object value, ValidationContext validationContext)
|
||||
{
|
||||
protected override ValidationResult IsValid(
|
||||
object value
|
||||
, ValidationContext validationContext
|
||||
) {
|
||||
var service = App.GetService(
|
||||
App.EffectiveTypes.Single(x => x.FullName == "NetAdmin.SysComponent.Application.Services.Sys.Dependency.IApiService"));
|
||||
App.EffectiveTypes.Single(x => x.FullName == "NetAdmin.SysComponent.Application.Services.Sys.Dependency.IApiService")
|
||||
);
|
||||
|
||||
var req = new QueryReq<QueryApiReq> { Filter = new QueryApiReq { Id = value as string } };
|
||||
|
||||
|
@@ -9,9 +9,8 @@ public sealed class CertificateAttribute : RegexAttribute
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="CertificateAttribute" /> class.
|
||||
/// </summary>
|
||||
public CertificateAttribute() //
|
||||
: base(Chars.RGX_CERTIFICATE)
|
||||
{
|
||||
public CertificateAttribute()
|
||||
: base(Chars.RGX_CERTIFICATE) {
|
||||
ErrorMessageResourceName = nameof(Ln.无效证件号码);
|
||||
ErrorMessageResourceType = typeof(Ln);
|
||||
}
|
||||
|
@@ -9,9 +9,8 @@ public sealed class ChineseNameAttribute : RegexAttribute
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="ChineseNameAttribute" /> class.
|
||||
/// </summary>
|
||||
public ChineseNameAttribute() //
|
||||
: base(Chars.RGXL_CHINESE_NAME)
|
||||
{
|
||||
public ChineseNameAttribute()
|
||||
: base(Chars.RGXL_CHINESE_NAME) {
|
||||
ErrorMessageResourceName = nameof(Ln.中文姓名);
|
||||
ErrorMessageResourceType = typeof(Ln);
|
||||
}
|
||||
|
@@ -9,9 +9,8 @@ public sealed class CronAttribute : RegexAttribute
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="CronAttribute" /> class.
|
||||
/// </summary>
|
||||
public CronAttribute() //
|
||||
: base(Chars.RGXL_CRON)
|
||||
{
|
||||
public CronAttribute()
|
||||
: base(Chars.RGXL_CRON) {
|
||||
ErrorMessageResourceName = nameof(Ln.时间表达式);
|
||||
ErrorMessageResourceType = typeof(Ln);
|
||||
}
|
||||
|
@@ -9,9 +9,8 @@ public sealed class EmailAttribute : RegexAttribute
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="EmailAttribute" /> class.
|
||||
/// </summary>
|
||||
public EmailAttribute() //
|
||||
: base(Chars.RGXL_EMAIL)
|
||||
{
|
||||
public EmailAttribute()
|
||||
: base(Chars.RGXL_EMAIL) {
|
||||
ErrorMessageResourceName = nameof(Ln.电子邮箱);
|
||||
ErrorMessageResourceType = typeof(Ln);
|
||||
}
|
||||
|
@@ -9,9 +9,8 @@ public sealed class InviteCodeAttribute : RegexAttribute
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="InviteCodeAttribute" /> class.
|
||||
/// </summary>
|
||||
public InviteCodeAttribute() //
|
||||
: base(Chars.RGX_INVITE_CODE)
|
||||
{
|
||||
public InviteCodeAttribute()
|
||||
: base(Chars.RGX_INVITE_CODE) {
|
||||
ErrorMessageResourceName = nameof(Ln.邀请码不正确);
|
||||
ErrorMessageResourceType = typeof(Ln);
|
||||
}
|
||||
|
@@ -7,8 +7,10 @@ namespace NetAdmin.Domain.Attributes.DataValidation;
|
||||
public sealed class JsonStringAttribute : ValidationAttribute
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override ValidationResult IsValid(object value, ValidationContext validationContext)
|
||||
{
|
||||
protected override ValidationResult IsValid(
|
||||
object value
|
||||
, ValidationContext validationContext
|
||||
) {
|
||||
return (value as string).IsJsonString() ? ValidationResult.Success : new ValidationResult(Ln.非JSON字符串, [validationContext.MemberName]);
|
||||
}
|
||||
}
|
@@ -9,9 +9,8 @@ public sealed class MobileAttribute : RegexAttribute
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="MobileAttribute" /> class.
|
||||
/// </summary>
|
||||
public MobileAttribute() //
|
||||
: base(Chars.RGX_MOBILE)
|
||||
{
|
||||
public MobileAttribute()
|
||||
: base(Chars.RGX_MOBILE) {
|
||||
ErrorMessageResourceName = nameof(Ln.手机号码不正确);
|
||||
ErrorMessageResourceType = typeof(Ln);
|
||||
}
|
||||
|
@@ -9,9 +9,8 @@ public sealed class PasswordAttribute : RegexAttribute
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="PasswordAttribute" /> class.
|
||||
/// </summary>
|
||||
public PasswordAttribute() //
|
||||
: base(Chars.RGX_PASSWORD)
|
||||
{
|
||||
public PasswordAttribute()
|
||||
: base(Chars.RGX_PASSWORD) {
|
||||
ErrorMessageResourceName = nameof(Ln._8位以上数字字母组合);
|
||||
ErrorMessageResourceType = typeof(Ln);
|
||||
}
|
||||
|
@@ -9,9 +9,8 @@ public sealed class PayPasswordAttribute : RegexAttribute
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="PayPasswordAttribute" /> class.
|
||||
/// </summary>
|
||||
public PayPasswordAttribute() //
|
||||
: base(Chars.RGX_PAY_PASSWORD)
|
||||
{
|
||||
public PayPasswordAttribute()
|
||||
: base(Chars.RGX_PAY_PASSWORD) {
|
||||
ErrorMessageResourceName = nameof(Ln._6位数字);
|
||||
ErrorMessageResourceType = typeof(Ln);
|
||||
}
|
||||
|
@@ -9,9 +9,8 @@ public sealed class PortAttribute : RangeAttribute
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="PortAttribute" /> class.
|
||||
/// </summary>
|
||||
public PortAttribute() //
|
||||
: base(1, ushort.MaxValue)
|
||||
{
|
||||
public PortAttribute()
|
||||
: base(1, ushort.MaxValue) {
|
||||
ErrorMessageResourceName = nameof(Ln.无效端口号);
|
||||
ErrorMessageResourceType = typeof(Ln);
|
||||
}
|
||||
|
@@ -11,6 +11,7 @@ public class RegexAttribute : RegularExpressionAttribute
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="RegexAttribute" /> class.
|
||||
/// </summary>
|
||||
protected RegexAttribute(string pattern) //
|
||||
: base(pattern) { }
|
||||
protected RegexAttribute(string pattern)
|
||||
: base(pattern) {
|
||||
}
|
||||
}
|
@@ -10,8 +10,10 @@ namespace NetAdmin.Domain.Attributes.DataValidation;
|
||||
public sealed class SpecificDeptAttribute : ValidationAttribute
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override ValidationResult IsValid(object value, ValidationContext validationContext)
|
||||
{
|
||||
protected override ValidationResult IsValid(
|
||||
object value
|
||||
, ValidationContext validationContext
|
||||
) {
|
||||
if (validationContext.ObjectInstance is not CreateRoleReq { DataScope: DataScopes.SpecificDept }) {
|
||||
return ValidationResult.Success;
|
||||
}
|
||||
|
@@ -9,9 +9,8 @@ public sealed class TelephoneAttribute : RegexAttribute
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="TelephoneAttribute" /> class.
|
||||
/// </summary>
|
||||
public TelephoneAttribute() //
|
||||
: base(Chars.RGX_TELEPHONE)
|
||||
{
|
||||
public TelephoneAttribute()
|
||||
: base(Chars.RGX_TELEPHONE) {
|
||||
ErrorMessageResourceName = nameof(Ln.区号电话号码分机号);
|
||||
ErrorMessageResourceType = typeof(Ln);
|
||||
}
|
||||
|
@@ -9,10 +9,13 @@ namespace NetAdmin.Domain.Attributes.DataValidation;
|
||||
public sealed class UserIdAttribute : ValidationAttribute
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override ValidationResult IsValid(object value, ValidationContext validationContext)
|
||||
{
|
||||
protected override ValidationResult IsValid(
|
||||
object value
|
||||
, ValidationContext validationContext
|
||||
) {
|
||||
var service = App.GetService(
|
||||
App.EffectiveTypes.Single(x => x.FullName == "NetAdmin.SysComponent.Application.Services.Sys.Dependency.IUserService"));
|
||||
App.EffectiveTypes.Single(x => x.FullName == "NetAdmin.SysComponent.Application.Services.Sys.Dependency.IUserService")
|
||||
);
|
||||
|
||||
var req = new QueryReq<QueryUserReq> { Filter = new QueryUserReq { Id = (long)value! } };
|
||||
|
||||
|
@@ -9,15 +9,13 @@ public sealed class UserNameAttribute : RegexAttribute
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="UserNameAttribute" /> class.
|
||||
/// </summary>
|
||||
public UserNameAttribute() //
|
||||
: base(Chars.RGX_USERNAME)
|
||||
{
|
||||
public UserNameAttribute()
|
||||
: base(Chars.RGX_USERNAME) {
|
||||
ErrorMessageResourceType = typeof(Ln);
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public override bool IsValid(object value)
|
||||
{
|
||||
public override bool IsValid(object value) {
|
||||
if (!base.IsValid(value)) {
|
||||
ErrorMessageResourceName = nameof(Ln.用户名不符合要求);
|
||||
return false;
|
||||
|
@@ -9,9 +9,8 @@ public sealed class VerifyCodeAttribute : RegexAttribute
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="VerifyCodeAttribute" /> class.
|
||||
/// </summary>
|
||||
public VerifyCodeAttribute() //
|
||||
: base(Chars.RGX_VERIFY_CODE)
|
||||
{
|
||||
public VerifyCodeAttribute()
|
||||
: base(Chars.RGX_VERIFY_CODE) {
|
||||
ErrorMessageResourceName = nameof(Ln.验证码不正确);
|
||||
ErrorMessageResourceType = typeof(Ln);
|
||||
}
|
||||
|
@@ -10,8 +10,7 @@ public sealed record ContextUserInfo : QueryUserRsp
|
||||
/// <summary>
|
||||
/// 从HttpContext 创建上下文用户信息
|
||||
/// </summary>
|
||||
public static ContextUserInfo Create()
|
||||
{
|
||||
public static ContextUserInfo Create() {
|
||||
var ret = App.HttpContext?.Items[nameof(Chars.FLG_CONTEXT_USER_INFO)] as QueryUserRsp;
|
||||
return ret?.Adapt<ContextUserInfo>();
|
||||
}
|
||||
@@ -19,8 +18,7 @@ public sealed record ContextUserInfo : QueryUserRsp
|
||||
/// <summary>
|
||||
/// 是否存在于 HttpContext
|
||||
/// </summary>
|
||||
public static bool HasInContext()
|
||||
{
|
||||
public static bool HasInContext() {
|
||||
return App.HttpContext?.Items.ContainsKey(Chars.FLG_CONTEXT_USER_INFO) ?? false;
|
||||
}
|
||||
}
|
@@ -32,8 +32,7 @@ public sealed record ContextUserToken : DataAbstraction
|
||||
/// <summary>
|
||||
/// 从HttpContext 创建上下文用户
|
||||
/// </summary>
|
||||
public static ContextUserToken Create()
|
||||
{
|
||||
public static ContextUserToken Create() {
|
||||
var claim = App.User?.FindFirst(nameof(ContextUserToken));
|
||||
return claim?.Value.ToObject<ContextUserToken>();
|
||||
}
|
||||
@@ -41,18 +40,22 @@ public sealed record ContextUserToken : DataAbstraction
|
||||
/// <summary>
|
||||
/// 从 QueryUserRsp 创建上下文用户
|
||||
/// </summary>
|
||||
public static ContextUserToken Create(long id, Guid token, string userName, long deptId)
|
||||
{
|
||||
public static ContextUserToken Create(
|
||||
long id
|
||||
, Guid token
|
||||
, string userName
|
||||
, long deptId
|
||||
) {
|
||||
return new ContextUserToken { Id = id, Token = token, UserName = userName, DeptId = deptId };
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 从 Json Web Token 创建上下文用户
|
||||
/// </summary>
|
||||
public static ContextUserToken Create(string jwt)
|
||||
{
|
||||
var claim = JWTEncryption.ReadJwtToken(jwt.TrimPrefix($"{Chars.FLG_HTTP_HEADER_VALUE_AUTH_SCHEMA} "))
|
||||
?.Claims.FirstOrDefault(x => x.Type == nameof(ContextUserToken));
|
||||
public static ContextUserToken Create(string jwt) {
|
||||
var claim = JWTEncryption
|
||||
.ReadJwtToken(jwt.TrimPrefix($"{Chars.FLG_HTTP_HEADER_VALUE_AUTH_SCHEMA} "))
|
||||
?.Claims.FirstOrDefault(x => x.Type == nameof(ContextUserToken));
|
||||
return claim?.Value.ToObject<ContextUserToken>();
|
||||
}
|
||||
}
|
@@ -14,31 +14,28 @@ public abstract record DataAbstraction : IValidatableObject
|
||||
/// 如果数据校验失败,抛出异常
|
||||
/// </summary>
|
||||
/// <exception cref="NetAdminValidateException">NetAdminValidateException</exception>
|
||||
public void ThrowIfInvalid()
|
||||
{
|
||||
public void ThrowIfInvalid() {
|
||||
if (HasValidated) {
|
||||
return;
|
||||
}
|
||||
|
||||
var validationResult = this.TryValidate();
|
||||
if (!validationResult.IsValid) {
|
||||
throw new NetAdminValidateException(validationResult.ValidationResults.ToDictionary( //
|
||||
x => x.MemberNames.First() //
|
||||
, x => new[] { x.ErrorMessage }));
|
||||
throw new NetAdminValidateException(
|
||||
validationResult.ValidationResults.ToDictionary(x => x.MemberNames.First(), x => new[] { x.ErrorMessage })
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public override string ToString()
|
||||
{
|
||||
public override string ToString() {
|
||||
return this.ToJson();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 截断所有字符串属性 以符合[MaxLength(x)]特性
|
||||
/// </summary>
|
||||
public void TruncateStrings()
|
||||
{
|
||||
public void TruncateStrings() {
|
||||
foreach (var property in GetType().GetProperties(BindingFlags.Public | BindingFlags.Instance).Where(x => x.PropertyType == typeof(string))) {
|
||||
var maxLen = property.GetCustomAttribute<MaxLengthAttribute>(true)?.Length;
|
||||
if (maxLen is null or 0) {
|
||||
@@ -56,8 +53,7 @@ public abstract record DataAbstraction : IValidatableObject
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public IEnumerable<ValidationResult> Validate(ValidationContext validationContext)
|
||||
{
|
||||
public IEnumerable<ValidationResult> Validate(ValidationContext validationContext) {
|
||||
HasValidated = true;
|
||||
return ValidateInternal(validationContext);
|
||||
}
|
||||
@@ -65,8 +61,7 @@ public abstract record DataAbstraction : IValidatableObject
|
||||
/// <summary>
|
||||
/// 内部验证
|
||||
/// </summary>
|
||||
protected virtual IEnumerable<ValidationResult> ValidateInternal(ValidationContext validationContext)
|
||||
{
|
||||
protected virtual IEnumerable<ValidationResult> ValidateInternal(ValidationContext validationContext) {
|
||||
yield return ValidationResult.Success;
|
||||
}
|
||||
}
|
@@ -7,7 +7,6 @@ public abstract record ImmutableEntity : ImmutableEntity<long>
|
||||
/// 唯一编码
|
||||
/// </summary>
|
||||
[Column(IsIdentity = false, IsPrimary = true, Position = 1)]
|
||||
[CsvIgnore]
|
||||
[Snowflake]
|
||||
public override long Id { get; init; }
|
||||
}
|
||||
@@ -23,7 +22,6 @@ public abstract record ImmutableEntity<T> : LiteImmutableEntity<T>, IFieldCreate
|
||||
/// 创建者编号
|
||||
/// </summary>
|
||||
[Column(CanUpdate = false, Position = -1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? CreatedUserId { get; init; }
|
||||
|
||||
@@ -31,7 +29,6 @@ public abstract record ImmutableEntity<T> : LiteImmutableEntity<T>, IFieldCreate
|
||||
/// 创建者用户名
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31, CanUpdate = false, Position = -1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string CreatedUserName { get; init; }
|
||||
|
||||
@@ -39,6 +36,5 @@ public abstract record ImmutableEntity<T> : LiteImmutableEntity<T>, IFieldCreate
|
||||
/// 唯一编码
|
||||
/// </summary>
|
||||
[Column(IsIdentity = false, IsPrimary = true, Position = 1)]
|
||||
[CsvIgnore]
|
||||
public override T Id { get; init; }
|
||||
}
|
@@ -7,7 +7,6 @@ public abstract record LiteImmutableEntity : LiteImmutableEntity<long>
|
||||
/// 唯一编码
|
||||
/// </summary>
|
||||
[Column(IsIdentity = false, IsPrimary = true, Position = 1)]
|
||||
[CsvIgnore]
|
||||
[Snowflake]
|
||||
public override long Id { get; init; }
|
||||
}
|
||||
@@ -23,7 +22,6 @@ public abstract record LiteImmutableEntity<T> : EntityBase<T>, IFieldCreatedTime
|
||||
/// 创建时间
|
||||
/// </summary>
|
||||
[Column(ServerTime = DateTimeKind.Local, CanUpdate = false, Position = -1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual DateTime CreatedTime { get; init; }
|
||||
|
||||
@@ -31,7 +29,6 @@ public abstract record LiteImmutableEntity<T> : EntityBase<T>, IFieldCreatedTime
|
||||
/// 唯一编码
|
||||
/// </summary>
|
||||
[Column(IsIdentity = false, IsPrimary = true, Position = 1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public override T Id { get; init; }
|
||||
}
|
@@ -7,7 +7,6 @@ public abstract record LiteMutableEntity : LiteMutableEntity<long>
|
||||
/// 唯一编码
|
||||
/// </summary>
|
||||
[Column(IsIdentity = false, IsPrimary = true, Position = 1)]
|
||||
[CsvIgnore]
|
||||
[Snowflake]
|
||||
public override long Id { get; init; }
|
||||
}
|
||||
@@ -22,14 +21,12 @@ public abstract record LiteMutableEntity<T> : LiteImmutableEntity<T>, IFieldModi
|
||||
/// 唯一编码
|
||||
/// </summary>
|
||||
[Column(IsIdentity = false, IsPrimary = true, Position = 1)]
|
||||
[CsvIgnore]
|
||||
public override T Id { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 修改时间
|
||||
/// </summary>
|
||||
[Column(ServerTime = DateTimeKind.Local, CanInsert = false, Position = -1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual DateTime? ModifiedTime { get; init; }
|
||||
}
|
@@ -7,7 +7,6 @@ public abstract record LiteVersionEntity : LiteVersionEntity<long>
|
||||
/// 唯一编码
|
||||
/// </summary>
|
||||
[Column(IsIdentity = false, IsPrimary = true, Position = 1)]
|
||||
[CsvIgnore]
|
||||
[Snowflake]
|
||||
public override long Id { get; init; }
|
||||
}
|
||||
@@ -22,7 +21,6 @@ public abstract record LiteVersionEntity<T> : LiteMutableEntity<T>, IFieldVersio
|
||||
/// 唯一编码
|
||||
/// </summary>
|
||||
[Column(IsIdentity = false, IsPrimary = true, Position = 1)]
|
||||
[CsvIgnore]
|
||||
[Snowflake]
|
||||
public override T Id { get; init; }
|
||||
|
||||
@@ -30,7 +28,6 @@ public abstract record LiteVersionEntity<T> : LiteMutableEntity<T>, IFieldVersio
|
||||
/// 数据版本
|
||||
/// </summary>
|
||||
[Column(IsVersion = true, Position = -1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long Version { get; init; }
|
||||
}
|
@@ -7,7 +7,6 @@ public abstract record MutableEntity : MutableEntity<long>
|
||||
/// 唯一编码
|
||||
/// </summary>
|
||||
[Column(IsIdentity = false, IsPrimary = true, Position = 1)]
|
||||
[CsvIgnore]
|
||||
[Snowflake]
|
||||
public override long Id { get; init; }
|
||||
}
|
||||
@@ -22,7 +21,6 @@ public abstract record MutableEntity<T> : LiteMutableEntity<T>, IFieldCreatedUse
|
||||
/// 创建者编号
|
||||
/// </summary>
|
||||
[Column(CanUpdate = false, Position = -1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? CreatedUserId { get; init; }
|
||||
|
||||
@@ -30,7 +28,6 @@ public abstract record MutableEntity<T> : LiteMutableEntity<T>, IFieldCreatedUse
|
||||
/// 创建者用户名
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31, CanUpdate = false, Position = -1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string CreatedUserName { get; init; }
|
||||
|
||||
@@ -38,14 +35,12 @@ public abstract record MutableEntity<T> : LiteMutableEntity<T>, IFieldCreatedUse
|
||||
/// 唯一编码
|
||||
/// </summary>
|
||||
[Column(IsIdentity = false, IsPrimary = true, Position = 1)]
|
||||
[CsvIgnore]
|
||||
public override T Id { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 修改者编号
|
||||
/// </summary>
|
||||
[Column(CanInsert = false, Position = -1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? ModifiedUserId { get; init; }
|
||||
|
||||
@@ -53,7 +48,6 @@ public abstract record MutableEntity<T> : LiteMutableEntity<T>, IFieldCreatedUse
|
||||
/// 修改者用户名
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31, CanInsert = false, Position = -1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string ModifiedUserName { get; init; }
|
||||
}
|
@@ -7,7 +7,6 @@ public abstract record SimpleEntity : SimpleEntity<long>
|
||||
/// 唯一编码
|
||||
/// </summary>
|
||||
[Column(IsIdentity = false, IsPrimary = true, Position = 1)]
|
||||
[CsvIgnore]
|
||||
[Snowflake]
|
||||
public override long Id { get; init; }
|
||||
}
|
||||
|
@@ -7,7 +7,6 @@ public abstract record VersionEntity : VersionEntity<long>
|
||||
/// 唯一编码
|
||||
/// </summary>
|
||||
[Column(IsIdentity = false, IsPrimary = true, Position = 1)]
|
||||
[CsvIgnore]
|
||||
[Snowflake]
|
||||
public override long Id { get; init; }
|
||||
}
|
||||
@@ -22,7 +21,6 @@ public abstract record VersionEntity<T> : LiteVersionEntity<T>, IFieldModifiedUs
|
||||
/// 创建者编号
|
||||
/// </summary>
|
||||
[Column(CanUpdate = false, Position = -1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? CreatedUserId { get; init; }
|
||||
|
||||
@@ -30,7 +28,6 @@ public abstract record VersionEntity<T> : LiteVersionEntity<T>, IFieldModifiedUs
|
||||
/// 创建者用户名
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31, CanUpdate = false, Position = -1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string CreatedUserName { get; init; }
|
||||
|
||||
@@ -38,14 +35,12 @@ public abstract record VersionEntity<T> : LiteVersionEntity<T>, IFieldModifiedUs
|
||||
/// 唯一编码
|
||||
/// </summary>
|
||||
[Column(IsIdentity = false, IsPrimary = true, Position = 1)]
|
||||
[CsvIgnore]
|
||||
public override T Id { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 修改者编号
|
||||
/// </summary>
|
||||
[Column(CanInsert = false, Position = -1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? ModifiedUserId { get; init; }
|
||||
|
||||
@@ -53,7 +48,6 @@ public abstract record VersionEntity<T> : LiteVersionEntity<T>, IFieldModifiedUs
|
||||
/// 修改者用户名
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31, CanInsert = false, Position = -1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string ModifiedUserName { get; init; }
|
||||
}
|
@@ -4,13 +4,12 @@ namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
/// Api接口表
|
||||
/// </summary>
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_Api))]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(PathCrc32), nameof(PathCrc32), true)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(PathCrc32), nameof(PathCrc32), true)]
|
||||
public record Sys_Api : ImmutableEntity<string>, IFieldSummary
|
||||
{
|
||||
/// <summary>
|
||||
/// 子节点
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(ParentId))]
|
||||
public IEnumerable<Sys_Api> Children { get; init; }
|
||||
@@ -19,7 +18,6 @@ public record Sys_Api : ImmutableEntity<string>, IFieldSummary
|
||||
/// 唯一编码
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127, IsIdentity = false, IsPrimary = true, Position = 1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public override string Id { get; init; }
|
||||
|
||||
@@ -27,7 +25,6 @@ public record Sys_Api : ImmutableEntity<string>, IFieldSummary
|
||||
/// 请求方式
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_15)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Method { get; init; }
|
||||
|
||||
@@ -35,7 +32,6 @@ public record Sys_Api : ImmutableEntity<string>, IFieldSummary
|
||||
/// 服务名称
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Name { get; init; }
|
||||
|
||||
@@ -43,7 +39,6 @@ public record Sys_Api : ImmutableEntity<string>, IFieldSummary
|
||||
/// 命名空间
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
#pragma warning disable CA1716
|
||||
public virtual string Namespace { get; init; }
|
||||
@@ -53,7 +48,6 @@ public record Sys_Api : ImmutableEntity<string>, IFieldSummary
|
||||
/// 父编号
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string ParentId { get; init; }
|
||||
|
||||
@@ -61,14 +55,12 @@ public record Sys_Api : ImmutableEntity<string>, IFieldSummary
|
||||
/// 路径CRC32
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual int PathCrc32 { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 角色集合
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_RoleApi))]
|
||||
public IReadOnlyCollection<Sys_Role> Roles { get; init; }
|
||||
@@ -77,7 +69,6 @@ public record Sys_Api : ImmutableEntity<string>, IFieldSummary
|
||||
/// 服务描述
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Summary { get; set; }
|
||||
}
|
@@ -11,7 +11,6 @@ public record Sys_CodeTemplate : VersionEntity, IFieldSort, IFieldSummary, IFiel
|
||||
/// </summary>
|
||||
/// <example>true</example>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual bool Enabled { get; init; }
|
||||
|
||||
@@ -20,7 +19,6 @@ public record Sys_CodeTemplate : VersionEntity, IFieldSort, IFieldSummary, IFiel
|
||||
/// </summary>
|
||||
/// <example>Male</example>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual Genders? Gender { get; init; }
|
||||
|
||||
@@ -29,7 +27,6 @@ public record Sys_CodeTemplate : VersionEntity, IFieldSort, IFieldSummary, IFiel
|
||||
/// </summary>
|
||||
/// <example>123456</example>
|
||||
[Column(IsIdentity = false, IsPrimary = true, Position = 1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Snowflake]
|
||||
public override long Id { get; init; }
|
||||
@@ -39,14 +36,12 @@ public record Sys_CodeTemplate : VersionEntity, IFieldSort, IFieldSummary, IFiel
|
||||
/// </summary>
|
||||
/// <example>老王</example>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Name { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 归属用户
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(OwnerId))]
|
||||
public Sys_User Owner { get; init; }
|
||||
@@ -56,7 +51,6 @@ public record Sys_CodeTemplate : VersionEntity, IFieldSort, IFieldSummary, IFiel
|
||||
/// </summary>
|
||||
/// <example>370942943322181</example>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerDeptId { get; init; }
|
||||
|
||||
@@ -65,7 +59,6 @@ public record Sys_CodeTemplate : VersionEntity, IFieldSort, IFieldSummary, IFiel
|
||||
/// </summary>
|
||||
/// <example>370942943322181</example>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerId { get; init; }
|
||||
|
||||
@@ -74,7 +67,6 @@ public record Sys_CodeTemplate : VersionEntity, IFieldSort, IFieldSummary, IFiel
|
||||
/// </summary>
|
||||
/// <example>100</example>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long Sort { get; init; }
|
||||
|
||||
@@ -83,7 +75,6 @@ public record Sys_CodeTemplate : VersionEntity, IFieldSort, IFieldSummary, IFiel
|
||||
/// </summary>
|
||||
/// <example>备注文字</example>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Summary { get; set; }
|
||||
}
|
@@ -10,7 +10,6 @@ public record Sys_Config : VersionEntity, IFieldEnabled
|
||||
/// 人民币兑点数比率
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual int CnyToPointRate { get; init; }
|
||||
|
||||
@@ -18,7 +17,6 @@ public record Sys_Config : VersionEntity, IFieldEnabled
|
||||
/// 是否启用
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual bool Enabled { get; init; }
|
||||
|
||||
@@ -26,7 +24,6 @@ public record Sys_Config : VersionEntity, IFieldEnabled
|
||||
/// 必须邀请注册
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual bool RegisterInviteRequired { get; init; }
|
||||
|
||||
@@ -34,7 +31,6 @@ public record Sys_Config : VersionEntity, IFieldEnabled
|
||||
/// 必须手机号注册
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual bool RegisterMobileRequired { get; init; }
|
||||
|
||||
@@ -42,7 +38,6 @@ public record Sys_Config : VersionEntity, IFieldEnabled
|
||||
/// Trc20收款地址
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_CHAR_34)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Trc20ReceiptAddress { get; init; }
|
||||
|
||||
@@ -50,7 +45,6 @@ public record Sys_Config : VersionEntity, IFieldEnabled
|
||||
/// 美元兑点数比率
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual int UsdToPointRate { get; init; }
|
||||
|
||||
@@ -58,14 +52,12 @@ public record Sys_Config : VersionEntity, IFieldEnabled
|
||||
/// 用户注册是否需要人工确认
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual bool UserRegisterConfirm { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 用户注册默认部门
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(UserRegisterDeptId))]
|
||||
public Sys_Dept UserRegisterDept { get; init; }
|
||||
@@ -74,14 +66,12 @@ public record Sys_Config : VersionEntity, IFieldEnabled
|
||||
/// 用户注册默认部门编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long UserRegisterDeptId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 用户注册默认角色
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(UserRegisterRoleId))]
|
||||
public Sys_Role UserRegisterRole { get; init; }
|
||||
@@ -90,7 +80,6 @@ public record Sys_Config : VersionEntity, IFieldEnabled
|
||||
/// 用户注册默认角色编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long UserRegisterRoleId { get; init; }
|
||||
}
|
@@ -1,11 +1,14 @@
|
||||
using NetAdmin.Domain.Enums.Sys;
|
||||
|
||||
namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
|
||||
/// <summary>
|
||||
/// 充值订单表
|
||||
/// </summary>
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_DepositOrder))]
|
||||
[SqlIndex( //
|
||||
$"{Chars.FLG_DB_INDEX_PREFIX}{nameof(ActualPayAmount)}_{nameof(FinishTimestamp)}", $"{nameof(ActualPayAmount)},{nameof(FinishTimestamp)}", true)]
|
||||
[SqlIndex(
|
||||
$"{Chars.FLG_DB_INDEX_PREFIX}{nameof(ActualPayAmount)}_{nameof(FinishTimestamp)}", $"{nameof(ActualPayAmount)},{nameof(FinishTimestamp)}", true
|
||||
)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(PaymentFinger), nameof(PaymentFinger), true, WhenNotNull = true)]
|
||||
public record Sys_DepositOrder : LiteVersionEntity, IFieldOwner
|
||||
{
|
||||
@@ -13,7 +16,6 @@ public record Sys_DepositOrder : LiteVersionEntity, IFieldOwner
|
||||
/// 实际支付金额
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long ActualPayAmount { get; init; }
|
||||
|
||||
@@ -21,7 +23,6 @@ public record Sys_DepositOrder : LiteVersionEntity, IFieldOwner
|
||||
/// 订单状态
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual DepositOrderStatues DepositOrderStatus { get; init; }
|
||||
|
||||
@@ -29,7 +30,6 @@ public record Sys_DepositOrder : LiteVersionEntity, IFieldOwner
|
||||
/// 充值点数
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long DepositPoint { get; init; }
|
||||
|
||||
@@ -37,14 +37,12 @@ public record Sys_DepositOrder : LiteVersionEntity, IFieldOwner
|
||||
/// 完成时间戳
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long FinishTimestamp { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 归属用户
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(OwnerId))]
|
||||
public Sys_User Owner { get; init; }
|
||||
@@ -53,7 +51,6 @@ public record Sys_DepositOrder : LiteVersionEntity, IFieldOwner
|
||||
/// 归属部门编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerDeptId { get; init; }
|
||||
|
||||
@@ -61,7 +58,6 @@ public record Sys_DepositOrder : LiteVersionEntity, IFieldOwner
|
||||
/// 归属用户编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerId { get; init; }
|
||||
|
||||
@@ -69,7 +65,6 @@ public record Sys_DepositOrder : LiteVersionEntity, IFieldOwner
|
||||
/// 付款账号
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string PaidAccount { get; init; }
|
||||
|
||||
@@ -77,7 +72,6 @@ public record Sys_DepositOrder : LiteVersionEntity, IFieldOwner
|
||||
/// 付款时间
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual DateTime? PaidTime { get; init; }
|
||||
|
||||
@@ -85,7 +79,6 @@ public record Sys_DepositOrder : LiteVersionEntity, IFieldOwner
|
||||
/// 付款指纹
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string PaymentFinger { get; init; }
|
||||
|
||||
@@ -93,7 +86,6 @@ public record Sys_DepositOrder : LiteVersionEntity, IFieldOwner
|
||||
/// 支付方式
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual PaymentModes PaymentMode { get; init; }
|
||||
|
||||
@@ -101,7 +93,6 @@ public record Sys_DepositOrder : LiteVersionEntity, IFieldOwner
|
||||
/// 收款账号
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string ReceiptAccount { get; init; }
|
||||
|
||||
@@ -109,7 +100,6 @@ public record Sys_DepositOrder : LiteVersionEntity, IFieldOwner
|
||||
/// 兑点数比率
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual int ToPointRate { get; init; }
|
||||
}
|
@@ -9,7 +9,6 @@ public record Sys_Dept : VersionEntity, IFieldEnabled, IFieldSummary, IFieldSort
|
||||
/// <summary>
|
||||
/// 子节点
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(ParentId))]
|
||||
public IEnumerable<Sys_Dept> Children { get; init; }
|
||||
@@ -18,7 +17,6 @@ public record Sys_Dept : VersionEntity, IFieldEnabled, IFieldSummary, IFieldSort
|
||||
/// 是否启用
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual bool Enabled { get; init; }
|
||||
|
||||
@@ -26,7 +24,6 @@ public record Sys_Dept : VersionEntity, IFieldEnabled, IFieldSummary, IFieldSort
|
||||
/// 部门名称
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Name { get; init; }
|
||||
|
||||
@@ -34,14 +31,12 @@ public record Sys_Dept : VersionEntity, IFieldEnabled, IFieldSummary, IFieldSort
|
||||
/// 父编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long ParentId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 角色集合
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_RoleDept))]
|
||||
public IReadOnlyCollection<Sys_Role> Roles { get; init; }
|
||||
@@ -49,7 +44,6 @@ public record Sys_Dept : VersionEntity, IFieldEnabled, IFieldSummary, IFieldSort
|
||||
/// <summary>
|
||||
/// 发送给此部门的站内信集合
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_SiteMsgDept))]
|
||||
public IReadOnlyCollection<Sys_SiteMsg> SiteMsgs { get; init; }
|
||||
@@ -58,7 +52,6 @@ public record Sys_Dept : VersionEntity, IFieldEnabled, IFieldSummary, IFieldSort
|
||||
/// 排序值,越大越前
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long Sort { get; init; }
|
||||
|
||||
@@ -66,7 +59,6 @@ public record Sys_Dept : VersionEntity, IFieldEnabled, IFieldSummary, IFieldSort
|
||||
/// 部门备注
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Summary { get; set; }
|
||||
}
|
@@ -3,14 +3,13 @@ namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
/// <summary>
|
||||
/// 字典目录表
|
||||
/// </summary>
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(Code), nameof(Code), true)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(Code), nameof(Code), true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_DicCatalog))]
|
||||
public record Sys_DicCatalog : VersionEntity
|
||||
{
|
||||
/// <summary>
|
||||
/// 子节点
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(ParentId))]
|
||||
public IEnumerable<Sys_DicCatalog> Children { get; init; }
|
||||
@@ -19,14 +18,12 @@ public record Sys_DicCatalog : VersionEntity
|
||||
/// 字典目录编码
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Code { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 字典内容集合
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(Sys_DicContent.CatalogId))]
|
||||
public IReadOnlyCollection<Sys_DicContent> Contents { get; init; }
|
||||
@@ -35,7 +32,6 @@ public record Sys_DicCatalog : VersionEntity
|
||||
/// 字典目录名称
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Name { get; init; }
|
||||
|
||||
@@ -43,7 +39,6 @@ public record Sys_DicCatalog : VersionEntity
|
||||
/// 父编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long ParentId { get; init; }
|
||||
}
|
@@ -10,7 +10,6 @@ public record Sys_DicContent : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// <summary>
|
||||
/// 字典目录
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(CatalogId))]
|
||||
public Sys_DicCatalog Catalog { get; init; }
|
||||
@@ -19,7 +18,6 @@ public record Sys_DicContent : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 字典目录编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long CatalogId { get; init; }
|
||||
|
||||
@@ -27,7 +25,6 @@ public record Sys_DicContent : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 是否启用
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual bool Enabled { get; init; }
|
||||
|
||||
@@ -35,7 +32,6 @@ public record Sys_DicContent : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 键名称
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Key { get; init; }
|
||||
|
||||
@@ -43,7 +39,6 @@ public record Sys_DicContent : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 备注
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Summary { get; set; }
|
||||
|
||||
@@ -51,7 +46,6 @@ public record Sys_DicContent : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 键值
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Value { get; init; }
|
||||
}
|
@@ -3,14 +3,13 @@ namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
/// <summary>
|
||||
/// 文档分类表
|
||||
/// </summary>
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(Code), nameof(Code), true)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(Code), nameof(Code), true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_DocCatalog))]
|
||||
public record Sys_DocCatalog : VersionEntity, IFieldOwner
|
||||
{
|
||||
/// <summary>
|
||||
/// 子节点
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(ParentId))]
|
||||
public IEnumerable<Sys_DocCatalog> Children { get; init; }
|
||||
@@ -19,14 +18,12 @@ public record Sys_DocCatalog : VersionEntity, IFieldOwner
|
||||
/// 文档分类编码
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Code { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 文档内容集合
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(Sys_DocContent.CatalogId))]
|
||||
public IReadOnlyCollection<Sys_DocContent> Contents { get; init; }
|
||||
@@ -35,14 +32,12 @@ public record Sys_DocCatalog : VersionEntity, IFieldOwner
|
||||
/// 文档分类名称
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Name { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 归属用户
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(OwnerId))]
|
||||
public Sys_User Owner { get; init; }
|
||||
@@ -51,7 +46,6 @@ public record Sys_DocCatalog : VersionEntity, IFieldOwner
|
||||
/// 归属部门编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerDeptId { get; init; }
|
||||
|
||||
@@ -59,7 +53,6 @@ public record Sys_DocCatalog : VersionEntity, IFieldOwner
|
||||
/// 归属用户编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerId { get; init; }
|
||||
|
||||
@@ -67,7 +60,6 @@ public record Sys_DocCatalog : VersionEntity, IFieldOwner
|
||||
/// 父编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long ParentId { get; init; }
|
||||
}
|
@@ -12,14 +12,12 @@ public record Sys_DocContent : VersionEntity, IFieldEnabled, IFieldOwner
|
||||
/// 文档正文
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Body { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 文档分类
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(CatalogId))]
|
||||
public Sys_DocCatalog Catalog { get; init; }
|
||||
@@ -28,7 +26,6 @@ public record Sys_DocContent : VersionEntity, IFieldEnabled, IFieldOwner
|
||||
/// 文档分类编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long CatalogId { get; init; }
|
||||
|
||||
@@ -36,14 +33,12 @@ public record Sys_DocContent : VersionEntity, IFieldEnabled, IFieldOwner
|
||||
/// 是否启用
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual bool Enabled { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 归属用户
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(OwnerId))]
|
||||
public Sys_User Owner { get; init; }
|
||||
@@ -52,7 +47,6 @@ public record Sys_DocContent : VersionEntity, IFieldEnabled, IFieldOwner
|
||||
/// 归属部门编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerDeptId { get; init; }
|
||||
|
||||
@@ -60,7 +54,6 @@ public record Sys_DocContent : VersionEntity, IFieldEnabled, IFieldOwner
|
||||
/// 归属用户编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerId { get; init; }
|
||||
|
||||
@@ -68,7 +61,6 @@ public record Sys_DocContent : VersionEntity, IFieldEnabled, IFieldOwner
|
||||
/// 文档标题
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Title { get; init; }
|
||||
|
||||
@@ -76,7 +68,6 @@ public record Sys_DocContent : VersionEntity, IFieldEnabled, IFieldOwner
|
||||
/// 可见性
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual ArchiveVisibilities Visibility { get; init; }
|
||||
}
|
@@ -12,7 +12,6 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 是否启用
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual bool Enabled { get; init; }
|
||||
|
||||
@@ -20,7 +19,6 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 执行时间计划
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string ExecutionCron { get; init; }
|
||||
|
||||
@@ -28,7 +26,6 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 请求方法
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual HttpMethods HttpMethod { get; init; }
|
||||
|
||||
@@ -36,7 +33,6 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 作业名称
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string JobName { get; init; }
|
||||
|
||||
@@ -44,7 +40,6 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 上次执行耗时
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? LastDuration { get; init; }
|
||||
|
||||
@@ -52,7 +47,6 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 上次执行时间
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual DateTime? LastExecTime { get; init; }
|
||||
|
||||
@@ -60,7 +54,6 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 上次执行状态
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_SMALL_INT)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public int? LastStatusCode { get; init; }
|
||||
|
||||
@@ -68,7 +61,6 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 下次执行时间
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual DateTime? NextExecTime { get; init; }
|
||||
|
||||
@@ -76,7 +68,6 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 下次执行时间编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? NextTimeId { get; init; }
|
||||
|
||||
@@ -84,7 +75,6 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 随机延时起始值(毫秒)
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual int? RandomDelayBegin { get; init; }
|
||||
|
||||
@@ -92,7 +82,6 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 随机延时结束值(毫秒)
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual int? RandomDelayEnd { get; init; }
|
||||
|
||||
@@ -100,7 +89,6 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 请求体
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestBody { get; init; }
|
||||
|
||||
@@ -108,7 +96,6 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 请求头
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestHeader { get; init; }
|
||||
|
||||
@@ -116,7 +103,6 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 请求的网络地址
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestUrl { get; init; }
|
||||
|
||||
@@ -124,7 +110,6 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 作业状态
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual JobStatues Status { get; init; }
|
||||
|
||||
@@ -132,14 +117,12 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 备注
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Summary { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 执行用户
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(UserId))]
|
||||
public Sys_User User { get; init; }
|
||||
@@ -148,7 +131,6 @@ public record Sys_Job : VersionEntity, IFieldEnabled, IFieldSummary
|
||||
/// 执行用户编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long UserId { get; init; }
|
||||
}
|
@@ -4,9 +4,9 @@ namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
/// 计划作业执行记录表
|
||||
/// </summary>
|
||||
[SqlIndex($"{Chars.FLG_DB_INDEX_PREFIX}{nameof(JobId)}_{nameof(TimeId)}", $"{nameof(JobId)},{nameof(TimeId)}", true)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(CreatedTime), $"{nameof(CreatedTime)} DESC", false)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(JobId), nameof(JobId), false)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(HttpStatusCode), nameof(HttpStatusCode), false)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(CreatedTime), $"{nameof(CreatedTime)} DESC", false)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(JobId), nameof(JobId), false)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(HttpStatusCode), nameof(HttpStatusCode), false)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_JobRecord))]
|
||||
public record Sys_JobRecord : LiteImmutableEntity
|
||||
{
|
||||
@@ -14,7 +14,6 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
/// 执行耗时(毫秒)
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long Duration { get; init; }
|
||||
|
||||
@@ -22,7 +21,6 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
/// 请求方法
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual HttpMethods HttpMethod { get; init; }
|
||||
|
||||
@@ -30,14 +28,12 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
/// HTTP 状态码
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public int HttpStatusCode { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 归属信息
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(JobId))]
|
||||
public Sys_Job Job { get; init; }
|
||||
@@ -46,7 +42,6 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
/// 作业编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long JobId { get; init; }
|
||||
|
||||
@@ -54,7 +49,6 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
/// 请求体
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestBody { get; init; }
|
||||
|
||||
@@ -62,7 +56,6 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
/// 请求头
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestHeader { get; init; }
|
||||
|
||||
@@ -70,7 +63,6 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
/// 请求的网络地址
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestUrl { get; init; }
|
||||
|
||||
@@ -78,7 +70,6 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
/// 响应体
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string ResponseBody { get; init; }
|
||||
|
||||
@@ -86,7 +77,6 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
/// 响应头
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string ResponseHeader { get; init; }
|
||||
|
||||
@@ -94,7 +84,6 @@ public record Sys_JobRecord : LiteImmutableEntity
|
||||
/// 执行时间编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long TimeId { get; init; }
|
||||
}
|
@@ -3,9 +3,9 @@ namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
/// <summary>
|
||||
/// 登录日志表
|
||||
/// </summary>
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(CreatedTime), $"{nameof(CreatedTime)} DESC", false)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(HttpStatusCode), nameof(HttpStatusCode), false)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(OwnerId), nameof(OwnerId), false)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(CreatedTime), $"{nameof(CreatedTime)} DESC", false)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(HttpStatusCode), nameof(HttpStatusCode), false)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(OwnerId), nameof(OwnerId), false)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_LoginLog))]
|
||||
public record Sys_LoginLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFieldCreatedClientIp, IFieldCreatedClientUserAgent
|
||||
{
|
||||
@@ -13,7 +13,6 @@ public record Sys_LoginLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFiel
|
||||
/// 创建者客户端IP
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual int? CreatedClientIp { get; init; }
|
||||
|
||||
@@ -21,7 +20,6 @@ public record Sys_LoginLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFiel
|
||||
/// 创建时间
|
||||
/// </summary>
|
||||
[Column(ServerTime = DateTimeKind.Local, CanUpdate = false, Position = -1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual DateTime CreatedTime { get; init; }
|
||||
|
||||
@@ -29,7 +27,6 @@ public record Sys_LoginLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFiel
|
||||
/// 创建者客户端用户代理
|
||||
/// </summary>
|
||||
[Column(Position = -1, DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_1022)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string CreatedUserAgent { get; init; }
|
||||
|
||||
@@ -37,7 +34,6 @@ public record Sys_LoginLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFiel
|
||||
/// 执行耗时(毫秒)
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual int Duration { get; protected init; }
|
||||
|
||||
@@ -45,7 +41,6 @@ public record Sys_LoginLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFiel
|
||||
/// 程序响应码
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual ErrorCodes ErrorCode { get; protected init; }
|
||||
|
||||
@@ -53,7 +48,6 @@ public record Sys_LoginLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFiel
|
||||
/// HTTP状态码
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_SMALL_INT)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual int HttpStatusCode { get; init; }
|
||||
|
||||
@@ -61,14 +55,12 @@ public record Sys_LoginLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFiel
|
||||
/// 登录用户名
|
||||
/// </summary>
|
||||
[Column(Position = -1, DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string LoginUserName { get; protected init; }
|
||||
|
||||
/// <summary>
|
||||
/// 归属用户
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(OwnerId))]
|
||||
public Sys_User Owner { get; init; }
|
||||
@@ -77,7 +69,6 @@ public record Sys_LoginLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFiel
|
||||
/// 归属部门编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerDeptId { get; init; }
|
||||
|
||||
@@ -85,7 +76,6 @@ public record Sys_LoginLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFiel
|
||||
/// 归属用户编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerId { get; init; }
|
||||
|
||||
@@ -93,7 +83,6 @@ public record Sys_LoginLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFiel
|
||||
/// 请求内容
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestBody { get; protected init; }
|
||||
|
||||
@@ -101,7 +90,6 @@ public record Sys_LoginLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFiel
|
||||
/// 请求头信息
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestHeaders { get; protected init; }
|
||||
|
||||
@@ -109,7 +97,6 @@ public record Sys_LoginLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFiel
|
||||
/// 请求地址
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestUrl { get; protected init; }
|
||||
|
||||
@@ -117,7 +104,6 @@ public record Sys_LoginLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFiel
|
||||
/// 响应内容
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string ResponseBody { get; protected init; }
|
||||
|
||||
@@ -125,7 +111,6 @@ public record Sys_LoginLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFiel
|
||||
/// 响应头
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string ResponseHeaders { get; protected init; }
|
||||
|
||||
@@ -133,7 +118,6 @@ public record Sys_LoginLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFiel
|
||||
/// 服务器IP
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual int? ServerIp { get; protected init; }
|
||||
}
|
@@ -5,7 +5,7 @@ namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
/// <summary>
|
||||
/// 菜单表
|
||||
/// </summary>
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(Name), nameof(Name), true)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(Name), nameof(Name), true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_Menu))]
|
||||
public record Sys_Menu : VersionEntity, IFieldSort
|
||||
{
|
||||
@@ -13,14 +13,12 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 子节点或详情页需要高亮的上级菜单路由地址
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Active { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 子节点
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(ParentId))]
|
||||
public IEnumerable<Sys_Menu> Children { get; init; }
|
||||
@@ -29,7 +27,6 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 背景颜色
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_7)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Color { get; init; }
|
||||
|
||||
@@ -37,7 +34,6 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 组件
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Component { get; init; }
|
||||
|
||||
@@ -45,7 +41,6 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 是否整页路由
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual bool FullPageRouting { get; init; }
|
||||
|
||||
@@ -53,7 +48,6 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 是否隐藏菜单
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual bool Hidden { get; init; }
|
||||
|
||||
@@ -61,7 +55,6 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 是否隐藏面包屑
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual bool HiddenBreadCrumb { get; init; }
|
||||
|
||||
@@ -69,7 +62,6 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 图标
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Icon { get; init; }
|
||||
|
||||
@@ -77,7 +69,6 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 菜单名称
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Name { get; init; }
|
||||
|
||||
@@ -85,7 +76,6 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 父编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long ParentId { get; init; }
|
||||
|
||||
@@ -93,7 +83,6 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 菜单路径
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Path { get; init; }
|
||||
|
||||
@@ -101,14 +90,12 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 重定向地址
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Redirect { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 拥有此菜单的角色集合
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_RoleMenu))]
|
||||
public IReadOnlyCollection<Sys_Role> Roles { get; init; }
|
||||
@@ -117,7 +104,6 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 排序值,越大越前
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long Sort { get; init; }
|
||||
|
||||
@@ -125,7 +111,6 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 标签
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Tag { get; init; }
|
||||
|
||||
@@ -133,7 +118,6 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 菜单标题
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Title { get; init; }
|
||||
|
||||
@@ -141,7 +125,6 @@ public record Sys_Menu : VersionEntity, IFieldSort
|
||||
/// 菜单类型
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual MenuTypes Type { get; init; }
|
||||
}
|
@@ -3,18 +3,16 @@ namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
/// <summary>
|
||||
/// 请求日志表
|
||||
/// </summary>
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(ApiPathCrc32), nameof(ApiPathCrc32), false)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(CreatedTime), $"{nameof(CreatedTime)} DESC", false)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(OwnerId), nameof(OwnerId), false)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(HttpStatusCode), nameof(HttpStatusCode), false)]
|
||||
[Table( //
|
||||
Name = $"{Chars.FLG_DB_TABLE_NAME_PREFIX}{nameof(Sys_RequestLog)}_{{yyyyMMdd}}", AsTable = $"{nameof(CreatedTime)}=2024-5-1(1 day)")]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(ApiPathCrc32), nameof(ApiPathCrc32), false)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(CreatedTime), $"{nameof(CreatedTime)} DESC", false)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(OwnerId), nameof(OwnerId), false)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(HttpStatusCode), nameof(HttpStatusCode), false)]
|
||||
[Table(Name = $"{Chars.FLG_DB_TABLE_NAME_PREFIX}{nameof(Sys_RequestLog)}_{{yyyyMMdd}}", AsTable = $"{nameof(CreatedTime)}=2024-5-1(1 day)")]
|
||||
public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFieldCreatedClientIp
|
||||
{
|
||||
/// <summary>
|
||||
/// 接口
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(ApiPathCrc32), TempPrimary = nameof(Sys_Api.PathCrc32))]
|
||||
public Sys_Api Api { get; init; }
|
||||
@@ -23,7 +21,6 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFi
|
||||
/// 接口路径CRC32
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual int ApiPathCrc32 { get; init; }
|
||||
|
||||
@@ -31,7 +28,6 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFi
|
||||
/// 创建者客户端IP
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual int? CreatedClientIp { get; init; }
|
||||
|
||||
@@ -39,14 +35,12 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFi
|
||||
/// 创建时间
|
||||
/// </summary>
|
||||
[Column(ServerTime = DateTimeKind.Local, CanUpdate = false, Position = -1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual DateTime CreatedTime { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 明细
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(Id))]
|
||||
public Sys_RequestLogDetail Detail { get; init; }
|
||||
@@ -55,7 +49,6 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFi
|
||||
/// 执行耗时(毫秒)
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual int Duration { get; init; }
|
||||
|
||||
@@ -63,7 +56,6 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFi
|
||||
/// 请求方法
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_TINY_INT)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual HttpMethods HttpMethod { get; init; }
|
||||
|
||||
@@ -71,14 +63,12 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFi
|
||||
/// HTTP状态码
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_SMALL_INT)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual int HttpStatusCode { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 归属用户
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(OwnerId))]
|
||||
public Sys_User Owner { get; init; }
|
||||
@@ -87,7 +77,6 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFi
|
||||
/// 归属部门编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerDeptId { get; init; }
|
||||
|
||||
@@ -95,7 +84,6 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFi
|
||||
/// 归属用户编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerId { get; init; }
|
||||
|
||||
@@ -103,7 +91,6 @@ public record Sys_RequestLog : SimpleEntity, IFieldCreatedTime, IFieldOwner, IFi
|
||||
/// 请求追踪标识
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual Guid TraceId { get; init; }
|
||||
}
|
@@ -4,14 +4,13 @@ namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
/// 请求日志明细表
|
||||
/// </summary>
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_RequestLogDetail))]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(CreatedTime), $"{nameof(CreatedTime)} DESC", false)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(CreatedTime), $"{nameof(CreatedTime)} DESC", false)]
|
||||
public record Sys_RequestLogDetail : SimpleEntity, IFieldCreatedTime, IFieldCreatedClientUserAgent
|
||||
{
|
||||
/// <summary>
|
||||
/// 创建时间
|
||||
/// </summary>
|
||||
[Column(ServerTime = DateTimeKind.Local, CanUpdate = false, Position = -1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual DateTime CreatedTime { get; init; }
|
||||
|
||||
@@ -19,7 +18,6 @@ public record Sys_RequestLogDetail : SimpleEntity, IFieldCreatedTime, IFieldCrea
|
||||
/// 创建者客户端用户代理
|
||||
/// </summary>
|
||||
[Column(Position = -1, DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_1022)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string CreatedUserAgent { get; init; }
|
||||
|
||||
@@ -27,7 +25,6 @@ public record Sys_RequestLogDetail : SimpleEntity, IFieldCreatedTime, IFieldCrea
|
||||
/// 程序响应码
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual ErrorCodes ErrorCode { get; init; }
|
||||
|
||||
@@ -35,7 +32,6 @@ public record Sys_RequestLogDetail : SimpleEntity, IFieldCreatedTime, IFieldCrea
|
||||
/// 异常信息
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Exception { get; init; }
|
||||
|
||||
@@ -43,7 +39,6 @@ public record Sys_RequestLogDetail : SimpleEntity, IFieldCreatedTime, IFieldCrea
|
||||
/// 请求内容
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestBody { get; init; }
|
||||
|
||||
@@ -51,7 +46,6 @@ public record Sys_RequestLogDetail : SimpleEntity, IFieldCreatedTime, IFieldCrea
|
||||
/// 请求content-type
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestContentType { get; init; }
|
||||
|
||||
@@ -59,7 +53,6 @@ public record Sys_RequestLogDetail : SimpleEntity, IFieldCreatedTime, IFieldCrea
|
||||
/// 请求头信息
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestHeaders { get; init; }
|
||||
|
||||
@@ -67,7 +60,6 @@ public record Sys_RequestLogDetail : SimpleEntity, IFieldCreatedTime, IFieldCrea
|
||||
/// 请求地址
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string RequestUrl { get; init; }
|
||||
|
||||
@@ -75,7 +67,6 @@ public record Sys_RequestLogDetail : SimpleEntity, IFieldCreatedTime, IFieldCrea
|
||||
/// 响应内容
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string ResponseBody { get; init; }
|
||||
|
||||
@@ -83,7 +74,6 @@ public record Sys_RequestLogDetail : SimpleEntity, IFieldCreatedTime, IFieldCrea
|
||||
/// 响应content-type
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string ResponseContentType { get; init; }
|
||||
|
||||
@@ -91,7 +81,6 @@ public record Sys_RequestLogDetail : SimpleEntity, IFieldCreatedTime, IFieldCrea
|
||||
/// 响应头
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string ResponseHeaders { get; init; }
|
||||
|
||||
@@ -99,7 +88,6 @@ public record Sys_RequestLogDetail : SimpleEntity, IFieldCreatedTime, IFieldCrea
|
||||
/// 服务器IP
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual int? ServerIp { get; init; }
|
||||
}
|
@@ -6,14 +6,13 @@ namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
/// <summary>
|
||||
/// 角色表
|
||||
/// </summary>
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(Name), nameof(Name), true)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(Name), nameof(Name), true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_Role))]
|
||||
public record Sys_Role : VersionEntity, IFieldSort, IFieldEnabled, IFieldSummary, IRegister
|
||||
{
|
||||
/// <summary>
|
||||
/// 角色-接口映射
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_RoleApi))]
|
||||
public IReadOnlyCollection<Sys_Api> Apis { get; init; }
|
||||
@@ -22,7 +21,6 @@ public record Sys_Role : VersionEntity, IFieldSort, IFieldEnabled, IFieldSummary
|
||||
/// 仪表板布局
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string DashboardLayout { get; set; }
|
||||
|
||||
@@ -30,14 +28,12 @@ public record Sys_Role : VersionEntity, IFieldSort, IFieldEnabled, IFieldSummary
|
||||
/// 数据范围
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual DataScopes DataScope { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 角色-部门映射
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_RoleDept))]
|
||||
public IReadOnlyCollection<Sys_Dept> Depts { get; init; }
|
||||
@@ -46,7 +42,6 @@ public record Sys_Role : VersionEntity, IFieldSort, IFieldEnabled, IFieldSummary
|
||||
/// 是否显示仪表板
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual bool DisplayDashboard { get; init; }
|
||||
|
||||
@@ -54,7 +49,6 @@ public record Sys_Role : VersionEntity, IFieldSort, IFieldEnabled, IFieldSummary
|
||||
/// 是否启用
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual bool Enabled { get; init; }
|
||||
|
||||
@@ -62,14 +56,12 @@ public record Sys_Role : VersionEntity, IFieldSort, IFieldEnabled, IFieldSummary
|
||||
/// 是否忽略权限控制
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual bool IgnorePermissionControl { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 角色-菜单映射
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_RoleMenu))]
|
||||
public IReadOnlyCollection<Sys_Menu> Menus { get; init; }
|
||||
@@ -78,14 +70,12 @@ public record Sys_Role : VersionEntity, IFieldSort, IFieldEnabled, IFieldSummary
|
||||
/// 角色名称
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Name { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 发送给此角色的站内信集合
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_SiteMsgRole))]
|
||||
public IReadOnlyCollection<Sys_SiteMsg> SiteMsgs { get; init; }
|
||||
@@ -94,7 +84,6 @@ public record Sys_Role : VersionEntity, IFieldSort, IFieldEnabled, IFieldSummary
|
||||
/// 排序值,越大越前
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long Sort { get; init; }
|
||||
|
||||
@@ -102,35 +91,25 @@ public record Sys_Role : VersionEntity, IFieldSort, IFieldEnabled, IFieldSummary
|
||||
/// 备注
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Summary { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 此角色下的用户集合
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_UserRole))]
|
||||
public IReadOnlyCollection<Sys_User> Users { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
public virtual void Register(TypeAdapterConfig config)
|
||||
{
|
||||
public virtual void Register(TypeAdapterConfig config) {
|
||||
// ReSharper disable InvokeAsExtensionMethod
|
||||
#pragma warning disable RCS1196
|
||||
|
||||
_ = config.ForType<CreateRoleReq, Sys_Role>()
|
||||
.Map( //
|
||||
d => d.Depts
|
||||
, s => s.DeptIds.NullOrEmpty() ? Array.Empty<Sys_Dept>() : Enumerable.Select(s.DeptIds, x => new Sys_Dept { Id = x }))
|
||||
.Map( //
|
||||
d => d.Menus
|
||||
, s => s.MenuIds.NullOrEmpty() ? Array.Empty<Sys_Menu>() : Enumerable.Select(s.MenuIds, x => new Sys_Menu { Id = x }))
|
||||
.Map( //
|
||||
d => d.Apis, s => s.ApiIds.NullOrEmpty() ? Array.Empty<Sys_Api>() : Enumerable.Select(s.ApiIds, x => new Sys_Api { Id = x }))
|
||||
|
||||
//
|
||||
;
|
||||
_ = config
|
||||
.ForType<CreateRoleReq, Sys_Role>()
|
||||
.Map(d => d.Depts, s => s.DeptIds.NullOrEmpty() ? Array.Empty<Sys_Dept>() : Enumerable.Select(s.DeptIds, x => new Sys_Dept { Id = x }))
|
||||
.Map(d => d.Menus, s => s.MenuIds.NullOrEmpty() ? Array.Empty<Sys_Menu>() : Enumerable.Select(s.MenuIds, x => new Sys_Menu { Id = x }))
|
||||
.Map(d => d.Apis, s => s.ApiIds.NullOrEmpty() ? Array.Empty<Sys_Api>() : Enumerable.Select(s.ApiIds, x => new Sys_Api { Id = x }));
|
||||
}
|
||||
}
|
@@ -9,7 +9,6 @@ public record Sys_RoleApi : ImmutableEntity
|
||||
/// <summary>
|
||||
/// 关联的接口
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public Sys_Api Api { get; init; }
|
||||
|
||||
@@ -17,14 +16,12 @@ public record Sys_RoleApi : ImmutableEntity
|
||||
/// 接口编号
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public string ApiId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 关联的角色
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public Sys_Role Role { get; init; }
|
||||
|
||||
@@ -32,7 +29,6 @@ public record Sys_RoleApi : ImmutableEntity
|
||||
/// 角色编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public long RoleId { get; init; }
|
||||
}
|
@@ -10,7 +10,6 @@ public record Sys_RoleDept : ImmutableEntity
|
||||
/// <summary>
|
||||
/// 关联的部门
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public Sys_Dept Dept { get; init; }
|
||||
|
||||
@@ -18,14 +17,12 @@ public record Sys_RoleDept : ImmutableEntity
|
||||
/// 可访问的部门编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public long DeptId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 关联的角色
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public Sys_Role Role { get; init; }
|
||||
|
||||
@@ -33,7 +30,6 @@ public record Sys_RoleDept : ImmutableEntity
|
||||
/// 角色编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public long RoleId { get; init; }
|
||||
}
|
@@ -10,7 +10,6 @@ public record Sys_RoleMenu : ImmutableEntity
|
||||
/// <summary>
|
||||
/// 关联的菜单
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public Sys_Menu Menu { get; init; }
|
||||
|
||||
@@ -18,14 +17,12 @@ public record Sys_RoleMenu : ImmutableEntity
|
||||
/// 菜单编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long MenuId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 关联的角色
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public Sys_Role Role { get; init; }
|
||||
|
||||
@@ -33,7 +30,6 @@ public record Sys_RoleMenu : ImmutableEntity
|
||||
/// 角色编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long RoleId { get; init; }
|
||||
}
|
@@ -13,14 +13,12 @@ public record Sys_SiteMsg : VersionEntity, IRegister, IFieldSummary
|
||||
/// 消息内容
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Content { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 消息-创建者映射
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(CreatedUserId))]
|
||||
public Sys_User Creator { get; init; }
|
||||
@@ -28,7 +26,6 @@ public record Sys_SiteMsg : VersionEntity, IRegister, IFieldSummary
|
||||
/// <summary>
|
||||
/// 消息-部门映射
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_SiteMsgDept))]
|
||||
public IReadOnlyCollection<Sys_Dept> Depts { get; init; }
|
||||
@@ -36,7 +33,6 @@ public record Sys_SiteMsg : VersionEntity, IRegister, IFieldSummary
|
||||
/// <summary>
|
||||
/// 消息-标记映射
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(Sys_SiteMsgFlag.SiteMsgId))]
|
||||
public IReadOnlyCollection<Sys_SiteMsgFlag> Flags { get; init; }
|
||||
@@ -44,14 +40,12 @@ public record Sys_SiteMsg : VersionEntity, IRegister, IFieldSummary
|
||||
/// <summary>
|
||||
/// 消息类型
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual SiteMsgTypes MsgType { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 消息-角色映射
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_SiteMsgRole))]
|
||||
public IReadOnlyCollection<Sys_Role> Roles { get; init; }
|
||||
@@ -60,7 +54,6 @@ public record Sys_SiteMsg : VersionEntity, IRegister, IFieldSummary
|
||||
/// 消息摘要
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Summary { get; set; }
|
||||
|
||||
@@ -68,39 +61,27 @@ public record Sys_SiteMsg : VersionEntity, IRegister, IFieldSummary
|
||||
/// 消息主题
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Title { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 消息-用户映射
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_SiteMsgUser))]
|
||||
public IReadOnlyCollection<Sys_User> Users { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
public void Register(TypeAdapterConfig config)
|
||||
{
|
||||
public void Register(TypeAdapterConfig config) {
|
||||
#pragma warning disable RCS1196
|
||||
|
||||
// ReSharper disable InvokeAsExtensionMethod
|
||||
_ = config.ForType<CreateSiteMsgReq, Sys_SiteMsg>()
|
||||
.Map( //
|
||||
d => d.Summary, s => s.Content.RemoveHtmlTag().HtmlDe().Sub(0, 100))
|
||||
.Map( //
|
||||
d => d.Roles
|
||||
, s => s.RoleIds.NullOrEmpty() ? Array.Empty<Sys_Role>() : Enumerable.Select(s.RoleIds, x => new Sys_Role { Id = x }))
|
||||
.Map( //
|
||||
d => d.Users
|
||||
, s => s.UserIds.NullOrEmpty() ? Array.Empty<Sys_User>() : Enumerable.Select(s.UserIds, x => new Sys_User { Id = x }))
|
||||
.Map( //
|
||||
d => d.Depts
|
||||
, s => s.DeptIds.NullOrEmpty() ? Array.Empty<Sys_Dept>() : Enumerable.Select(s.DeptIds, x => new Sys_Dept { Id = x }))
|
||||
|
||||
//
|
||||
;
|
||||
_ = config
|
||||
.ForType<CreateSiteMsgReq, Sys_SiteMsg>()
|
||||
.Map(d => d.Summary, s => s.Content.RemoveHtmlTag().HtmlDe().Sub(0, 100))
|
||||
.Map(d => d.Roles, s => s.RoleIds.NullOrEmpty() ? Array.Empty<Sys_Role>() : Enumerable.Select(s.RoleIds, x => new Sys_Role { Id = x }))
|
||||
.Map(d => d.Users, s => s.UserIds.NullOrEmpty() ? Array.Empty<Sys_User>() : Enumerable.Select(s.UserIds, x => new Sys_User { Id = x }))
|
||||
.Map(d => d.Depts, s => s.DeptIds.NullOrEmpty() ? Array.Empty<Sys_Dept>() : Enumerable.Select(s.DeptIds, x => new Sys_Dept { Id = x }));
|
||||
|
||||
// ReSharper restore InvokeAsExtensionMethod
|
||||
#pragma warning restore RCS1196
|
||||
|
@@ -10,7 +10,6 @@ public record Sys_SiteMsgDept : ImmutableEntity
|
||||
/// <summary>
|
||||
/// 关联的部门
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public Sys_Dept Dept { get; init; }
|
||||
|
||||
@@ -18,14 +17,12 @@ public record Sys_SiteMsgDept : ImmutableEntity
|
||||
/// 部门编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public long DeptId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 关联的站内信
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public Sys_SiteMsg SiteMsg { get; init; }
|
||||
|
||||
@@ -33,7 +30,6 @@ public record Sys_SiteMsgDept : ImmutableEntity
|
||||
/// 站内信编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public long SiteMsgId { get; init; }
|
||||
}
|
@@ -13,7 +13,6 @@ public record Sys_SiteMsgFlag : MutableEntity
|
||||
/// 站内信编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long SiteMsgId { get; init; }
|
||||
|
||||
@@ -21,7 +20,6 @@ public record Sys_SiteMsgFlag : MutableEntity
|
||||
/// 用户编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public long UserId { get; init; }
|
||||
|
||||
@@ -29,7 +27,6 @@ public record Sys_SiteMsgFlag : MutableEntity
|
||||
/// 用户站内信状态
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual UserSiteMsgStatues UserSiteMsgStatus { get; init; }
|
||||
}
|
@@ -10,7 +10,6 @@ public record Sys_SiteMsgRole : ImmutableEntity
|
||||
/// <summary>
|
||||
/// 关联的角色
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public Sys_Role Role { get; init; }
|
||||
|
||||
@@ -18,14 +17,12 @@ public record Sys_SiteMsgRole : ImmutableEntity
|
||||
/// 角色编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public long RoleId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 关联的站内信
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public Sys_SiteMsg SiteMsg { get; init; }
|
||||
|
||||
@@ -33,7 +30,6 @@ public record Sys_SiteMsgRole : ImmutableEntity
|
||||
/// 站内信编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public long SiteMsgId { get; init; }
|
||||
}
|
@@ -10,7 +10,6 @@ public record Sys_SiteMsgUser : ImmutableEntity
|
||||
/// <summary>
|
||||
/// 关联的站内信
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public Sys_SiteMsg SiteMsg { get; init; }
|
||||
|
||||
@@ -18,14 +17,12 @@ public record Sys_SiteMsgUser : ImmutableEntity
|
||||
/// 站内信编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public long SiteMsgId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 关联的用户
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public Sys_User User { get; init; }
|
||||
|
||||
@@ -33,7 +30,6 @@ public record Sys_SiteMsgUser : ImmutableEntity
|
||||
/// 用户编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public long UserId { get; init; }
|
||||
}
|
@@ -5,10 +5,10 @@ namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
/// <summary>
|
||||
/// 用户基本信息表
|
||||
/// </summary>
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(Email), nameof(Email), true)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(Mobile), nameof(Mobile), true)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(InviteCode), nameof(InviteCode), true)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(UserName), nameof(UserName), true)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(Email), nameof(Email), true)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(Mobile), nameof(Mobile), true)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(InviteCode), nameof(InviteCode), true)]
|
||||
[SqlIndex(Chars.FLG_DB_INDEX_PREFIX + nameof(UserName), nameof(UserName), true)]
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_User))]
|
||||
public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
{
|
||||
@@ -16,14 +16,12 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 头像链接
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Avatar { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 归属部门
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(DeptId))]
|
||||
public Sys_Dept Dept { get; init; }
|
||||
@@ -32,7 +30,6 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 部门编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long DeptId { get; init; }
|
||||
|
||||
@@ -40,7 +37,6 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 邮箱
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Email { get; init; }
|
||||
|
||||
@@ -48,14 +44,12 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 是否启用
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual bool Enabled { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 用户邀请
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public Sys_UserInvite Invite { get; init; }
|
||||
|
||||
@@ -63,7 +57,6 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 邀请码
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_CHAR_6)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string InviteCode { get; init; }
|
||||
|
||||
@@ -71,7 +64,6 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 最后登录时间
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual DateTime? LastLoginTime { get; init; }
|
||||
|
||||
@@ -79,7 +71,6 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 手机号码
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_15)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Mobile { get; init; }
|
||||
|
||||
@@ -87,7 +78,6 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 密码
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[DangerField]
|
||||
[JsonIgnore]
|
||||
public Guid Password { get; init; }
|
||||
@@ -95,14 +85,12 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// <summary>
|
||||
/// 用户档案
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public Sys_UserProfile Profile { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 归属角色
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_UserRole))]
|
||||
public ICollection<Sys_Role> Roles { get; init; }
|
||||
@@ -110,7 +98,6 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// <summary>
|
||||
/// 发送给此用户的站内信集合
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(ManyToMany = typeof(Sys_SiteMsgUser))]
|
||||
public IReadOnlyCollection<Sys_SiteMsg> SiteMsgs { get; init; }
|
||||
@@ -119,7 +106,6 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 备注
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Summary { get; set; }
|
||||
|
||||
@@ -127,7 +113,6 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 授权验证Token,全局唯一,可以随时重置(强制下线)
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public Guid Token { get; init; }
|
||||
|
||||
@@ -135,29 +120,24 @@ public record Sys_User : VersionEntity, IFieldSummary, IFieldEnabled, IRegister
|
||||
/// 用户名
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string UserName { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
public virtual void Register(TypeAdapterConfig config)
|
||||
{
|
||||
public virtual void Register(TypeAdapterConfig config) {
|
||||
#pragma warning disable RCS1196
|
||||
|
||||
// ReSharper disable InvokeAsExtensionMethod
|
||||
_ = config.ForType<CreateUserReq, Sys_User>()
|
||||
.Map(d => d.Password, s => s.PasswordText.Pwd().Guid())
|
||||
.Map(d => d.Token, _ => Guid.NewGuid())
|
||||
.Map( //
|
||||
d => d.Roles
|
||||
, s => s.RoleIds.NullOrEmpty() ? Array.Empty<Sys_Role>() : Enumerable.Select(s.RoleIds, x => new Sys_Role { Id = x }));
|
||||
_ = config
|
||||
.ForType<CreateUserReq, Sys_User>()
|
||||
.Map(d => d.Password, s => s.PasswordText.Pwd().Guid())
|
||||
.Map(d => d.Token, _ => Guid.NewGuid())
|
||||
.Map(d => d.Roles, s => s.RoleIds.NullOrEmpty() ? Array.Empty<Sys_Role>() : Enumerable.Select(s.RoleIds, x => new Sys_Role { Id = x }));
|
||||
|
||||
_ = config.ForType<EditUserReq, Sys_User>()
|
||||
.Map( //
|
||||
d => d.Password, s => s.PasswordText.NullOrEmpty() ? Guid.Empty : s.PasswordText.Pwd().Guid())
|
||||
.Map( //
|
||||
d => d.Roles
|
||||
, s => s.RoleIds.NullOrEmpty() ? Array.Empty<Sys_Role>() : Enumerable.Select(s.RoleIds, x => new Sys_Role { Id = x }));
|
||||
_ = config
|
||||
.ForType<EditUserReq, Sys_User>()
|
||||
.Map(d => d.Password, s => s.PasswordText.NullOrEmpty() ? Guid.Empty : s.PasswordText.Pwd().Guid())
|
||||
.Map(d => d.Roles, s => s.RoleIds.NullOrEmpty() ? Array.Empty<Sys_Role>() : Enumerable.Select(s.RoleIds, x => new Sys_Role { Id = x }));
|
||||
|
||||
// ReSharper restore InvokeAsExtensionMethod
|
||||
#pragma warning restore RCS1196
|
||||
|
@@ -6,10 +6,23 @@ namespace NetAdmin.Domain.DbMaps.Sys;
|
||||
[Table(Name = Chars.FLG_DB_TABLE_NAME_PREFIX + nameof(Sys_UserInvite))]
|
||||
public record Sys_UserInvite : VersionEntity, IFieldOwner
|
||||
{
|
||||
/// <summary>
|
||||
/// 渠道
|
||||
/// </summary>
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(ChannelId))]
|
||||
public Sys_User Channel { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 渠道编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[JsonIgnore]
|
||||
public virtual long? ChannelId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 子节点
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(OwnerId))]
|
||||
public IEnumerable<Sys_UserInvite> Children { get; init; }
|
||||
@@ -18,14 +31,12 @@ public record Sys_UserInvite : VersionEntity, IFieldOwner
|
||||
/// 返佣比率
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual int CommissionRatio { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 归属
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(OwnerId))]
|
||||
public Sys_User Owner { get; init; }
|
||||
@@ -34,7 +45,6 @@ public record Sys_UserInvite : VersionEntity, IFieldOwner
|
||||
/// 归属部门编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerDeptId { get; init; }
|
||||
|
||||
@@ -42,7 +52,6 @@ public record Sys_UserInvite : VersionEntity, IFieldOwner
|
||||
/// 归属用户编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerId { get; init; }
|
||||
|
||||
@@ -50,14 +59,12 @@ public record Sys_UserInvite : VersionEntity, IFieldOwner
|
||||
/// 允许自助充值
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual bool SelfRechargeAllowed { get; init; }
|
||||
public virtual bool SelfDepositAllowed { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 用户
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(Id))]
|
||||
public Sys_User User { get; init; }
|
||||
|
@@ -12,7 +12,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 应用配置
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLGL_DB_FIELD_TYPE_VARCHAR_MAX)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string AppConfig { get; set; }
|
||||
|
||||
@@ -20,7 +19,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 出生日期
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual DateTime? BornDate { get; init; }
|
||||
|
||||
@@ -28,7 +26,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 证件号码
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string CertificateNumber { get; init; }
|
||||
|
||||
@@ -36,7 +33,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 证件类型
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual CertificateTypes? CertificateType { get; init; }
|
||||
|
||||
@@ -44,7 +40,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 工作地址
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string CompanyAddress { get; init; }
|
||||
|
||||
@@ -52,7 +47,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 工作地区
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public int? CompanyArea { get; init; }
|
||||
|
||||
@@ -60,7 +54,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 工作单位
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string CompanyName { get; init; }
|
||||
|
||||
@@ -68,7 +61,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 工作电话
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string CompanyTelephone { get; init; }
|
||||
|
||||
@@ -76,7 +68,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 文化程度
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual Educations? Education { get; init; }
|
||||
|
||||
@@ -84,7 +75,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 紧急联系地址
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string EmergencyContactAddress { get; init; }
|
||||
|
||||
@@ -92,7 +82,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 紧急联系地区
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public int? EmergencyContactArea { get; init; }
|
||||
|
||||
@@ -100,7 +89,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 紧急联系人手机号
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_15)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string EmergencyContactMobile { get; init; }
|
||||
|
||||
@@ -108,7 +96,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 紧急联系人
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string EmergencyContactName { get; init; }
|
||||
|
||||
@@ -116,7 +103,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 性别
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual Genders? Gender { get; init; }
|
||||
|
||||
@@ -124,7 +110,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 毕业学校
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string GraduateSchool { get; init; }
|
||||
|
||||
@@ -132,7 +117,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 身高
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual int? Height { get; init; }
|
||||
|
||||
@@ -140,7 +124,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 住宅地址
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_127)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string HomeAddress { get; init; }
|
||||
|
||||
@@ -148,7 +131,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 住宅地区
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public int? HomeArea { get; init; }
|
||||
|
||||
@@ -156,7 +138,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 住宅电话
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string HomeTelephone { get; init; }
|
||||
|
||||
@@ -164,7 +145,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 婚姻状况
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual MarriageStatues? MarriageStatus { get; init; }
|
||||
|
||||
@@ -173,7 +153,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// </summary>
|
||||
/// 7
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual Nations? Nation { get; init; }
|
||||
|
||||
@@ -181,7 +160,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 籍贯
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public int? NationArea { get; init; }
|
||||
|
||||
@@ -189,7 +167,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 政治面貌
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual PoliticalStatues? PoliticalStatus { get; init; }
|
||||
|
||||
@@ -197,7 +174,6 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 职业
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Profession { get; init; }
|
||||
|
||||
@@ -205,25 +181,22 @@ public record Sys_UserProfile : VersionEntity, IRegister
|
||||
/// 真实姓名
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_31)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string RealName { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 用户基本信息
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public Sys_User User { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
public void Register(TypeAdapterConfig config)
|
||||
{
|
||||
_ = config.ForType<CreateUserProfileReq, Sys_UserProfile>()
|
||||
.Map(d => d.NationArea, s => s.NationArea == null ? null : s.NationArea.Value)
|
||||
.Map(d => d.CompanyArea, s => s.CompanyArea == null ? null : s.CompanyArea.Value)
|
||||
.Map(d => d.HomeArea, s => s.HomeArea == null ? null : s.HomeArea.Value)
|
||||
.Map( //
|
||||
d => d.EmergencyContactArea, s => s.EmergencyContactArea == null ? null : s.EmergencyContactArea.Value);
|
||||
public void Register(TypeAdapterConfig config) {
|
||||
_ = config
|
||||
.ForType<CreateUserProfileReq, Sys_UserProfile>()
|
||||
.Map(d => d.NationArea, s => s.NationArea == null ? null : s.NationArea.Value)
|
||||
.Map(d => d.CompanyArea, s => s.CompanyArea == null ? null : s.CompanyArea.Value)
|
||||
.Map(d => d.HomeArea, s => s.HomeArea == null ? null : s.HomeArea.Value)
|
||||
.Map(d => d.EmergencyContactArea, s => s.EmergencyContactArea == null ? null : s.EmergencyContactArea.Value);
|
||||
}
|
||||
}
|
@@ -9,7 +9,6 @@ public record Sys_UserRole : VersionEntity
|
||||
/// <summary>
|
||||
/// 关联的角色
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public Sys_Role Role { get; init; }
|
||||
|
||||
@@ -17,14 +16,12 @@ public record Sys_UserRole : VersionEntity
|
||||
/// 角色编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public long RoleId { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 关联的用户
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public Sys_User User { get; init; }
|
||||
|
||||
@@ -32,7 +29,6 @@ public record Sys_UserRole : VersionEntity
|
||||
/// 用户编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public long UserId { get; init; }
|
||||
}
|
@@ -10,7 +10,6 @@ public record Sys_UserWallet : LiteVersionEntity, IFieldOwner
|
||||
/// 可用余额
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long AvailableBalance { get; init; }
|
||||
|
||||
@@ -18,14 +17,12 @@ public record Sys_UserWallet : LiteVersionEntity, IFieldOwner
|
||||
/// 冻结余额
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long FrozenBalance { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 归属用户
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(OwnerId))]
|
||||
public Sys_User Owner { get; init; }
|
||||
@@ -34,7 +31,6 @@ public record Sys_UserWallet : LiteVersionEntity, IFieldOwner
|
||||
/// 归属部门编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerDeptId { get; init; }
|
||||
|
||||
@@ -42,7 +38,6 @@ public record Sys_UserWallet : LiteVersionEntity, IFieldOwner
|
||||
/// 归属用户编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerId { get; init; }
|
||||
|
||||
@@ -50,7 +45,6 @@ public record Sys_UserWallet : LiteVersionEntity, IFieldOwner
|
||||
/// 总支出
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long TotalExpenditure { get; init; }
|
||||
|
||||
@@ -58,7 +52,6 @@ public record Sys_UserWallet : LiteVersionEntity, IFieldOwner
|
||||
/// 总收入
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long TotalIncome { get; init; }
|
||||
}
|
@@ -12,7 +12,6 @@ public record Sys_VerifyCode : VersionEntity
|
||||
/// 验证码
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_7)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Code { get; init; }
|
||||
|
||||
@@ -20,7 +19,6 @@ public record Sys_VerifyCode : VersionEntity
|
||||
/// 目标设备
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_63)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string DestDevice { get; init; }
|
||||
|
||||
@@ -28,7 +26,6 @@ public record Sys_VerifyCode : VersionEntity
|
||||
/// 设备类型
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual VerifyCodeDeviceTypes DeviceType { get; init; }
|
||||
|
||||
@@ -36,7 +33,6 @@ public record Sys_VerifyCode : VersionEntity
|
||||
/// 发送报告
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public string Report { get; init; }
|
||||
|
||||
@@ -44,7 +40,6 @@ public record Sys_VerifyCode : VersionEntity
|
||||
/// 验证码状态
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual VerifyCodeStatues Status { get; init; }
|
||||
|
||||
@@ -52,7 +47,6 @@ public record Sys_VerifyCode : VersionEntity
|
||||
/// 验证码类型
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual VerifyCodeTypes Type { get; init; }
|
||||
}
|
@@ -13,7 +13,6 @@ public record Sys_WalletFrozen : LiteVersionEntity, IFieldOwner, IFieldSummary
|
||||
/// </summary>
|
||||
/// <example>100</example>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long Amount { get; init; }
|
||||
|
||||
@@ -22,7 +21,6 @@ public record Sys_WalletFrozen : LiteVersionEntity, IFieldOwner, IFieldSummary
|
||||
/// </summary>
|
||||
/// <example>100</example>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long FrozenBalanceBefore { get; init; }
|
||||
|
||||
@@ -31,7 +29,6 @@ public record Sys_WalletFrozen : LiteVersionEntity, IFieldOwner, IFieldSummary
|
||||
/// </summary>
|
||||
/// <example>123456</example>
|
||||
[Column(IsIdentity = false, IsPrimary = true, Position = 1)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Snowflake]
|
||||
public override long Id { get; init; }
|
||||
@@ -39,7 +36,6 @@ public record Sys_WalletFrozen : LiteVersionEntity, IFieldOwner, IFieldSummary
|
||||
/// <summary>
|
||||
/// 归属用户
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(OwnerId))]
|
||||
public Sys_User Owner { get; init; }
|
||||
@@ -49,7 +45,6 @@ public record Sys_WalletFrozen : LiteVersionEntity, IFieldOwner, IFieldSummary
|
||||
/// </summary>
|
||||
/// <example>370942943322181</example>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerDeptId { get; init; }
|
||||
|
||||
@@ -58,7 +53,6 @@ public record Sys_WalletFrozen : LiteVersionEntity, IFieldOwner, IFieldSummary
|
||||
/// </summary>
|
||||
/// <example>370942943322181</example>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerId { get; init; }
|
||||
|
||||
@@ -67,7 +61,6 @@ public record Sys_WalletFrozen : LiteVersionEntity, IFieldOwner, IFieldSummary
|
||||
/// </summary>
|
||||
/// <example>Trade</example>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual WalletFrozenReasons Reason { get; init; }
|
||||
|
||||
@@ -76,7 +69,6 @@ public record Sys_WalletFrozen : LiteVersionEntity, IFieldOwner, IFieldSummary
|
||||
/// </summary>
|
||||
/// <example>Frozen</example>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual WalletFrozenStatues Status { get; init; }
|
||||
|
||||
@@ -85,14 +77,12 @@ public record Sys_WalletFrozen : LiteVersionEntity, IFieldOwner, IFieldSummary
|
||||
/// </summary>
|
||||
/// <example>备注文字</example>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Summary { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 钱包
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(OwnerId))]
|
||||
public Sys_UserWallet Wallet { get; init; }
|
||||
|
@@ -10,7 +10,6 @@ public record Sys_WalletTrade : ImmutableEntity, IFieldOwner, IFieldSummary
|
||||
/// 交易金额
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long Amount { get; set; }
|
||||
|
||||
@@ -18,7 +17,6 @@ public record Sys_WalletTrade : ImmutableEntity, IFieldOwner, IFieldSummary
|
||||
/// 交易前余额
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long BalanceBefore { get; init; }
|
||||
|
||||
@@ -26,14 +24,12 @@ public record Sys_WalletTrade : ImmutableEntity, IFieldOwner, IFieldSummary
|
||||
/// 业务订单号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? BusinessOrderNumber { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 归属用户
|
||||
/// </summary>
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
[Navigate(nameof(OwnerId))]
|
||||
public Sys_User Owner { get; init; }
|
||||
@@ -42,7 +38,6 @@ public record Sys_WalletTrade : ImmutableEntity, IFieldOwner, IFieldSummary
|
||||
/// 归属部门编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerDeptId { get; init; }
|
||||
|
||||
@@ -50,7 +45,6 @@ public record Sys_WalletTrade : ImmutableEntity, IFieldOwner, IFieldSummary
|
||||
/// 归属用户编号
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual long? OwnerId { get; init; }
|
||||
|
||||
@@ -58,7 +52,6 @@ public record Sys_WalletTrade : ImmutableEntity, IFieldOwner, IFieldSummary
|
||||
/// 备注
|
||||
/// </summary>
|
||||
[Column(DbType = Chars.FLG_DB_FIELD_TYPE_VARCHAR_255)]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual string Summary { get; set; }
|
||||
|
||||
@@ -66,7 +59,6 @@ public record Sys_WalletTrade : ImmutableEntity, IFieldOwner, IFieldSummary
|
||||
/// 交易方向
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual TradeDirections TradeDirection { get; init; }
|
||||
|
||||
@@ -74,7 +66,6 @@ public record Sys_WalletTrade : ImmutableEntity, IFieldOwner, IFieldSummary
|
||||
/// 交易类型
|
||||
/// </summary>
|
||||
[Column]
|
||||
[CsvIgnore]
|
||||
[JsonIgnore]
|
||||
public virtual TradeTypes TradeType { get; init; }
|
||||
}
|
@@ -10,6 +10,17 @@ public record JobReq : DataAbstraction
|
||||
/// </summary>
|
||||
public int? Count { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 模数
|
||||
/// </summary>
|
||||
[JsonInclude]
|
||||
public int Mod { get; init; } = 1;
|
||||
|
||||
/// <summary>
|
||||
/// 余数
|
||||
/// </summary>
|
||||
public int Remainder { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// n秒以前
|
||||
/// </summary>
|
||||
|
@@ -51,15 +51,14 @@ public record QueryReq<T> : DataAbstraction
|
||||
/// <summary>
|
||||
/// 求和表达式
|
||||
/// </summary>
|
||||
public Expression<Func<TEntity, long>> GetSumExp<TEntity>()
|
||||
{
|
||||
public Expression<Func<TEntity, long>> GetSumExp<TEntity>() {
|
||||
if (RequiredFields.NullOrEmpty()) {
|
||||
return null;
|
||||
}
|
||||
|
||||
var field = RequiredFields[0];
|
||||
var field = RequiredFields[0];
|
||||
var leftParameter = Expression.Parameter(typeof(TEntity), "a");
|
||||
var prop = typeof(TEntity).GetRecursiveProperty(field);
|
||||
var prop = typeof(TEntity).GetRecursiveProperty(field);
|
||||
return prop == null || prop.GetCustomAttribute<DangerFieldAttribute>() != null
|
||||
? null
|
||||
: Expression.Lambda<Func<TEntity, long>>(CreatePropertyExpression(leftParameter, field), leftParameter);
|
||||
@@ -68,14 +67,13 @@ public record QueryReq<T> : DataAbstraction
|
||||
/// <summary>
|
||||
/// 列表表达式
|
||||
/// </summary>
|
||||
public Expression<Func<TEntity, TEntity>> GetToListExp<TEntity>()
|
||||
{
|
||||
public Expression<Func<TEntity, TEntity>> GetToListExp<TEntity>() {
|
||||
if (RequiredFields.NullOrEmpty()) {
|
||||
return null;
|
||||
}
|
||||
|
||||
var expParameter = Expression.Parameter(typeof(TEntity), "a");
|
||||
var bindings = new List<(PropertyInfo, MemberInitExpression)>();
|
||||
var bindings = new List<(PropertyInfo, MemberInitExpression)>();
|
||||
|
||||
// ReSharper disable once LoopCanBeConvertedToQuery
|
||||
foreach (var field in RequiredFields) {
|
||||
@@ -84,21 +82,24 @@ public record QueryReq<T> : DataAbstraction
|
||||
continue;
|
||||
}
|
||||
|
||||
var parentPath = field[..field.LastIndexOf('.').Is(-1, field.Length)];
|
||||
var parentPath = field[..field.LastIndexOf('.').Is(-1, field.Length)];
|
||||
var parentProperty = typeof(TEntity).GetRecursiveProperty(parentPath);
|
||||
var propExp = Expression.Property(Expression.Parameter(prop.DeclaringType!, parentPath), prop);
|
||||
var propExp = Expression.Property(Expression.Parameter(prop.DeclaringType!, parentPath), prop);
|
||||
|
||||
bindings.Add((parentProperty, Expression.MemberInit(Expression.New(prop.DeclaringType), Expression.Bind(prop, propExp))));
|
||||
}
|
||||
|
||||
var expBody = Expression.MemberInit( //
|
||||
var expBody = Expression.MemberInit(
|
||||
Expression.New(typeof(TEntity))
|
||||
, bindings.SelectMany(x => x.Item1.PropertyType == x.Item2.Type ? [Expression.Bind(x.Item1, x.Item2)] : x.Item2.Bindings.ToArray()));
|
||||
, bindings.SelectMany(x => x.Item1.PropertyType == x.Item2.Type ? [Expression.Bind(x.Item1, x.Item2)] : x.Item2.Bindings.ToArray())
|
||||
);
|
||||
return Expression.Lambda<Func<TEntity, TEntity>>(expBody, expParameter);
|
||||
}
|
||||
|
||||
private static Expression CreatePropertyExpression(ParameterExpression param, string propertyPath)
|
||||
{
|
||||
private static Expression CreatePropertyExpression(
|
||||
ParameterExpression param
|
||||
, string propertyPath
|
||||
) {
|
||||
return propertyPath.Split('.').Aggregate<string, Expression>(param, Expression.PropertyOrField);
|
||||
}
|
||||
}
|
@@ -10,8 +10,7 @@ public sealed record DfBuilder
|
||||
/// <summary>
|
||||
/// 构建生成器
|
||||
/// </summary>
|
||||
public static DynamicFilterInfo New(DynamicFilterLogics logic)
|
||||
{
|
||||
public static DynamicFilterInfo New(DynamicFilterLogics logic) {
|
||||
return new DynamicFilterInfo { Logic = logic, Filters = [] };
|
||||
}
|
||||
}
|
@@ -35,8 +35,7 @@ public sealed record DynamicFilterInfo : DataAbstraction
|
||||
/// <summary>
|
||||
/// 隐式转换为 FreeSql 的 DynamicFilterInfo 对象
|
||||
/// </summary>
|
||||
public static implicit operator FreeSql.Internal.Model.DynamicFilterInfo(DynamicFilterInfo d)
|
||||
{
|
||||
public static implicit operator FreeSql.Internal.Model.DynamicFilterInfo(DynamicFilterInfo d) {
|
||||
var ret = d.Adapt<FreeSql.Internal.Model.DynamicFilterInfo>();
|
||||
#pragma warning disable VSTHRD002
|
||||
ProcessDynamicFilterAsync(ret).ConfigureAwait(false).GetAwaiter().GetResult();
|
||||
@@ -47,8 +46,7 @@ public sealed record DynamicFilterInfo : DataAbstraction
|
||||
/// <summary>
|
||||
/// 添加子过滤条件
|
||||
/// </summary>
|
||||
public DynamicFilterInfo Add(DynamicFilterInfo df)
|
||||
{
|
||||
public DynamicFilterInfo Add(DynamicFilterInfo df) {
|
||||
if (Filters == null) {
|
||||
return this with { Filters = [df] };
|
||||
}
|
||||
@@ -60,29 +58,37 @@ public sealed record DynamicFilterInfo : DataAbstraction
|
||||
/// <summary>
|
||||
/// 添加过滤条件
|
||||
/// </summary>
|
||||
public DynamicFilterInfo Add(string field, DynamicFilterOperators opt, object val)
|
||||
{
|
||||
public DynamicFilterInfo Add(
|
||||
string field
|
||||
, DynamicFilterOperators opt
|
||||
, object val
|
||||
) {
|
||||
return Add(new DynamicFilterInfo { Field = field, Operator = opt, Value = val });
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 添加过滤条件
|
||||
/// </summary>
|
||||
public DynamicFilterInfo AddIf(bool condition, string field, DynamicFilterOperators opt, object val)
|
||||
{
|
||||
public DynamicFilterInfo AddIf(
|
||||
bool condition
|
||||
, string field
|
||||
, DynamicFilterOperators opt
|
||||
, object val
|
||||
) {
|
||||
return !condition ? this : Add(field, opt, val);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 添加过滤条件
|
||||
/// </summary>
|
||||
public DynamicFilterInfo AddIf(bool condition, DynamicFilterInfo df)
|
||||
{
|
||||
public DynamicFilterInfo AddIf(
|
||||
bool condition
|
||||
, DynamicFilterInfo df
|
||||
) {
|
||||
return !condition ? this : Add(df);
|
||||
}
|
||||
|
||||
private static async Task ParseDateExpAsync(FreeSql.Internal.Model.DynamicFilterInfo d)
|
||||
{
|
||||
private static async Task ParseDateExpAsync(FreeSql.Internal.Model.DynamicFilterInfo d) {
|
||||
var values = ((JsonElement)d.Value).Deserialize<string[]>();
|
||||
if (!DateTime.TryParse(values[0], CultureInfo.InvariantCulture, out _)) {
|
||||
var result = await values[0].ExecuteCSharpCodeAsync<DateTime>([typeof(DateTime).Assembly], nameof(System)).ConfigureAwait(false);
|
||||
@@ -97,8 +103,7 @@ public sealed record DynamicFilterInfo : DataAbstraction
|
||||
d.Value = values;
|
||||
}
|
||||
|
||||
private static async Task ProcessDynamicFilterAsync(FreeSql.Internal.Model.DynamicFilterInfo d)
|
||||
{
|
||||
private static async Task ProcessDynamicFilterAsync(FreeSql.Internal.Model.DynamicFilterInfo d) {
|
||||
if (d?.Filters != null) {
|
||||
foreach (var filterInfo in d.Filters) {
|
||||
await ProcessDynamicFilterAsync(filterInfo).ConfigureAwait(false);
|
||||
@@ -106,7 +111,8 @@ public sealed record DynamicFilterInfo : DataAbstraction
|
||||
}
|
||||
|
||||
if (new[] { nameof(IFieldCreatedClientIp.CreatedClientIp), nameof(IFieldModifiedClientIp.ModifiedClientIp) }.Contains(
|
||||
d?.Field, StringComparer.OrdinalIgnoreCase)) {
|
||||
d?.Field, StringComparer.OrdinalIgnoreCase
|
||||
)) {
|
||||
var val = d!.Value?.ToString();
|
||||
if (val?.IsIpV4() == true) {
|
||||
d.Value = val.IpV4ToInt32();
|
||||
|
@@ -3,33 +3,4 @@ namespace NetAdmin.Domain.Dto.Sys.Api;
|
||||
/// <summary>
|
||||
/// 响应:导出接口
|
||||
/// </summary>
|
||||
public sealed record ExportApiRsp : QueryApiRsp
|
||||
{
|
||||
/// <inheritdoc />
|
||||
[CsvIgnore]
|
||||
public override IEnumerable<QueryApiRsp> Children { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(0)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.接口路径))]
|
||||
public override string Id { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(2)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.请求方式))]
|
||||
public override string Method { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(1)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.接口名称))]
|
||||
public override string Name { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(3)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.接口描述))]
|
||||
public override string Summary { get; set; }
|
||||
}
|
||||
public sealed record ExportApiRsp : Sys_Api;
|
@@ -5,21 +5,21 @@ namespace NetAdmin.Domain.Dto.Sys.Cache;
|
||||
/// </summary>
|
||||
public sealed record CacheStatisticsRsp : DataAbstraction
|
||||
{
|
||||
private static readonly Regex[] _regexes = [
|
||||
new(@"keyspace_hits:(\d+)", RegexOptions.Compiled) //
|
||||
, new(@"keyspace_misses:(\d+)", RegexOptions.Compiled) //
|
||||
, new(@"uptime_in_seconds:(\d+)", RegexOptions.Compiled) //
|
||||
, new(@"used_cpu_sys:([\d\\.]+)", RegexOptions.Compiled) //
|
||||
, new(@"used_cpu_user:([\d\\.]+)", RegexOptions.Compiled) //
|
||||
, new(@"used_memory:(\d+)", RegexOptions.Compiled) //
|
||||
, new("redis_version:(.+)", RegexOptions.Compiled) //
|
||||
private static readonly Regex[] _regexes =
|
||||
[
|
||||
new(@"keyspace_hits:(\d+)", RegexOptions.Compiled) //
|
||||
, new(@"keyspace_misses:(\d+)", RegexOptions.Compiled) //
|
||||
, new(@"uptime_in_seconds:(\d+)", RegexOptions.Compiled) //
|
||||
, new(@"used_cpu_sys:([\d\\.]+)", RegexOptions.Compiled) //
|
||||
, new(@"used_cpu_user:([\d\\.]+)", RegexOptions.Compiled) //
|
||||
, new(@"used_memory:(\d+)", RegexOptions.Compiled) //
|
||||
, new("redis_version:(.+)", RegexOptions.Compiled)
|
||||
];
|
||||
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="CacheStatisticsRsp" /> class.
|
||||
/// </summary>
|
||||
public CacheStatisticsRsp(string redisResult)
|
||||
{
|
||||
public CacheStatisticsRsp(string redisResult) {
|
||||
KeyspaceHits = _regexes[0].Match(redisResult).Groups[1].Value.Trim().Int64Try(0);
|
||||
KeyspaceMisses = _regexes[1].Match(redisResult).Groups[1].Value.Trim().Int64Try(0);
|
||||
UpTime = _regexes[2].Match(redisResult).Groups[1].Value.Trim().Int64Try(0);
|
||||
|
@@ -1,60 +1,6 @@
|
||||
using NetAdmin.Domain.Dto.Sys.Dept;
|
||||
using NetAdmin.Domain.Dto.Sys.Role;
|
||||
|
||||
namespace NetAdmin.Domain.Dto.Sys.Config;
|
||||
|
||||
/// <summary>
|
||||
/// 响应:导出配置
|
||||
/// </summary>
|
||||
public sealed record ExportConfigRsp : QueryConfigRsp, IRegister
|
||||
{
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(6)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.是否启用))]
|
||||
public override bool Enabled { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(0)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.唯一编码))]
|
||||
public override long Id { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(3)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.人工审核))]
|
||||
public override bool UserRegisterConfirm { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIgnore]
|
||||
public override QueryDeptRsp UserRegisterDept { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 默认部门
|
||||
/// </summary>
|
||||
[CsvIndex(1)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.默认部门))]
|
||||
public string UserRegisterDeptName { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIgnore]
|
||||
public override QueryRoleRsp UserRegisterRole { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 默认角色
|
||||
/// </summary>
|
||||
[CsvIndex(2)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.默认角色))]
|
||||
public string UserRegisterRoleName { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
public void Register(TypeAdapterConfig config)
|
||||
{
|
||||
_ = config.ForType<Sys_Config, ExportConfigRsp>()
|
||||
.Map(d => d.UserRegisterDeptName, s => s.UserRegisterDept.Name)
|
||||
.Map(d => d.UserRegisterRoleName, s => s.UserRegisterRole.Name);
|
||||
}
|
||||
}
|
||||
public sealed record ExportConfigRsp : Sys_Config;
|
@@ -1,3 +1,5 @@
|
||||
using NetAdmin.Domain.Enums.Sys;
|
||||
|
||||
namespace NetAdmin.Domain.Dto.Sys.DepositOrder;
|
||||
|
||||
/// <summary>
|
||||
@@ -25,8 +27,7 @@ public record CreateDepositOrderReq : Sys_DepositOrder
|
||||
public override int ToPointRate { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override IEnumerable<ValidationResult> ValidateInternal(ValidationContext validationContext)
|
||||
{
|
||||
protected override IEnumerable<ValidationResult> ValidateInternal(ValidationContext validationContext) {
|
||||
if (PaymentMode != PaymentModes.USDT) {
|
||||
yield return new ValidationResult(Ln.支付方式不正确, [nameof(PaymentMode)]);
|
||||
}
|
||||
|
@@ -0,0 +1,61 @@
|
||||
namespace NetAdmin.Domain.Dto.Sys.DepositOrder;
|
||||
|
||||
/// <summary>
|
||||
/// 请求:导出充值订单
|
||||
/// </summary>
|
||||
public sealed record ExportDepositOrderRsp : DataAbstraction
|
||||
{
|
||||
/// <summary>
|
||||
/// 充值金额
|
||||
/// </summary>
|
||||
[Ganss.Excel.Column(6)]
|
||||
public decimal 充值金额 { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 订单编号
|
||||
/// </summary>
|
||||
[Ganss.Excel.Column(1)]
|
||||
public string 订单编号 { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 订单状态
|
||||
/// </summary>
|
||||
[Ganss.Excel.Column(5)]
|
||||
public string 订单状态 { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 归属用户
|
||||
/// </summary>
|
||||
[Ganss.Excel.Column(2)]
|
||||
public string 归属用户 { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 汇率
|
||||
/// </summary>
|
||||
[Ganss.Excel.Column(7)]
|
||||
public decimal 汇率 { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 渠道
|
||||
/// </summary>
|
||||
[Ganss.Excel.Column(4)]
|
||||
public string 渠道 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 上级
|
||||
/// </summary>
|
||||
[Ganss.Excel.Column(3)]
|
||||
public string 上级 { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 支付方式
|
||||
/// </summary>
|
||||
[Ganss.Excel.Column(9)]
|
||||
public string 支付方式 { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 支付金额
|
||||
/// </summary>
|
||||
[Ganss.Excel.Column(8)]
|
||||
public decimal 支付金额 { get; init; }
|
||||
}
|
@@ -1,4 +1,5 @@
|
||||
using NetAdmin.Domain.Dto.Sys.User;
|
||||
using NetAdmin.Domain.Enums.Sys;
|
||||
|
||||
namespace NetAdmin.Domain.Dto.Sys.DepositOrder;
|
||||
|
||||
@@ -32,7 +33,6 @@ public record QueryDepositOrderRsp : Sys_DepositOrder
|
||||
public override DateTime? ModifiedTime { get; init; }
|
||||
|
||||
/// <inheritdoc cref="Sys_DepositOrder.Owner" />
|
||||
[CsvIgnore]
|
||||
public new virtual QueryUserRsp Owner { get; init; }
|
||||
|
||||
/// <inheritdoc cref="IFieldOwner.OwnerDeptId" />
|
||||
|
@@ -3,45 +3,4 @@ namespace NetAdmin.Domain.Dto.Sys.Dept;
|
||||
/// <summary>
|
||||
/// 响应:导出部门
|
||||
/// </summary>
|
||||
public sealed record ExportDeptRsp : QueryDeptRsp
|
||||
{
|
||||
/// <inheritdoc />
|
||||
[CsvIgnore]
|
||||
public override IEnumerable<QueryDeptRsp> Children { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(5)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.创建时间))]
|
||||
public override DateTime CreatedTime { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(4)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.是否启用))]
|
||||
public override bool Enabled { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(0)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.唯一编码))]
|
||||
public override long Id { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(1)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.部门名称))]
|
||||
public override string Name { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(2)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.排序))]
|
||||
public override long Sort { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(3)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.备注))]
|
||||
public override string Summary { get; set; }
|
||||
}
|
||||
public sealed record ExportDeptRsp : Sys_Dept;
|
@@ -3,35 +3,4 @@ namespace NetAdmin.Domain.Dto.Sys.Dic.Content;
|
||||
/// <summary>
|
||||
/// 响应:导出字典内容
|
||||
/// </summary>
|
||||
public sealed record ExportDicContentRsp : QueryDicContentRsp
|
||||
{
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(2)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.创建时间))]
|
||||
public override DateTime CreatedTime { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(3)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.是否启用))]
|
||||
public override bool Enabled { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(0)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.项名))]
|
||||
public override string Key { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(4)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.备注))]
|
||||
public override string Summary { get; set; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(1)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.项值))]
|
||||
public override string Value { get; init; }
|
||||
}
|
||||
public sealed record ExportDicContentRsp : Sys_DicContent;
|
@@ -3,29 +3,4 @@ namespace NetAdmin.Domain.Dto.Sys.Doc.Content;
|
||||
/// <summary>
|
||||
/// 响应:导出文档内容
|
||||
/// </summary>
|
||||
public sealed record ExportDocContentRsp : QueryDocContentRsp
|
||||
{
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(1)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.文档内容))]
|
||||
public override string Body { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(2)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.创建时间))]
|
||||
public override DateTime CreatedTime { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(3)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.是否启用))]
|
||||
public override bool Enabled { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(0)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.文档标题))]
|
||||
public override string Title { get; init; }
|
||||
}
|
||||
public sealed record ExportDocContentRsp : Sys_DocContent;
|
@@ -1,80 +1,6 @@
|
||||
using NetAdmin.Domain.Dto.Sys.User;
|
||||
using NetAdmin.Domain.Enums.Sys;
|
||||
|
||||
namespace NetAdmin.Domain.Dto.Sys.Job;
|
||||
|
||||
/// <summary>
|
||||
/// 响应:导出计划作业
|
||||
/// 请求:导出计划作业
|
||||
/// </summary>
|
||||
public sealed record ExportJobRsp : QueryJobRsp
|
||||
{
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(5)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.上次执行状态))]
|
||||
public override string LastStatusCode => base.LastStatusCode;
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(10)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.创建时间))]
|
||||
public override DateTime CreatedTime { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(9)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.是否启用))]
|
||||
public override bool Enabled { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(2)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.执行计划))]
|
||||
public override string ExecutionCron { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(4)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.请求方式))]
|
||||
public override HttpMethods HttpMethod { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(0)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.唯一编码))]
|
||||
public override long Id { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(1)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.作业名称))]
|
||||
public override string JobName { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(7)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.上次执行耗时))]
|
||||
public override long? LastDuration { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(6)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.上次执行时间))]
|
||||
public override DateTime? LastExecTime { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(8)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.下次执行时间))]
|
||||
public override DateTime? NextExecTime { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(3)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.作业状态))]
|
||||
public override JobStatues Status { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIgnore]
|
||||
public override QueryUserRsp User { get; init; }
|
||||
}
|
||||
public sealed record ExportJobRsp : Sys_Job;
|
@@ -6,8 +6,7 @@ namespace NetAdmin.Domain.Dto.Sys.Job;
|
||||
public sealed record FinishJobReq : Sys_Job, IRegister
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public void Register(TypeAdapterConfig config)
|
||||
{
|
||||
public void Register(TypeAdapterConfig config) {
|
||||
_ = config.ForType<QueryJobRsp, FinishJobReq>().Map(d => d.LastStatusCode, s => ((Sys_Job)s).LastStatusCode);
|
||||
}
|
||||
}
|
@@ -19,10 +19,11 @@ public record QueryJobRsp : Sys_Job
|
||||
/// <inheritdoc cref="Sys_Job.LastStatusCode" />
|
||||
[JsonInclude]
|
||||
public new virtual string LastStatusCode =>
|
||||
base.LastStatusCode switch {
|
||||
base.LastStatusCode switch
|
||||
{
|
||||
null => null
|
||||
, _ => base.LastStatusCode.Value == Numbers.HTTP_STATUS_BIZ_FAIL
|
||||
? nameof(ErrorCodes.Unhandled).ToLowerCamelCase()
|
||||
, _ => base.LastStatusCode.Value == Numbers.HTTP_STATUS_BIZ_FAIL
|
||||
? nameof(ErrorCodes.InternalError).ToLowerCamelCase()
|
||||
: ((HttpStatusCode)base.LastStatusCode.Value).ToString().ToLowerCamelCase()
|
||||
};
|
||||
|
||||
|
@@ -1,57 +1,6 @@
|
||||
using NetAdmin.Domain.Dto.Sys.Job;
|
||||
|
||||
namespace NetAdmin.Domain.Dto.Sys.JobRecord;
|
||||
|
||||
/// <summary>
|
||||
/// 响应:导出计划作业执行记录
|
||||
/// </summary>
|
||||
public sealed record ExportJobRecordRsp : QueryJobRecordRsp, IRegister
|
||||
{
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(1)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.响应状态码))]
|
||||
public override string HttpStatusCode => base.HttpStatusCode;
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(6)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.创建时间))]
|
||||
public override DateTime CreatedTime { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(3)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.执行耗时))]
|
||||
public override long Duration { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(0)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.唯一编码))]
|
||||
public override long Id { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIgnore]
|
||||
public override QueryJobRsp Job { get; init; }
|
||||
|
||||
/// <summary>
|
||||
/// 作业名称
|
||||
/// </summary>
|
||||
[CsvIndex(4)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.作业名称))]
|
||||
public string JobName { get; set; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(5)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.响应体))]
|
||||
public override string ResponseBody { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
public void Register(TypeAdapterConfig config)
|
||||
{
|
||||
_ = config.ForType<Sys_JobRecord, ExportJobRecordRsp>().Map(d => d.JobName, s => s.Job.JobName);
|
||||
}
|
||||
}
|
||||
public sealed record ExportJobRecordRsp : Sys_JobRecord;
|
@@ -11,7 +11,7 @@ public record QueryJobRecordRsp : Sys_JobRecord
|
||||
[JsonInclude]
|
||||
public new virtual string HttpStatusCode =>
|
||||
base.HttpStatusCode == Numbers.HTTP_STATUS_BIZ_FAIL
|
||||
? nameof(ErrorCodes.Unhandled).ToLowerCamelCase()
|
||||
? nameof(ErrorCodes.InternalError).ToLowerCamelCase()
|
||||
: ((HttpStatusCode)base.HttpStatusCode).ToString().ToLowerCamelCase();
|
||||
|
||||
/// <inheritdoc cref="IFieldCreatedTime.CreatedTime" />
|
||||
|
@@ -10,14 +10,12 @@ namespace NetAdmin.Domain.Dto.Sys.LoginLog;
|
||||
public record CreateLoginLogReq : Sys_LoginLog, IRegister
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public void Register(TypeAdapterConfig config)
|
||||
{
|
||||
public void Register(TypeAdapterConfig config) {
|
||||
_ = config.ForType<CreateRequestLogReq, CreateLoginLogReq>().MapWith(x => Convert(x));
|
||||
}
|
||||
|
||||
private static CreateLoginLogReq Convert(CreateRequestLogReq s)
|
||||
{
|
||||
var body = s.Detail.ResponseBody.ToObject<RestfulInfo<LoginRsp>>();
|
||||
private static CreateLoginLogReq Convert(CreateRequestLogReq s) {
|
||||
var body = s.Detail.ResponseBody.ToObject<RestfulInfo<LoginRsp>>();
|
||||
ContextUserToken userToken = null;
|
||||
|
||||
// ReSharper disable once InvertIf
|
||||
@@ -30,23 +28,24 @@ public record CreateLoginLogReq : Sys_LoginLog, IRegister
|
||||
}
|
||||
}
|
||||
|
||||
return new CreateLoginLogReq {
|
||||
Id = s.Id
|
||||
, CreatedClientIp = s.CreatedClientIp
|
||||
, CreatedTime = s.CreatedTime
|
||||
, Duration = s.Duration
|
||||
, HttpStatusCode = s.HttpStatusCode
|
||||
, ErrorCode = s.Detail.ErrorCode
|
||||
, RequestBody = s.Detail.RequestBody
|
||||
, RequestHeaders = s.Detail.RequestHeaders
|
||||
, RequestUrl = s.Detail.RequestUrl
|
||||
, ResponseBody = s.Detail.ResponseBody
|
||||
, ResponseHeaders = s.Detail.ResponseHeaders
|
||||
, ServerIp = s.Detail.ServerIp
|
||||
, CreatedUserAgent = s.Detail.CreatedUserAgent
|
||||
, OwnerId = userToken?.Id
|
||||
, OwnerDeptId = userToken?.DeptId
|
||||
, LoginUserName = s.Detail.RequestBody?.ToObject<LoginByPwdReq>()?.Account
|
||||
};
|
||||
return new CreateLoginLogReq
|
||||
{
|
||||
Id = s.Id
|
||||
, CreatedClientIp = s.CreatedClientIp
|
||||
, CreatedTime = s.CreatedTime
|
||||
, Duration = s.Duration
|
||||
, HttpStatusCode = s.HttpStatusCode
|
||||
, ErrorCode = s.Detail.ErrorCode
|
||||
, RequestBody = s.Detail.RequestBody
|
||||
, RequestHeaders = s.Detail.RequestHeaders
|
||||
, RequestUrl = s.Detail.RequestUrl
|
||||
, ResponseBody = s.Detail.ResponseBody
|
||||
, ResponseHeaders = s.Detail.ResponseHeaders
|
||||
, ServerIp = s.Detail.ServerIp
|
||||
, CreatedUserAgent = s.Detail.CreatedUserAgent
|
||||
, OwnerId = userToken?.Id
|
||||
, OwnerDeptId = userToken?.DeptId
|
||||
, LoginUserName = s.Detail.RequestBody?.ToObject<LoginByPwdReq>()?.Account
|
||||
};
|
||||
}
|
||||
}
|
@@ -1,55 +1,6 @@
|
||||
using NetAdmin.Domain.Dto.Sys.User;
|
||||
|
||||
namespace NetAdmin.Domain.Dto.Sys.LoginLog;
|
||||
|
||||
/// <summary>
|
||||
/// 响应:导出登录日志
|
||||
/// </summary>
|
||||
public sealed record ExportLoginLogRsp : QueryLoginLogRsp
|
||||
{
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(3)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.客户端IP))]
|
||||
public override string CreatedClientIp => base.CreatedClientIp;
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(4)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.操作系统))]
|
||||
public override string Os => base.Os;
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIgnore(false)]
|
||||
[CsvIndex(6)]
|
||||
[CsvName(nameof(Ln.创建时间))]
|
||||
public override DateTime CreatedTime { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(5)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.用户代理))]
|
||||
public override string CreatedUserAgent { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(1)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.响应状态码))]
|
||||
public override int HttpStatusCode { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIndex(0)]
|
||||
[CsvIgnore(false)]
|
||||
[CsvName(nameof(Ln.唯一编码))]
|
||||
public override long Id { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIgnore(false)]
|
||||
[CsvIndex(2)]
|
||||
[CsvName(nameof(Ln.登录名))]
|
||||
public override string LoginUserName { get; protected init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
[CsvIgnore]
|
||||
public override QueryUserRsp Owner { get; init; }
|
||||
}
|
||||
public sealed record ExportLoginLogRsp : Sys_LoginLog;
|
@@ -10,16 +10,24 @@ public sealed record MetaInfo : DataAbstraction
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="MetaInfo" /> class.
|
||||
/// </summary>
|
||||
public MetaInfo(string color, bool fullPage, bool hidden, bool hiddenBreadCrumb, string icon, string tag, string title, MenuTypes type)
|
||||
{
|
||||
Color = color;
|
||||
FullPage = fullPage;
|
||||
Hidden = hidden;
|
||||
public MetaInfo(
|
||||
string color
|
||||
, bool fullPage
|
||||
, bool hidden
|
||||
, bool hiddenBreadCrumb
|
||||
, string icon
|
||||
, string tag
|
||||
, string title
|
||||
, MenuTypes type
|
||||
) {
|
||||
Color = color;
|
||||
FullPage = fullPage;
|
||||
Hidden = hidden;
|
||||
HiddenBreadCrumb = hiddenBreadCrumb;
|
||||
Icon = icon;
|
||||
Tag = tag;
|
||||
Title = title;
|
||||
Type = type;
|
||||
Icon = icon;
|
||||
Tag = tag;
|
||||
Title = title;
|
||||
Type = type;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@@ -62,12 +62,7 @@ public sealed record QueryMenuRsp : Sys_Menu, IRegister
|
||||
public override long Version { get; init; }
|
||||
|
||||
/// <inheritdoc />
|
||||
public void Register(TypeAdapterConfig config)
|
||||
{
|
||||
_ = config.ForType<Sys_Menu, QueryMenuRsp>() //
|
||||
.Map(d => d.Path, s => s.Path ?? string.Empty)
|
||||
|
||||
//
|
||||
;
|
||||
public void Register(TypeAdapterConfig config) {
|
||||
_ = config.ForType<Sys_Menu, QueryMenuRsp>().Map(d => d.Path, s => s.Path ?? string.Empty);
|
||||
}
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user