Эх сурвалжийг харах

😁调整生成种子数据相关代码

zuohuaijun 2 жил өмнө
parent
commit
41b0caff89

+ 1 - 1
Admin.NET/Admin.NET.Core/Admin.NET.Core.csproj

@@ -37,7 +37,7 @@
     <PackageReference Include="SKIT.FlurlHttpClient.Wechat.Api" Version="2.33.0" />
     <PackageReference Include="SKIT.FlurlHttpClient.Wechat.TenpayV3" Version="2.20.0" />
     <PackageReference Include="SqlSugarCore" Version="5.1.4.106" />
-    <PackageReference Include="System.Linq.Dynamic.Core" Version="1.3.4" />
+    <PackageReference Include="System.Linq.Dynamic.Core" Version="1.3.5" />
     <PackageReference Include="UAParser" Version="3.1.47" />
     <PackageReference Include="Yitter.IdGenerator" Version="1.0.14" />
   </ItemGroup>

+ 1 - 0
Admin.NET/Admin.NET.Core/GlobalUsings.cs

@@ -25,6 +25,7 @@ global using Furion.Schedule;
 global using Furion.UnifyResult;
 global using Furion.ViewEngine;
 global using Magicodes.ExporterAndImporter.Core;
+global using Magicodes.ExporterAndImporter.Core.Extension;
 global using Magicodes.ExporterAndImporter.Excel;
 global using Mapster;
 global using Microsoft.AspNetCore.Authorization;

+ 45 - 42
Admin.NET/Admin.NET.Core/Service/DataBase/Dto/CreateSeedDataInput.cs

@@ -1,45 +1,48 @@
-// 麻省理工学院许可证
-//
-// 版权所有 (c) 2021-2023 zuohuaijun,大名科技(天津)有限公司  联系电话/微信:18020030720  QQ:515096995
-//
-// 特此免费授予获得本软件的任何人以处理本软件的权利,但须遵守以下条件:在所有副本或重要部分的软件中必须包括上述版权声明和本许可声明。
-//
-// 软件按“原样”提供,不提供任何形式的明示或暗示的保证,包括但不限于对适销性、适用性和非侵权的保证。
-// 在任何情况下,作者或版权持有人均不对任何索赔、损害或其他责任负责,无论是因合同、侵权或其他方式引起的,与软件或其使用或其他交易有关。
-
-namespace Admin.NET.Core.Service;
-
-public class CreateSeedDataInput
-{
-    /// <summary>
-    /// 表名
-    /// </summary>
-    /// <example>student</example>
-    public string TableName { get; set; }
-    /// <summary>
-    /// SeedData对象名
-    /// </summary>
-    /// <example>Student</example>
-    public string EntityName { get; set; }
-    /// <summary>
-    /// SeedData对象名
-    /// </summary>
-    /// <example>Student</example>
-    public string SeedDataName { get; set; }
-    /// <summary>
-    /// 导出位置
-    /// </summary>
-    /// <example>Web.Application</example>
-    public string Position { get; set; }
-
-    /// <summary>
-    /// 库标识
-    /// </summary>
+// 麻省理工学院许可证
+//
+// 版权所有 (c) 2021-2023 zuohuaijun,大名科技(天津)有限公司  联系电话/微信:18020030720  QQ:515096995
+//
+// 特此免费授予获得本软件的任何人以处理本软件的权利,但须遵守以下条件:在所有副本或重要部分的软件中必须包括上述版权声明和本许可声明。
+//
+// 软件按“原样”提供,不提供任何形式的明示或暗示的保证,包括但不限于对适销性、适用性和非侵权的保证。
+// 在任何情况下,作者或版权持有人均不对任何索赔、损害或其他责任负责,无论是因合同、侵权或其他方式引起的,与软件或其使用或其他交易有关。
+
+namespace Admin.NET.Core.Service;
+
+public class CreateSeedDataInput
+{
+    /// <summary>
+    /// 库标识
+    /// </summary>
     public string ConfigId { get; set; }
 
-    /// <summary>
-    /// 后缀
-    /// </summary>
-    /// <example>Web.Application</example>
-    public string Suffix { get; set; }
+    /// <summary>
+    /// 表名
+    /// </summary>
+    /// <example>student</example>
+    public string TableName { get; set; }
+
+    /// <summary>
+    /// 实体名称
+    /// </summary>
+    /// <example>Student</example>
+    public string EntityName { get; set; }
+
+    /// <summary>
+    /// 种子名称
+    /// </summary>
+    /// <example>Student</example>
+    public string SeedDataName { get; set; }
+
+    /// <summary>
+    /// 导出位置
+    /// </summary>
+    /// <example>Web.Application</example>
+    public string Position { get; set; }
+
+    /// <summary>
+    /// 后缀
+    /// </summary>
+    /// <example>Web.Application</example>
+    public string Suffix { get; set; }
 }

+ 31 - 0
Admin.NET/Admin.NET.Core/Service/DataBase/Dto/JsonIgnoredPropertyData.cs

@@ -0,0 +1,31 @@
+// 麻省理工学院许可证
+//
+// 版权所有 (c) 2021-2023 zuohuaijun,大名科技(天津)有限公司  联系电话/微信:18020030720  QQ:515096995
+//
+// 特此免费授予获得本软件的任何人以处理本软件的权利,但须遵守以下条件:在所有副本或重要部分的软件中必须包括上述版权声明和本许可声明。
+//
+// 软件按“原样”提供,不提供任何形式的明示或暗示的保证,包括但不限于对适销性、适用性和非侵权的保证。
+// 在任何情况下,作者或版权持有人均不对任何索赔、损害或其他责任负责,无论是因合同、侵权或其他方式引起的,与软件或其使用或其他交易有关。
+
+namespace Admin.NET.Core.Service;
+
+/// <summary>
+/// 保存标注了JsonIgnore的Property的值信息
+/// </summary>
+public class JsonIgnoredPropertyData
+{
+    /// <summary>
+    /// 记录索引
+    /// </summary>
+    public int RecordIndex { get; set; }
+
+    /// <summary>
+    /// 属性名
+    /// </summary>
+    public string Name { get; set; }
+
+    /// <summary>
+    /// 属性值描述
+    /// </summary>
+    public string Value { get; set; }
+}

+ 21 - 47
Admin.NET/Admin.NET.Core/Service/DataBase/SysDatabaseService.cs

@@ -7,8 +7,6 @@
 // 软件按“原样”提供,不提供任何形式的明示或暗示的保证,包括但不限于对适销性、适用性和非侵权的保证。
 // 在任何情况下,作者或版权持有人均不对任何索赔、损害或其他责任负责,无论是因合同、侵权或其他方式引起的,与软件或其使用或其他交易有关。
 
-using Magicodes.ExporterAndImporter.Core.Extension;
-
 namespace Admin.NET.Core.Service;
 
 /// <summary>
@@ -17,24 +15,6 @@ namespace Admin.NET.Core.Service;
 [ApiDescriptionSettings(Order = 250)]
 public class SysDatabaseService : IDynamicApiController, ITransient
 {
-    /// <summary>
-    /// 保存标注了 JsonIgnore 的Property的值信息
-    /// </summary>
-    public class JsonIgnoredPropertyData
-    {
-        /// <summary>
-        /// 对应的记录索引
-        /// </summary>
-        public int RecordIndex { get; set; }
-        /// <summary>
-        /// 属性名
-        /// </summary>
-        public string Name { get; set; }
-        /// <summary>
-        /// 属性值的字符串描述
-        /// </summary>
-        public string Value { get; set; }
-    }
     private readonly ISqlSugarClient _db;
     private readonly IViewEngine _viewEngine;
     private readonly CodeGenOptions _codeGenOptions;
@@ -220,7 +200,7 @@ public class SysDatabaseService : IDynamicApiController, ITransient
         var config = App.GetOptions<DbConnectionOptions>().ConnectionConfigs.FirstOrDefault(u => u.ConfigId == input.ConfigId);
         input.Position = string.IsNullOrWhiteSpace(input.Position) ? "Admin.NET.Application" : input.Position;
         input.EntityName = string.IsNullOrWhiteSpace(input.EntityName) ? (config.DbSettings.EnableUnderLine ? CodeGenUtil.CamelColumnName(input.TableName, null) : input.TableName) : input.EntityName;
-        string[] dbColumnNames = new string[0];
+        string[] dbColumnNames = Array.Empty<string>();
         // Entity.cs.vm中是允许创建没有基类的实体的,所以这里也要做出相同的判断
         if (!string.IsNullOrWhiteSpace(input.BaseClassName))
         {
@@ -256,11 +236,11 @@ public class SysDatabaseService : IDynamicApiController, ITransient
     }
 
     /// <summary>
-    /// 创建 SeedData
+    /// 创建种子数据
     /// </summary>
     /// <param name="input"></param>
     [ApiDescriptionSettings(Name = "CreateSeedData"), HttpPost]
-    [DisplayName("创建 SeedData")]
+    [DisplayName("创建种子数据")]
     public async void CreateSeedData(CreateSeedDataInput input)
     {
         var config = App.GetOptions<DbConnectionOptions>().ConnectionConfigs.FirstOrDefault(u => u.ConfigId == input.ConfigId);
@@ -268,8 +248,8 @@ public class SysDatabaseService : IDynamicApiController, ITransient
 
         var templatePath = GetSeedDataTemplatePath();
         var db = _db.AsTenant().GetConnectionScope(input.ConfigId);
-        var tableInfo = db.DbMaintenance.GetTableInfoList(false).FirstOrDefault(u => u.Name == input.TableName);//表名
-        List<DbColumnInfo> dbColumnInfos = db.DbMaintenance.GetColumnInfosByTableName(input.TableName, false); //所有字段
+        var tableInfo = db.DbMaintenance.GetTableInfoList(false).FirstOrDefault(u => u.Name == input.TableName); // 表名
+        List<DbColumnInfo> dbColumnInfos = db.DbMaintenance.GetColumnInfosByTableName(input.TableName, false); // 所有字段
         IEnumerable<EntityInfo> entityInfos = await GetEntityInfos();
         Type enityType = null;
         foreach (var item in entityInfos)
@@ -285,32 +265,27 @@ public class SysDatabaseService : IDynamicApiController, ITransient
             input.SeedDataName += input.Suffix;
         var targetPath = GetSeedDataTargetPath(input);
 
-        // 查询所有数据
+        // 查询所有数据
         var query = db.QueryableByObject(enityType);
-        // 查询有没有合适的排序字段,有的话用来排序,保证SeedData的插入顺序合适
-        DbColumnInfo orderField = null;
+        DbColumnInfo orderField = null; // 排序字段
         // 优先用创建时间排序
         orderField = dbColumnInfos.Where(u => u.DbColumnName.ToLower() == "create_time" || u.DbColumnName.ToLower() == "createtime").FirstOrDefault();
         if (orderField != null)
-        {
             query.OrderBy(orderField.DbColumnName);
-        }
-        // 其次用ID排充
+        // 其次用Id排序
         orderField = dbColumnInfos.Where(u => u.DbColumnName.ToLower() == "id").FirstOrDefault();
         if (orderField != null)
-        {
             query.OrderBy(orderField.DbColumnName);
-        }
         object records = query.ToList();
-        string recordsJSON = Newtonsoft.Json.JsonConvert.SerializeObject(records, Formatting.Indented);
-
-        //检查有没有 System.Text.Json.Serialization.JsonIgnore 的属性
-        var jsonIgnoreProperties = enityType.GetProperties().Where(p => 
-                p.GetAttribute<System.Text.Json.Serialization.JsonIgnoreAttribute>() != null ||
-                p.GetAttribute<Newtonsoft.Json.JsonIgnoreAttribute>() != null
-            ).ToList();
-        List<List<JsonIgnoredPropertyData>> jsonIgnoreInfo = new List<List<JsonIgnoredPropertyData>>();
-        if (jsonIgnoreProperties.Count > 0) {
+        string recordsJSON = JsonConvert.SerializeObject(records, Formatting.Indented);
+
+        // 检查有没有 System.Text.Json.Serialization.JsonIgnore 的属性
+        var jsonIgnoreProperties = enityType.GetProperties().Where(p =>
+            p.GetAttribute<System.Text.Json.Serialization.JsonIgnoreAttribute>() != null ||
+            p.GetAttribute<JsonIgnoreAttribute>() != null).ToList();
+        var jsonIgnoreInfo = new List<List<JsonIgnoredPropertyData>>();
+        if (jsonIgnoreProperties.Count > 0)
+        {
             int recordIndex = 0;
             foreach (var r in (IEnumerable)records)
             {
@@ -325,7 +300,7 @@ public class SysDatabaseService : IDynamicApiController, ITransient
                         if (v.GetType() == typeof(string))
                             strValue = "\"" + strValue + "\"";
                         else if (v.GetType() == typeof(DateTime))
-                            strValue = "DateTime.Parse(\"" + ((DateTime)v).ToString("yyyy/MM/dd HH:mm:ss") + "\")"; //这个日期方式不知道对不对
+                            strValue = "DateTime.Parse(\"" + ((DateTime)v).ToString("yyyy-MM-dd HH:mm:ss") + "\")";
                     }
                     record.Add(new JsonIgnoredPropertyData { RecordIndex = recordIndex, Name = item.Name, Value = strValue });
                 }
@@ -333,7 +308,6 @@ public class SysDatabaseService : IDynamicApiController, ITransient
                 jsonIgnoreInfo.Add(record);
             }
         }
-        // 目前为止 jsonIgnoreInfo 中保存了 JsonIgnore 的属性和值的对应关系
 
         var tContent = File.ReadAllText(templatePath);
         var data = new
@@ -347,7 +321,7 @@ public class SysDatabaseService : IDynamicApiController, ITransient
             tableInfo.Description,
             JsonIgnoreInfo = jsonIgnoreInfo,
             RecordsJSON = recordsJSON
-        }; 
+        };
         var tResult = _viewEngine.RunCompile(tContent, data, builderAction: builder =>
         {
             builder.AddAssemblyReferenceByName("System.Linq");
@@ -423,7 +397,7 @@ public class SysDatabaseService : IDynamicApiController, ITransient
     }
 
     /// <summary>
-    /// 获取SeedData模板文件路径
+    /// 获取种子数据模板文件路径
     /// </summary>
     /// <returns></returns>
     private static string GetSeedDataTemplatePath()
@@ -446,7 +420,7 @@ public class SysDatabaseService : IDynamicApiController, ITransient
     }
 
     /// <summary>
-    /// 设置生成SeedData文件路径
+    /// 设置生成种子数据文件路径
     /// </summary>
     /// <param name="input"></param>
     /// <returns></returns>

+ 0 - 4
Admin.NET/Admin.NET.Web.Core/Admin.NET.Web.Core.csproj

@@ -21,8 +21,4 @@
     <ProjectReference Include="..\Admin.NET.Core\Admin.NET.Core.csproj" />
   </ItemGroup>
 
-  <ItemGroup>
-    <Folder Include="Properties\" />
-  </ItemGroup>
-
 </Project>

+ 15 - 5
Web/src/api-services/apis/sys-database-api.ts

@@ -234,12 +234,12 @@ export const SysDatabaseApiAxiosParamCreator = function (configuration?: Configu
         },
         /**
          * 
-         * @summary 创建实体
-         * @param {CreateEntityInput} [body] 
+         * @summary 创建种子数据
+         * @param {CreateSeedDataInput} [body] 
          * @param {*} [options] Override http request option.
          * @throws {RequiredError}
          */
-        apiSysDatabaseCreateSeedDataPost: async (body?: CreateEntityInput, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
+        apiSysDatabaseCreateSeedDataPost: async (body?: CreateSeedDataInput, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
             const localVarPath = `/api/sysDatabase/createSeedData`;
             // use dummy base URL string because the URL constructor only accepts absolute URLs.
             const localVarUrlObj = new URL(localVarPath, 'https://example.com');
@@ -632,7 +632,7 @@ export const SysDatabaseApiFp = function(configuration?: Configuration) {
         },
         /**
          * 
-         * @summary 创建 SeedData
+         * @summary 创建种子数据
          * @param {CreateSeedDataInput} [body] 
          * @param {*} [options] Override http request option.
          * @throws {RequiredError}
@@ -777,6 +777,16 @@ export const SysDatabaseApiFactory = function (configuration?: Configuration, ba
         async apiSysDatabaseCreateEntityPost(body?: CreateEntityInput, options?: AxiosRequestConfig): Promise<AxiosResponse<void>> {
             return SysDatabaseApiFp(configuration).apiSysDatabaseCreateEntityPost(body, options).then((request) => request(axios, basePath));
         },
+        /**
+         * 
+         * @summary 创建种子数据
+         * @param {CreateSeedDataInput} [body] 
+         * @param {*} [options] Override http request option.
+         * @throws {RequiredError}
+         */
+        async apiSysDatabaseCreateSeedDataPost(body?: CreateSeedDataInput, options?: AxiosRequestConfig): Promise<AxiosResponse<void>> {
+            return SysDatabaseApiFp(configuration).apiSysDatabaseCreateSeedDataPost(body, options).then((request) => request(axios, basePath));
+        },
         /**
          * 
          * @summary 删除列
@@ -893,7 +903,7 @@ export class SysDatabaseApi extends BaseAPI {
     }
     /**
      * 
-     * @summary 创建 SeedData
+     * @summary 创建种子数据
      * @param {CreateSeedDataInput} [body] 
      * @param {*} [options] Override http request option.
      * @throws {RequiredError}

+ 28 - 10
Web/src/api-services/apis/sys-message-api.ts

@@ -75,16 +75,28 @@ export const SysMessageApiAxiosParamCreator = function (configuration?: Configur
          * 
          * @summary 发送邮件
          * @param {string} message 
+         * @param {string} title 
+         * @param {boolean} isHtml 
          * @param {*} [options] Override http request option.
          * @throws {RequiredError}
          */
-        apiSysMessageSendEmailMessagePost: async (message: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
+        apiSysMessageSendEmailMessageTitleIsHtmlPost: async (message: string, title: string, isHtml: boolean, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
             // verify required parameter 'message' is not null or undefined
             if (message === null || message === undefined) {
-                throw new RequiredError('message','Required parameter message was null or undefined when calling apiSysMessageSendEmailMessagePost.');
+                throw new RequiredError('message','Required parameter message was null or undefined when calling apiSysMessageSendEmailMessageTitleIsHtmlPost.');
             }
-            const localVarPath = `/api/sysMessage/sendEmail/{message}`
-                .replace(`{${"message"}}`, encodeURIComponent(String(message)));
+            // verify required parameter 'title' is not null or undefined
+            if (title === null || title === undefined) {
+                throw new RequiredError('title','Required parameter title was null or undefined when calling apiSysMessageSendEmailMessageTitleIsHtmlPost.');
+            }
+            // verify required parameter 'isHtml' is not null or undefined
+            if (isHtml === null || isHtml === undefined) {
+                throw new RequiredError('isHtml','Required parameter isHtml was null or undefined when calling apiSysMessageSendEmailMessageTitleIsHtmlPost.');
+            }
+            const localVarPath = `/api/sysMessage/sendEmail/{message}/{title}/{isHtml}`
+                .replace(`{${"message"}}`, encodeURIComponent(String(message)))
+                .replace(`{${"title"}}`, encodeURIComponent(String(title)))
+                .replace(`{${"isHtml"}}`, encodeURIComponent(String(isHtml)));
             // use dummy base URL string because the URL constructor only accepts absolute URLs.
             const localVarUrlObj = new URL(localVarPath, 'https://example.com');
             let baseOptions;
@@ -291,11 +303,13 @@ export const SysMessageApiFp = function(configuration?: Configuration) {
          * 
          * @summary 发送邮件
          * @param {string} message 
+         * @param {string} title 
+         * @param {boolean} isHtml 
          * @param {*} [options] Override http request option.
          * @throws {RequiredError}
          */
-        async apiSysMessageSendEmailMessagePost(message: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<void>>> {
-            const localVarAxiosArgs = await SysMessageApiAxiosParamCreator(configuration).apiSysMessageSendEmailMessagePost(message, options);
+        async apiSysMessageSendEmailMessageTitleIsHtmlPost(message: string, title: string, isHtml: boolean, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<void>>> {
+            const localVarAxiosArgs = await SysMessageApiAxiosParamCreator(configuration).apiSysMessageSendEmailMessageTitleIsHtmlPost(message, title, isHtml, options);
             return (axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
                 const axiosRequestArgs :AxiosRequestConfig = {...localVarAxiosArgs.options, url: basePath + localVarAxiosArgs.url};
                 return axios.request(axiosRequestArgs);
@@ -366,11 +380,13 @@ export const SysMessageApiFactory = function (configuration?: Configuration, bas
          * 
          * @summary 发送邮件
          * @param {string} message 
+         * @param {string} title 
+         * @param {boolean} isHtml 
          * @param {*} [options] Override http request option.
          * @throws {RequiredError}
          */
-        async apiSysMessageSendEmailMessagePost(message: string, options?: AxiosRequestConfig): Promise<AxiosResponse<void>> {
-            return SysMessageApiFp(configuration).apiSysMessageSendEmailMessagePost(message, options).then((request) => request(axios, basePath));
+        async apiSysMessageSendEmailMessageTitleIsHtmlPost(message: string, title: string, isHtml: boolean, options?: AxiosRequestConfig): Promise<AxiosResponse<void>> {
+            return SysMessageApiFp(configuration).apiSysMessageSendEmailMessageTitleIsHtmlPost(message, title, isHtml, options).then((request) => request(axios, basePath));
         },
         /**
          * 
@@ -427,12 +443,14 @@ export class SysMessageApi extends BaseAPI {
      * 
      * @summary 发送邮件
      * @param {string} message 
+     * @param {string} title 
+     * @param {boolean} isHtml 
      * @param {*} [options] Override http request option.
      * @throws {RequiredError}
      * @memberof SysMessageApi
      */
-    public async apiSysMessageSendEmailMessagePost(message: string, options?: AxiosRequestConfig) : Promise<AxiosResponse<void>> {
-        return SysMessageApiFp(this.configuration).apiSysMessageSendEmailMessagePost(message, options).then((request) => request(this.axios, this.basePath));
+    public async apiSysMessageSendEmailMessageTitleIsHtmlPost(message: string, title: string, isHtml: boolean, options?: AxiosRequestConfig) : Promise<AxiosResponse<void>> {
+        return SysMessageApiFp(this.configuration).apiSysMessageSendEmailMessageTitleIsHtmlPost(message, title, isHtml, options).then((request) => request(this.axios, this.basePath));
     }
     /**
      * 

+ 1 - 1
Web/src/api-services/models/add-org-input.ts

@@ -91,7 +91,7 @@ export interface AddOrgInput {
      * @type {number}
      * @memberof AddOrgInput
      */
-    directorId?: number;
+    directorId?: number | null;
     /**
      * 
      * @type {SysUser}

+ 1 - 1
Web/src/api-services/models/add-user-input.ts

@@ -223,7 +223,7 @@ export interface AddUserInput {
      * @type {number}
      * @memberof AddUserInput
      */
-    managerUserId?: number;
+    managerUserId?: number | null;
     /**
      * 
      * @type {SysUser}

+ 20 - 8
Web/src/api-services/models/create-seed-data-input.ts

@@ -17,28 +17,40 @@
  * @interface CreateSeedDataInput
  */
 export interface CreateSeedDataInput {
+    /**
+     * 库标识
+     * @type {string}
+     * @memberof CreateSeedDataInput
+     */
+    configId?: string | null;
     /**
      * 表名
      * @type {string}
-     * @memberof CreateEntityInput
+     * @memberof CreateSeedDataInput
      */
     tableName?: string | null;
     /**
-     * 导出位置
+     * 实体名称
      * @type {string}
-     * @memberof CreateEntityInput
+     * @memberof CreateSeedDataInput
      */
-    position?: string | null;
+    entityName?: string | null;
     /**
-     * 库标识
+     * 种子名称
      * @type {string}
-     * @memberof CreateEntityInput
+     * @memberof CreateSeedDataInput
      */
-    configId?: string | null;
+    seedDataName?: string | null;
+    /**
+     * 导出位置
+     * @type {string}
+     * @memberof CreateSeedDataInput
+     */
+    position?: string | null;
     /**
      * 后缀
      * @type {string}
-     * @memberof CreateEntityInput
+     * @memberof CreateSeedDataInput
      */
     suffix?: string | null;
 }

+ 1 - 1
Web/src/api-services/models/sys-org.ts

@@ -97,7 +97,7 @@ export interface SysOrg {
      * @type {number}
      * @memberof SysOrg
      */
-    directorId?: number;
+    directorId?: number | null;
     /**
      * 
      * @type {SysUser}

+ 1 - 1
Web/src/api-services/models/sys-user.ts

@@ -234,7 +234,7 @@ export interface SysUser {
      * @type {number}
      * @memberof SysUser
      */
-    managerUserId?: number;
+    managerUserId?: number | null;
     /**
      * 
      * @type {SysUser}

+ 1 - 1
Web/src/api-services/models/update-org-input.ts

@@ -91,7 +91,7 @@ export interface UpdateOrgInput {
      * @type {number}
      * @memberof UpdateOrgInput
      */
-    directorId?: number;
+    directorId?: number | null;
     /**
      * 
      * @type {SysUser}

+ 1 - 1
Web/src/api-services/models/update-user-input.ts

@@ -223,7 +223,7 @@ export interface UpdateUserInput {
      * @type {number}
      * @memberof UpdateUserInput
      */
-    managerUserId?: number;
+    managerUserId?: number | null;
     /**
      * 
      * @type {SysUser}