讲师维护

master
xiaochanghai 1 year ago
parent 062401534e
commit ef1e5c4e69
  1. 2476
      Model/Tiobon.Web.pdm
  2. 14
      Tiobon.Core.Api/Controllers/Ghre/Ghre_TeacherAttachmentController.cs
  3. 22
      Tiobon.Core.Api/Controllers/Ghre/Ghre_TeacherController.cs
  4. 14
      Tiobon.Core.Api/Controllers/Ghro/Ghro_DeptController.cs
  5. 1027
      Tiobon.Core.Api/Tiobon.Core.Model.xml
  6. 15
      Tiobon.Core.Api/Tiobon.Core.xml
  7. 5
      Tiobon.Core.Extensions/ServiceExtensions/SwaggerSetup.cs
  8. 2
      Tiobon.Core.IServices/BASE/IBaseServices.cs
  9. 12
      Tiobon.Core.IServices/Ghre/IGhre_TeacherAttachmentServices.cs
  10. 13
      Tiobon.Core.IServices/Ghre/IGhre_TeacherServices.cs
  11. 12
      Tiobon.Core.IServices/Ghro/IGhro_DeptServices.cs
  12. 186
      Tiobon.Core.Model/Base/Ghre/Ghre_Teacher.Dto.Base.cs
  13. 137
      Tiobon.Core.Model/Base/Ghre/Ghre_TeacherAttachment.Dto.Base.cs
  14. 205
      Tiobon.Core.Model/Base/Ghro/Ghro_Dept.Dto.Base.cs
  15. 33
      Tiobon.Core.Model/Edit/Ghre/Ghre_Teacher.Dto.EditInput.cs
  16. 32
      Tiobon.Core.Model/Edit/Ghre/Ghre_TeacherAttachment.Dto.EditInput.cs
  17. 27
      Tiobon.Core.Model/Edit/Ghro/Ghro_Dept.Dto.EditInput.cs
  18. 32
      Tiobon.Core.Model/Insert/Ghre/Ghre_Teacher.Dto.InsertInput.cs
  19. 31
      Tiobon.Core.Model/Insert/Ghre/Ghre_TeacherAttachment.Dto.InsertInput.cs
  20. 27
      Tiobon.Core.Model/Insert/Ghro/Ghro_Dept.Dto.InsertInput.cs
  21. 188
      Tiobon.Core.Model/Models/Ghre/Ghre_Teacher.cs
  22. 139
      Tiobon.Core.Model/Models/Ghre/Ghre_TeacherAttachment.cs
  23. 207
      Tiobon.Core.Model/Models/Ghro/Ghro_Dept.cs
  24. 42
      Tiobon.Core.Model/View/Ghre/Ghre_Teacher.Dto.View.cs
  25. 36
      Tiobon.Core.Model/View/Ghre/Ghre_TeacherAttachment.Dto.View.cs
  26. 34
      Tiobon.Core.Model/View/Ghro/Ghro_Dept.Dto.View.cs
  27. 17
      Tiobon.Core.Services/BASE/BaseServices.cs
  28. 3
      Tiobon.Core.Services/CommonServices.cs
  29. 2
      Tiobon.Core.Services/Ghre/Ghre_SchoolServices.cs
  30. 23
      Tiobon.Core.Services/Ghre/Ghre_TeacherAttachmentServices.cs
  31. 273
      Tiobon.Core.Services/Ghre/Ghre_TeacherServices.cs
  32. 23
      Tiobon.Core.Services/Ghro/Ghro_DeptServices.cs
  33. 1027
      Tiobon.Core/Tiobon.Core.Model.xml
  34. 15
      Tiobon.Core/Tiobon.Core.xml

File diff suppressed because it is too large Load Diff

@ -0,0 +1,14 @@
namespace Tiobon.Core.Api.Controllers;
/// <summary>
/// Ghre_TeacherAttachment(Controller)
/// </summary>
[Route("api/[controller]")]
[ApiController, GlobalActionFilter]
[Authorize(Permissions.Name), ApiExplorerSettings(GroupName = Grouping.GroupName_Ghre)]
public class Ghre_TeacherAttachmentController : BaseController<IGhre_TeacherAttachmentServices, Ghre_TeacherAttachment, Ghre_TeacherAttachmentDto, InsertGhre_TeacherAttachmentInput, EditGhre_TeacherAttachmentInput>
{
public Ghre_TeacherAttachmentController(IGhre_TeacherAttachmentServices service) : base(service)
{
}
}

@ -0,0 +1,22 @@
namespace Tiobon.Core.Api.Controllers;
/// <summary>
/// Ghre_Teacher(Controller)
/// </summary>
[Route("api/[controller]")]
[ApiController, GlobalActionFilter]
[Authorize(Permissions.Name), ApiExplorerSettings(GroupName = Grouping.GroupName_Ghre)]
public class Ghre_TeacherController : BaseController<IGhre_TeacherServices, Ghre_Teacher, Ghre_TeacherDto, InsertGhre_TeacherInput, EditGhre_TeacherInput>
{
public Ghre_TeacherController(IGhre_TeacherServices service) : base(service)
{
}
#region 查询
[HttpPost("QueryDisabled")]
public async Task<ServicePageResult<Ghre_TeacherDto>> QueryDisabled([FromBody] QueryBody body)
{
return await _service.QueryFilterPage(body, null, false);
}
#endregion
}

@ -0,0 +1,14 @@
namespace Tiobon.Core.Api.Controllers;
/// <summary>
/// Ghro_Dept(Controller)
/// </summary>
[Route("api/[controller]")]
[ApiController, GlobalActionFilter]
[Authorize(Permissions.Name), ApiExplorerSettings(GroupName = Grouping.GroupName_Ghro)]
public class Ghro_DeptController : BaseController<IGhro_DeptServices, Ghro_Dept, Ghro_DeptDto, InsertGhro_DeptInput, EditGhro_DeptInput>
{
public Ghro_DeptController(IGhro_DeptServices service) : base(service)
{
}
}

File diff suppressed because it is too large Load Diff

@ -821,6 +821,21 @@
培训机构(Controller) 培训机构(Controller)
</summary> </summary>
</member> </member>
<member name="T:Tiobon.Core.Api.Controllers.Ghre_TeacherAttachmentController">
<summary>
Ghre_TeacherAttachment(Controller)
</summary>
</member>
<member name="T:Tiobon.Core.Api.Controllers.Ghre_TeacherController">
<summary>
Ghre_Teacher(Controller)
</summary>
</member>
<member name="T:Tiobon.Core.Api.Controllers.Ghro_DeptController">
<summary>
Ghro_Dept(Controller)
</summary>
</member>
<member name="T:Tiobon.Core.Api.Controllers.Ghrs_AttachmentController"> <member name="T:Tiobon.Core.Api.Controllers.Ghrs_AttachmentController">
<summary> <summary>
Ghrs_Attachment(Controller) Ghrs_Attachment(Controller)

@ -275,6 +275,11 @@ namespace Tiobon.Core.Extensions
/// Ghra /// Ghra
/// </summary> /// </summary>
public const string GroupName_Ghra = "ghra"; public const string GroupName_Ghra = "ghra";
/// <summary>
/// ghro
/// </summary>
public const string GroupName_Ghro = "ghro";
/// <summary> /// <summary>
/// 辅助工具 /// 辅助工具
/// </summary> /// </summary>

@ -150,7 +150,7 @@ namespace Tiobon.Core.IServices.BASE
Task<PageModel<TEntity>> QueryPage(Expression<Func<TEntity, bool>> whereExpression, int pageIndex = 1, int pageSize = 20, string orderByFields = null); Task<PageModel<TEntity>> QueryPage(Expression<Func<TEntity, bool>> whereExpression, int pageIndex = 1, int pageSize = 20, string orderByFields = null);
Task<ServicePageResult<TEntityDto>> QueryFilterPage([FromBody] QueryBody body); Task<ServicePageResult<TEntityDto>> QueryFilterPage([FromBody] QueryBody body);
Task<ServicePageResult<TEntityDto>> QueryFilterPage(QueryBody filter, string condition); Task<ServicePageResult<TEntityDto>> QueryFilterPage(QueryBody filter, string condition, bool? IsEnable = true);
Task<ServiceResult<string>> ExportExcel([FromBody] QueryExport body); Task<ServiceResult<string>> ExportExcel([FromBody] QueryExport body);
Task<ServiceResult<ExcelData>> ImportExcel(IFormFile file); Task<ServiceResult<ExcelData>> ImportExcel(IFormFile file);

@ -0,0 +1,12 @@
using Tiobon.Core.IServices.BASE;
using Tiobon.Core.Model.Models;
namespace Tiobon.Core.IServices
{
/// <summary>
/// Ghre_TeacherAttachment(自定义服务接口)
/// </summary>
public interface IGhre_TeacherAttachmentServices :IBaseServices<Ghre_TeacherAttachment, Ghre_TeacherAttachmentDto, InsertGhre_TeacherAttachmentInput, EditGhre_TeacherAttachmentInput>
{
}
}

@ -0,0 +1,13 @@
using Tiobon.Core.IServices.BASE;
using Tiobon.Core.Model.Models;
namespace Tiobon.Core.IServices
{
/// <summary>
/// Ghre_Teacher(自定义服务接口)
/// </summary>
public interface IGhre_TeacherServices :IBaseServices<Ghre_Teacher, Ghre_TeacherDto, InsertGhre_TeacherInput, EditGhre_TeacherInput>
{
}
}

@ -0,0 +1,12 @@
using Tiobon.Core.IServices.BASE;
using Tiobon.Core.Model.Models;
namespace Tiobon.Core.IServices
{
/// <summary>
/// Ghro_Dept(自定义服务接口)
/// </summary>
public interface IGhro_DeptServices :IBaseServices<Ghro_Dept, Ghro_DeptDto, InsertGhro_DeptInput, EditGhro_DeptInput>
{
}
}

@ -0,0 +1,186 @@
/* ,
* Ghre_Teacher.cs
*
* N / A
* Ghre_Teacher
*
* Ver
*
*V0.01 2024/6/27 14:05:58 SimonHsiao
*
* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved.
*
*  
* SimonHsiao
*
*/
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace Tiobon.Core.Model.Models
{
/// <summary>
/// Ghre_Teacher (Dto.Base)
/// </summary>
public class Ghre_TeacherBase
{
/// <summary>
/// 机构Id
/// </summary>
public long? SchoolId { get; set; }
/// <summary>
/// 部门ID
/// </summary>
public int? DeptID { get; set; }
/// <summary>
/// 员工ID
/// </summary>
public int? StaffId { get; set; }
/// <summary>
/// 讲师分类
/// </summary>
[Display(Name = "TeacherType"), Description("讲师分类"), MaxLength(32, ErrorMessage = "讲师分类 不能超过 32 个字符")]
public string TeacherType { get; set; }
/// <summary>
/// 机构编号
/// </summary>
[Display(Name = "TeacherNo"), Description("机构编号"), MaxLength(32, ErrorMessage = "机构编号 不能超过 32 个字符")]
public string TeacherNo { get; set; }
/// <summary>
/// 机构名称
/// </summary>
[Display(Name = "TeacherName"), Description("机构名称"), MaxLength(32, ErrorMessage = "机构名称 不能超过 32 个字符")]
public string TeacherName { get; set; }
/// <summary>
/// 员工照片
/// </summary>
[Display(Name = "PhotoUrl"), Description("员工照片"), MaxLength(256, ErrorMessage = "员工照片 不能超过 256 个字符")]
public string PhotoUrl { get; set; }
/// <summary>
/// 性别
/// </summary>
[Display(Name = "Gender"), Description("性别"), MaxLength(32, ErrorMessage = "性别 不能超过 32 个字符")]
public string Gender { get; set; }
/// <summary>
/// 邮箱
/// </summary>
[Display(Name = "Email"), Description("邮箱"), MaxLength(64, ErrorMessage = "邮箱 不能超过 64 个字符")]
public string Email { get; set; }
/// <summary>
/// 手机号码
/// </summary>
[Display(Name = "Mobile"), Description("手机号码"), MaxLength(32, ErrorMessage = "手机号码 不能超过 32 个字符")]
public string Mobile { get; set; }
/// <summary>
/// 讲师等级
/// </summary>
[Display(Name = "TeacherLevel"), Description("讲师等级"), MaxLength(32, ErrorMessage = "讲师等级 不能超过 32 个字符")]
public string TeacherLevel { get; set; }
/// <summary>
/// 课时费
/// </summary>
[Display(Name = "Price"), Description("课时费"), Column(TypeName = "decimal(20,2)")]
public decimal? Price { get; set; }
/// <summary>
/// 擅长领域
/// </summary>
[Display(Name = "SkillPoints"), Description("擅长领域"), MaxLength(256, ErrorMessage = "擅长领域 不能超过 256 个字符")]
public string SkillPoints { get; set; }
/// <summary>
/// 备注
/// </summary>
[Display(Name = "RemarkSz"), Description("备注"), MaxLength(2000, ErrorMessage = "备注 不能超过 2000 个字符")]
public string RemarkSz { get; set; }
/// <summary>
/// 默认标志
/// </summary>
public int? IsDefault { get; set; }
/// <summary>
/// 预留字段1
/// </summary>
[Display(Name = "Reverse1"), Description("预留字段1"), MaxLength(1000, ErrorMessage = "预留字段1 不能超过 1000 个字符")]
public string Reverse1 { get; set; }
/// <summary>
/// 预留字段2
/// </summary>
[Display(Name = "Reverse2"), Description("预留字段2"), MaxLength(1000, ErrorMessage = "预留字段2 不能超过 1000 个字符")]
public string Reverse2 { get; set; }
/// <summary>
/// 预留字段3
/// </summary>
[Display(Name = "Reverse3"), Description("预留字段3"), MaxLength(1000, ErrorMessage = "预留字段3 不能超过 1000 个字符")]
public string Reverse3 { get; set; }
/// <summary>
/// 预留字段4
/// </summary>
[Display(Name = "Reverse4"), Description("预留字段4"), MaxLength(1000, ErrorMessage = "预留字段4 不能超过 1000 个字符")]
public string Reverse4 { get; set; }
/// <summary>
/// 预留字段5
/// </summary>
[Display(Name = "Reverse5"), Description("预留字段5"), MaxLength(1000, ErrorMessage = "预留字段5 不能超过 1000 个字符")]
public string Reverse5 { get; set; }
/// <summary>
/// 预留字段6
/// </summary>
[Display(Name = "Reverse6"), Description("预留字段6"), MaxLength(1000, ErrorMessage = "预留字段6 不能超过 1000 个字符")]
public string Reverse6 { get; set; }
/// <summary>
/// 预留字段7
/// </summary>
[Display(Name = "Reverse7"), Description("预留字段7"), MaxLength(1000, ErrorMessage = "预留字段7 不能超过 1000 个字符")]
public string Reverse7 { get; set; }
/// <summary>
/// 预留字段8
/// </summary>
[Display(Name = "Reverse8"), Description("预留字段8"), MaxLength(1000, ErrorMessage = "预留字段8 不能超过 1000 个字符")]
public string Reverse8 { get; set; }
/// <summary>
/// 预留字段9
/// </summary>
[Display(Name = "Reverse9"), Description("预留字段9"), MaxLength(1000, ErrorMessage = "预留字段9 不能超过 1000 个字符")]
public string Reverse9 { get; set; }
/// <summary>
/// 预留字段10
/// </summary>
[Display(Name = "Reverse10"), Description("预留字段10"), MaxLength(1000, ErrorMessage = "预留字段10 不能超过 1000 个字符")]
public string Reverse10 { get; set; }
/// <summary>
/// 预留字段11
/// </summary>
public int? ReverseI1 { get; set; }
/// <summary>
/// 预留字段12
/// </summary>
public int? ReverseI2 { get; set; }
}
}

@ -0,0 +1,137 @@
/* ,
* Ghre_TeacherAttachment.cs
*
* N / A
* Ghre_TeacherAttachment
*
* Ver
*
*V0.01 2024/6/27 14:06:11 SimonHsiao
*
* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved.
*
*  
* SimonHsiao
*
*/
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
namespace Tiobon.Core.Model.Models
{
/// <summary>
/// Ghre_TeacherAttachment (Dto.Base)
/// </summary>
public class Ghre_TeacherAttachmentBase
{
/// <summary>
/// 机构ID
/// </summary>
public long? TeacherId { get; set; }
/// <summary>
/// 编号
/// </summary>
[Display(Name = "CertificateNo"), Description("编号"), MaxLength(32, ErrorMessage = "编号 不能超过 32 个字符")]
public string CertificateNo { get; set; }
/// <summary>
/// 名称
/// </summary>
[Display(Name = "CertificateName"), Description("名称"), MaxLength(32, ErrorMessage = "名称 不能超过 32 个字符")]
public string CertificateName { get; set; }
/// <summary>
/// 生效日期
/// </summary>
public DateTime? EffectiveDate { get; set; }
/// <summary>
/// 失效日期
/// </summary>
public DateTime? ExpirationDate { get; set; }
/// <summary>
/// 备注
/// </summary>
[Display(Name = "RemarkSz"), Description("备注"), MaxLength(2000, ErrorMessage = "备注 不能超过 2000 个字符")]
public string RemarkSz { get; set; }
/// <summary>
/// 默认标志
/// </summary>
public int? IsDefault { get; set; }
/// <summary>
/// 预留字段1
/// </summary>
[Display(Name = "Reverse1"), Description("预留字段1"), MaxLength(1000, ErrorMessage = "预留字段1 不能超过 1000 个字符")]
public string Reverse1 { get; set; }
/// <summary>
/// 预留字段2
/// </summary>
[Display(Name = "Reverse2"), Description("预留字段2"), MaxLength(1000, ErrorMessage = "预留字段2 不能超过 1000 个字符")]
public string Reverse2 { get; set; }
/// <summary>
/// 预留字段3
/// </summary>
[Display(Name = "Reverse3"), Description("预留字段3"), MaxLength(1000, ErrorMessage = "预留字段3 不能超过 1000 个字符")]
public string Reverse3 { get; set; }
/// <summary>
/// 预留字段4
/// </summary>
[Display(Name = "Reverse4"), Description("预留字段4"), MaxLength(1000, ErrorMessage = "预留字段4 不能超过 1000 个字符")]
public string Reverse4 { get; set; }
/// <summary>
/// 预留字段5
/// </summary>
[Display(Name = "Reverse5"), Description("预留字段5"), MaxLength(1000, ErrorMessage = "预留字段5 不能超过 1000 个字符")]
public string Reverse5 { get; set; }
/// <summary>
/// 预留字段6
/// </summary>
[Display(Name = "Reverse6"), Description("预留字段6"), MaxLength(1000, ErrorMessage = "预留字段6 不能超过 1000 个字符")]
public string Reverse6 { get; set; }
/// <summary>
/// 预留字段7
/// </summary>
[Display(Name = "Reverse7"), Description("预留字段7"), MaxLength(1000, ErrorMessage = "预留字段7 不能超过 1000 个字符")]
public string Reverse7 { get; set; }
/// <summary>
/// 预留字段8
/// </summary>
[Display(Name = "Reverse8"), Description("预留字段8"), MaxLength(1000, ErrorMessage = "预留字段8 不能超过 1000 个字符")]
public string Reverse8 { get; set; }
/// <summary>
/// 预留字段9
/// </summary>
[Display(Name = "Reverse9"), Description("预留字段9"), MaxLength(1000, ErrorMessage = "预留字段9 不能超过 1000 个字符")]
public string Reverse9 { get; set; }
/// <summary>
/// 预留字段10
/// </summary>
[Display(Name = "Reverse10"), Description("预留字段10"), MaxLength(1000, ErrorMessage = "预留字段10 不能超过 1000 个字符")]
public string Reverse10 { get; set; }
/// <summary>
/// 预留字段11
/// </summary>
public int? ReverseI1 { get; set; }
/// <summary>
/// 预留字段12
/// </summary>
public int? ReverseI2 { get; set; }
}
}

@ -0,0 +1,205 @@
/* ,
* Ghro_Dept.cs
*
* N / A
* Ghro_Dept
*
* Ver
*
*V0.01 2024/6/27 15:40:05 SimonHsiao
*
* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved.
*
*  
* SimonHsiao
*
*/
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
namespace Tiobon.Core.Model.Models
{
/// <summary>
/// Ghro_Dept (Dto.Base)
/// </summary>
public class Ghro_DeptBase
{
/// <summary>
/// DeptID
/// </summary>
public int? DeptID { get; set; }
/// <summary>
/// DeptNo
/// </summary>
[Display(Name = "DeptNo"), Description("DeptNo"), MaxLength(100, ErrorMessage = "DeptNo 不能超过 100 个字符")]
public string DeptNo { get; set; }
/// <summary>
/// DeptName
/// </summary>
[Display(Name = "DeptName"), Description("DeptName"), MaxLength(200, ErrorMessage = "DeptName 不能超过 200 个字符")]
public string DeptName { get; set; }
/// <summary>
/// DeptEname
/// </summary>
[Display(Name = "DeptEname"), Description("DeptEname"), MaxLength(200, ErrorMessage = "DeptEname 不能超过 200 个字符")]
public string DeptEname { get; set; }
/// <summary>
/// BeginDate
/// </summary>
public DateTime? BeginDate { get; set; }
/// <summary>
/// EndDate
/// </summary>
public DateTime? EndDate { get; set; }
/// <summary>
/// DataBelongID
/// </summary>
[Display(Name = "DataBelongID"), Description("DataBelongID"), MaxLength(-1, ErrorMessage = "DataBelongID 不能超过 -1 个字符")]
public string DataBelongID { get; set; }
/// <summary>
/// Mkey
/// </summary>
[Display(Name = "Mkey"), Description("Mkey"), MaxLength(1000, ErrorMessage = "Mkey 不能超过 1000 个字符")]
public string Mkey { get; set; }
/// <summary>
/// DeptType
/// </summary>
[Display(Name = "DeptType"), Description("DeptType"), MaxLength(100, ErrorMessage = "DeptType 不能超过 100 个字符")]
public string DeptType { get; set; }
/// <summary>
/// DeptType1
/// </summary>
[Display(Name = "DeptType1"), Description("DeptType1"), MaxLength(100, ErrorMessage = "DeptType1 不能超过 100 个字符")]
public string DeptType1 { get; set; }
/// <summary>
/// DeptType2
/// </summary>
[Display(Name = "DeptType2"), Description("DeptType2"), MaxLength(100, ErrorMessage = "DeptType2 不能超过 100 个字符")]
public string DeptType2 { get; set; }
/// <summary>
/// DeptLevel
/// </summary>
[Display(Name = "DeptLevel"), Description("DeptLevel"), MaxLength(100, ErrorMessage = "DeptLevel 不能超过 100 个字符")]
public string DeptLevel { get; set; }
/// <summary>
/// DeptManagerID
/// </summary>
public int? DeptManagerID { get; set; }
/// <summary>
/// DeptManagerID2
/// </summary>
public int? DeptManagerID2 { get; set; }
/// <summary>
/// DeptAssID
/// </summary>
public int? DeptAssID { get; set; }
/// <summary>
/// ParentDeptID
/// </summary>
public int? ParentDeptID { get; set; }
/// <summary>
/// ParentDeptID2
/// </summary>
public int? ParentDeptID2 { get; set; }
/// <summary>
/// RemarkSz
/// </summary>
[Display(Name = "RemarkSz"), Description("RemarkSz"), MaxLength(2000, ErrorMessage = "RemarkSz 不能超过 2000 个字符")]
public string RemarkSz { get; set; }
/// <summary>
/// SortNo
/// </summary>
public int? SortNo { get; set; }
/// <summary>
/// IsDefault
/// </summary>
public int? IsDefault { get; set; }
/// <summary>
/// AttachmentIDs
/// </summary>
[Display(Name = "AttachmentIDs"), Description("AttachmentIDs"), MaxLength(-1, ErrorMessage = "AttachmentIDs 不能超过 -1 个字符")]
public string AttachmentIDs { get; set; }
/// <summary>
/// Reverse1
/// </summary>
[Display(Name = "Reverse1"), Description("Reverse1"), MaxLength(1000, ErrorMessage = "Reverse1 不能超过 1000 个字符")]
public string Reverse1 { get; set; }
/// <summary>
/// Reverse2
/// </summary>
[Display(Name = "Reverse2"), Description("Reverse2"), MaxLength(1000, ErrorMessage = "Reverse2 不能超过 1000 个字符")]
public string Reverse2 { get; set; }
/// <summary>
/// Reverse3
/// </summary>
[Display(Name = "Reverse3"), Description("Reverse3"), MaxLength(1000, ErrorMessage = "Reverse3 不能超过 1000 个字符")]
public string Reverse3 { get; set; }
/// <summary>
/// Reverse4
/// </summary>
[Display(Name = "Reverse4"), Description("Reverse4"), MaxLength(1000, ErrorMessage = "Reverse4 不能超过 1000 个字符")]
public string Reverse4 { get; set; }
/// <summary>
/// Reverse5
/// </summary>
[Display(Name = "Reverse5"), Description("Reverse5"), MaxLength(1000, ErrorMessage = "Reverse5 不能超过 1000 个字符")]
public string Reverse5 { get; set; }
/// <summary>
/// DisplayDirection
/// </summary>
[Display(Name = "DisplayDirection"), Description("DisplayDirection"), MaxLength(100, ErrorMessage = "DisplayDirection 不能超过 100 个字符")]
public string DisplayDirection { get; set; }
/// <summary>
/// DeptColor
/// </summary>
[Display(Name = "DeptColor"), Description("DeptColor"), MaxLength(100, ErrorMessage = "DeptColor 不能超过 100 个字符")]
public string DeptColor { get; set; }
/// <summary>
/// DeptIcon
/// </summary>
[Display(Name = "DeptIcon"), Description("DeptIcon"), MaxLength(100, ErrorMessage = "DeptIcon 不能超过 100 个字符")]
public string DeptIcon { get; set; }
/// <summary>
/// ShortName
/// </summary>
[Display(Name = "ShortName"), Description("ShortName"), MaxLength(200, ErrorMessage = "ShortName 不能超过 200 个字符")]
public string ShortName { get; set; }
/// <summary>
/// DeptDataType
/// </summary>
[Display(Name = "DeptDataType"), Description("DeptDataType"), MaxLength(100, ErrorMessage = "DeptDataType 不能超过 100 个字符")]
public string DeptDataType { get; set; }
}
}

@ -0,0 +1,33 @@
/* ,
* Ghre_Teacher.cs
*
* N / A
* Ghre_Teacher
*
* Ver
*
*V0.01 2024/6/27 14:05:58 SimonHsiao
*
* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved.
*
*  
* SimonHsiao
*
*/
using System.ComponentModel.DataAnnotations.Schema;
namespace Tiobon.Core.Model.Models
{
/// <summary>
/// Ghre_Teacher (Dto.EditInput)
/// </summary>
public class EditGhre_TeacherInput : Ghre_TeacherBase
{
[NotMapped]
public List<EditGhre_TeacherAttachmentInput> TeacherAttachments { get; set; }
}
}

@ -0,0 +1,32 @@
/* ,
* Ghre_TeacherAttachment.cs
*
* N / A
* Ghre_TeacherAttachment
*
* Ver
*
*V0.01 2024/6/27 14:06:11 SimonHsiao
*
* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved.
*
*  
* SimonHsiao
*
*/
using System.ComponentModel.DataAnnotations.Schema;
namespace Tiobon.Core.Model.Models
{
/// <summary>
/// Ghre_TeacherAttachment (Dto.EditInput)
/// </summary>
public class EditGhre_TeacherAttachmentInput : Ghre_TeacherAttachmentBase
{
[NotMapped]
public List<EditGhrs_AttachmentInput> Attachments { get; set; }
}
}

@ -0,0 +1,27 @@
/* ,
* Ghro_Dept.cs
*
* N / A
* Ghro_Dept
*
* Ver
*
*V0.01 2024/6/27 15:40:05 SimonHsiao
*
* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved.
*
*  
* SimonHsiao
*
*/
namespace Tiobon.Core.Model.Models
{
/// <summary>
/// Ghro_Dept (Dto.EditInput)
/// </summary>
public class EditGhro_DeptInput : Ghro_DeptBase
{
}
}

@ -0,0 +1,32 @@
/* ,
* Ghre_Teacher.cs
*
* N / A
* Ghre_Teacher
*
* Ver
*
*V0.01 2024/6/27 14:05:58 SimonHsiao
*
* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved.
*
*  
* SimonHsiao
*
*/
using System.ComponentModel.DataAnnotations.Schema;
namespace Tiobon.Core.Model.Models
{
/// <summary>
/// Ghre_Teacher (Dto.InsertInput)
/// </summary>
public class InsertGhre_TeacherInput : Ghre_TeacherBase
{
[NotMapped]
public List<InsertGhre_TeacherAttachmentInput> TeacherAttachments { get; set; }
}
}

@ -0,0 +1,31 @@
/* ,
* Ghre_TeacherAttachment.cs
*
* N / A
* Ghre_TeacherAttachment
*
* Ver
*
*V0.01 2024/6/27 14:06:11 SimonHsiao
*
* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved.
*
*  
* SimonHsiao
*
*/
using System.ComponentModel.DataAnnotations.Schema;
namespace Tiobon.Core.Model.Models
{
/// <summary>
/// Ghre_TeacherAttachment (Dto.InsertInput)
/// </summary>
public class InsertGhre_TeacherAttachmentInput : Ghre_TeacherAttachmentBase
{
[NotMapped]
public List<InsertGhrs_AttachmentInput> Attachments { get; set; }
}
}

@ -0,0 +1,27 @@
/* ,
* Ghro_Dept.cs
*
* N / A
* Ghro_Dept
*
* Ver
*
*V0.01 2024/6/27 15:40:05 SimonHsiao
*
* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved.
*
*  
* SimonHsiao
*
*/
namespace Tiobon.Core.Model.Models
{
/// <summary>
/// Ghro_Dept (Dto.InsertInput)
/// </summary>
public class InsertGhro_DeptInput : Ghro_DeptBase
{
}
}

@ -0,0 +1,188 @@
/* ,
* Ghre_Teacher.cs
*
* N / A
* Ghre_Teacher
*
* Ver
*
*V0.01 2024/6/27 14:05:58 SimonHsiao
*
* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved.
*
*  
* SimonHsiao
*
*/
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using SqlSugar;
namespace Tiobon.Core.Model.Models
{
/// <summary>
/// Ghre_Teacher (Model)
/// </summary>
[SugarTable("Ghre_Teacher", "Ghre_Teacher"), Entity(TableCnName = "Ghre_Teacher", TableName = "Ghre_Teacher")]
public class Ghre_Teacher : BasePoco
{
/// <summary>
/// 机构Id
/// </summary>
public long? SchoolId { get; set; }
/// <summary>
/// 部门ID
/// </summary>
public int? DeptID { get; set; }
/// <summary>
/// 员工ID
/// </summary>
public int? StaffId { get; set; }
/// <summary>
/// 讲师分类
/// </summary>
[Display(Name = "TeacherType"), Description("讲师分类"), MaxLength(32, ErrorMessage = "讲师分类 不能超过 32 个字符")]
public string TeacherType { get; set; }
/// <summary>
/// 机构编号
/// </summary>
[Display(Name = "TeacherNo"), Description("机构编号"), MaxLength(32, ErrorMessage = "机构编号 不能超过 32 个字符")]
public string TeacherNo { get; set; }
/// <summary>
/// 机构名称
/// </summary>
[Display(Name = "TeacherName"), Description("机构名称"), MaxLength(32, ErrorMessage = "机构名称 不能超过 32 个字符")]
public string TeacherName { get; set; }
/// <summary>
/// 员工照片
/// </summary>
[Display(Name = "PhotoUrl"), Description("员工照片"), MaxLength(256, ErrorMessage = "员工照片 不能超过 256 个字符")]
public string PhotoUrl { get; set; }
/// <summary>
/// 性别
/// </summary>
[Display(Name = "Gender"), Description("性别"), MaxLength(32, ErrorMessage = "性别 不能超过 32 个字符")]
public string Gender { get; set; }
/// <summary>
/// 邮箱
/// </summary>
[Display(Name = "Email"), Description("邮箱"), MaxLength(64, ErrorMessage = "邮箱 不能超过 64 个字符")]
public string Email { get; set; }
/// <summary>
/// 手机号码
/// </summary>
[Display(Name = "Mobile"), Description("手机号码"), MaxLength(32, ErrorMessage = "手机号码 不能超过 32 个字符")]
public string Mobile { get; set; }
/// <summary>
/// 讲师等级
/// </summary>
[Display(Name = "TeacherLevel"), Description("讲师等级"), MaxLength(32, ErrorMessage = "讲师等级 不能超过 32 个字符")]
public string TeacherLevel { get; set; }
/// <summary>
/// 课时费
/// </summary>
[Display(Name = "Price"), Description("课时费"), Column(TypeName = "decimal(20,2)")]
public decimal? Price { get; set; }
/// <summary>
/// 擅长领域
/// </summary>
[Display(Name = "SkillPoints"), Description("擅长领域"), MaxLength(256, ErrorMessage = "擅长领域 不能超过 256 个字符")]
public string SkillPoints { get; set; }
/// <summary>
/// 备注
/// </summary>
[Display(Name = "RemarkSz"), Description("备注"), MaxLength(2000, ErrorMessage = "备注 不能超过 2000 个字符")]
public string RemarkSz { get; set; }
/// <summary>
/// 默认标志
/// </summary>
public int? IsDefault { get; set; }
/// <summary>
/// 预留字段1
/// </summary>
[Display(Name = "Reverse1"), Description("预留字段1"), MaxLength(1000, ErrorMessage = "预留字段1 不能超过 1000 个字符")]
public string Reverse1 { get; set; }
/// <summary>
/// 预留字段2
/// </summary>
[Display(Name = "Reverse2"), Description("预留字段2"), MaxLength(1000, ErrorMessage = "预留字段2 不能超过 1000 个字符")]
public string Reverse2 { get; set; }
/// <summary>
/// 预留字段3
/// </summary>
[Display(Name = "Reverse3"), Description("预留字段3"), MaxLength(1000, ErrorMessage = "预留字段3 不能超过 1000 个字符")]
public string Reverse3 { get; set; }
/// <summary>
/// 预留字段4
/// </summary>
[Display(Name = "Reverse4"), Description("预留字段4"), MaxLength(1000, ErrorMessage = "预留字段4 不能超过 1000 个字符")]
public string Reverse4 { get; set; }
/// <summary>
/// 预留字段5
/// </summary>
[Display(Name = "Reverse5"), Description("预留字段5"), MaxLength(1000, ErrorMessage = "预留字段5 不能超过 1000 个字符")]
public string Reverse5 { get; set; }
/// <summary>
/// 预留字段6
/// </summary>
[Display(Name = "Reverse6"), Description("预留字段6"), MaxLength(1000, ErrorMessage = "预留字段6 不能超过 1000 个字符")]
public string Reverse6 { get; set; }
/// <summary>
/// 预留字段7
/// </summary>
[Display(Name = "Reverse7"), Description("预留字段7"), MaxLength(1000, ErrorMessage = "预留字段7 不能超过 1000 个字符")]
public string Reverse7 { get; set; }
/// <summary>
/// 预留字段8
/// </summary>
[Display(Name = "Reverse8"), Description("预留字段8"), MaxLength(1000, ErrorMessage = "预留字段8 不能超过 1000 个字符")]
public string Reverse8 { get; set; }
/// <summary>
/// 预留字段9
/// </summary>
[Display(Name = "Reverse9"), Description("预留字段9"), MaxLength(1000, ErrorMessage = "预留字段9 不能超过 1000 个字符")]
public string Reverse9 { get; set; }
/// <summary>
/// 预留字段10
/// </summary>
[Display(Name = "Reverse10"), Description("预留字段10"), MaxLength(1000, ErrorMessage = "预留字段10 不能超过 1000 个字符")]
public string Reverse10 { get; set; }
/// <summary>
/// 预留字段11
/// </summary>
public int? ReverseI1 { get; set; }
/// <summary>
/// 预留字段12
/// </summary>
public int? ReverseI2 { get; set; }
}
}

@ -0,0 +1,139 @@
/* ,
* Ghre_TeacherAttachment.cs
*
* N / A
* Ghre_TeacherAttachment
*
* Ver
*
*V0.01 2024/6/27 14:06:11 SimonHsiao
*
* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved.
*
*  
* SimonHsiao
*
*/
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using SqlSugar;
namespace Tiobon.Core.Model.Models
{
/// <summary>
/// Ghre_TeacherAttachment (Model)
/// </summary>
[SugarTable("Ghre_TeacherAttachment", "Ghre_TeacherAttachment"), Entity(TableCnName = "Ghre_TeacherAttachment", TableName = "Ghre_TeacherAttachment")]
public class Ghre_TeacherAttachment : BasePoco
{
/// <summary>
/// 机构ID
/// </summary>
public long? TeacherId { get; set; }
/// <summary>
/// 编号
/// </summary>
[Display(Name = "CertificateNo"), Description("编号"), MaxLength(32, ErrorMessage = "编号 不能超过 32 个字符")]
public string CertificateNo { get; set; }
/// <summary>
/// 名称
/// </summary>
[Display(Name = "CertificateName"), Description("名称"), MaxLength(32, ErrorMessage = "名称 不能超过 32 个字符")]
public string CertificateName { get; set; }
/// <summary>
/// 生效日期
/// </summary>
public DateTime? EffectiveDate { get; set; }
/// <summary>
/// 失效日期
/// </summary>
public DateTime? ExpirationDate { get; set; }
/// <summary>
/// 备注
/// </summary>
[Display(Name = "RemarkSz"), Description("备注"), MaxLength(2000, ErrorMessage = "备注 不能超过 2000 个字符")]
public string RemarkSz { get; set; }
/// <summary>
/// 默认标志
/// </summary>
public int? IsDefault { get; set; }
/// <summary>
/// 预留字段1
/// </summary>
[Display(Name = "Reverse1"), Description("预留字段1"), MaxLength(1000, ErrorMessage = "预留字段1 不能超过 1000 个字符")]
public string Reverse1 { get; set; }
/// <summary>
/// 预留字段2
/// </summary>
[Display(Name = "Reverse2"), Description("预留字段2"), MaxLength(1000, ErrorMessage = "预留字段2 不能超过 1000 个字符")]
public string Reverse2 { get; set; }
/// <summary>
/// 预留字段3
/// </summary>
[Display(Name = "Reverse3"), Description("预留字段3"), MaxLength(1000, ErrorMessage = "预留字段3 不能超过 1000 个字符")]
public string Reverse3 { get; set; }
/// <summary>
/// 预留字段4
/// </summary>
[Display(Name = "Reverse4"), Description("预留字段4"), MaxLength(1000, ErrorMessage = "预留字段4 不能超过 1000 个字符")]
public string Reverse4 { get; set; }
/// <summary>
/// 预留字段5
/// </summary>
[Display(Name = "Reverse5"), Description("预留字段5"), MaxLength(1000, ErrorMessage = "预留字段5 不能超过 1000 个字符")]
public string Reverse5 { get; set; }
/// <summary>
/// 预留字段6
/// </summary>
[Display(Name = "Reverse6"), Description("预留字段6"), MaxLength(1000, ErrorMessage = "预留字段6 不能超过 1000 个字符")]
public string Reverse6 { get; set; }
/// <summary>
/// 预留字段7
/// </summary>
[Display(Name = "Reverse7"), Description("预留字段7"), MaxLength(1000, ErrorMessage = "预留字段7 不能超过 1000 个字符")]
public string Reverse7 { get; set; }
/// <summary>
/// 预留字段8
/// </summary>
[Display(Name = "Reverse8"), Description("预留字段8"), MaxLength(1000, ErrorMessage = "预留字段8 不能超过 1000 个字符")]
public string Reverse8 { get; set; }
/// <summary>
/// 预留字段9
/// </summary>
[Display(Name = "Reverse9"), Description("预留字段9"), MaxLength(1000, ErrorMessage = "预留字段9 不能超过 1000 个字符")]
public string Reverse9 { get; set; }
/// <summary>
/// 预留字段10
/// </summary>
[Display(Name = "Reverse10"), Description("预留字段10"), MaxLength(1000, ErrorMessage = "预留字段10 不能超过 1000 个字符")]
public string Reverse10 { get; set; }
/// <summary>
/// 预留字段11
/// </summary>
public int? ReverseI1 { get; set; }
/// <summary>
/// 预留字段12
/// </summary>
public int? ReverseI2 { get; set; }
}
}

@ -0,0 +1,207 @@
/* ,
* Ghro_Dept.cs
*
* N / A
* Ghro_Dept
*
* Ver
*
*V0.01 2024/6/27 15:40:05 SimonHsiao
*
* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved.
*
*  
* SimonHsiao
*
*/
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using SqlSugar;
namespace Tiobon.Core.Model.Models
{
/// <summary>
/// Ghro_Dept (Model)
/// </summary>
[SugarTable("Ghro_Dept", "Ghro_Dept"), Entity(TableCnName = "Ghro_Dept", TableName = "Ghro_Dept")]
public class Ghro_Dept : BasePoco1
{
/// <summary>
/// DeptID
/// </summary>
public int? DeptID { get; set; }
/// <summary>
/// DeptNo
/// </summary>
[Display(Name = "DeptNo"), Description("DeptNo"), MaxLength(100, ErrorMessage = "DeptNo 不能超过 100 个字符")]
public string DeptNo { get; set; }
/// <summary>
/// DeptName
/// </summary>
[Display(Name = "DeptName"), Description("DeptName"), MaxLength(200, ErrorMessage = "DeptName 不能超过 200 个字符")]
public string DeptName { get; set; }
/// <summary>
/// DeptEname
/// </summary>
[Display(Name = "DeptEname"), Description("DeptEname"), MaxLength(200, ErrorMessage = "DeptEname 不能超过 200 个字符")]
public string DeptEname { get; set; }
/// <summary>
/// BeginDate
/// </summary>
public DateTime? BeginDate { get; set; }
/// <summary>
/// EndDate
/// </summary>
public DateTime? EndDate { get; set; }
/// <summary>
/// DataBelongID
/// </summary>
[Display(Name = "DataBelongID"), Description("DataBelongID"), MaxLength(-1, ErrorMessage = "DataBelongID 不能超过 -1 个字符")]
public string DataBelongID { get; set; }
/// <summary>
/// Mkey
/// </summary>
[Display(Name = "Mkey"), Description("Mkey"), MaxLength(1000, ErrorMessage = "Mkey 不能超过 1000 个字符")]
public string Mkey { get; set; }
/// <summary>
/// DeptType
/// </summary>
[Display(Name = "DeptType"), Description("DeptType"), MaxLength(100, ErrorMessage = "DeptType 不能超过 100 个字符")]
public string DeptType { get; set; }
/// <summary>
/// DeptType1
/// </summary>
[Display(Name = "DeptType1"), Description("DeptType1"), MaxLength(100, ErrorMessage = "DeptType1 不能超过 100 个字符")]
public string DeptType1 { get; set; }
/// <summary>
/// DeptType2
/// </summary>
[Display(Name = "DeptType2"), Description("DeptType2"), MaxLength(100, ErrorMessage = "DeptType2 不能超过 100 个字符")]
public string DeptType2 { get; set; }
/// <summary>
/// DeptLevel
/// </summary>
[Display(Name = "DeptLevel"), Description("DeptLevel"), MaxLength(100, ErrorMessage = "DeptLevel 不能超过 100 个字符")]
public string DeptLevel { get; set; }
/// <summary>
/// DeptManagerID
/// </summary>
public int? DeptManagerID { get; set; }
/// <summary>
/// DeptManagerID2
/// </summary>
public int? DeptManagerID2 { get; set; }
/// <summary>
/// DeptAssID
/// </summary>
public int? DeptAssID { get; set; }
/// <summary>
/// ParentDeptID
/// </summary>
public int? ParentDeptID { get; set; }
/// <summary>
/// ParentDeptID2
/// </summary>
public int? ParentDeptID2 { get; set; }
/// <summary>
/// RemarkSz
/// </summary>
[Display(Name = "RemarkSz"), Description("RemarkSz"), MaxLength(2000, ErrorMessage = "RemarkSz 不能超过 2000 个字符")]
public string RemarkSz { get; set; }
/// <summary>
/// SortNo
/// </summary>
public int? SortNo { get; set; }
/// <summary>
/// IsDefault
/// </summary>
public int? IsDefault { get; set; }
/// <summary>
/// AttachmentIDs
/// </summary>
[Display(Name = "AttachmentIDs"), Description("AttachmentIDs"), MaxLength(-1, ErrorMessage = "AttachmentIDs 不能超过 -1 个字符")]
public string AttachmentIDs { get; set; }
/// <summary>
/// Reverse1
/// </summary>
[Display(Name = "Reverse1"), Description("Reverse1"), MaxLength(1000, ErrorMessage = "Reverse1 不能超过 1000 个字符")]
public string Reverse1 { get; set; }
/// <summary>
/// Reverse2
/// </summary>
[Display(Name = "Reverse2"), Description("Reverse2"), MaxLength(1000, ErrorMessage = "Reverse2 不能超过 1000 个字符")]
public string Reverse2 { get; set; }
/// <summary>
/// Reverse3
/// </summary>
[Display(Name = "Reverse3"), Description("Reverse3"), MaxLength(1000, ErrorMessage = "Reverse3 不能超过 1000 个字符")]
public string Reverse3 { get; set; }
/// <summary>
/// Reverse4
/// </summary>
[Display(Name = "Reverse4"), Description("Reverse4"), MaxLength(1000, ErrorMessage = "Reverse4 不能超过 1000 个字符")]
public string Reverse4 { get; set; }
/// <summary>
/// Reverse5
/// </summary>
[Display(Name = "Reverse5"), Description("Reverse5"), MaxLength(1000, ErrorMessage = "Reverse5 不能超过 1000 个字符")]
public string Reverse5 { get; set; }
/// <summary>
/// DisplayDirection
/// </summary>
[Display(Name = "DisplayDirection"), Description("DisplayDirection"), MaxLength(100, ErrorMessage = "DisplayDirection 不能超过 100 个字符")]
public string DisplayDirection { get; set; }
/// <summary>
/// DeptColor
/// </summary>
[Display(Name = "DeptColor"), Description("DeptColor"), MaxLength(100, ErrorMessage = "DeptColor 不能超过 100 个字符")]
public string DeptColor { get; set; }
/// <summary>
/// DeptIcon
/// </summary>
[Display(Name = "DeptIcon"), Description("DeptIcon"), MaxLength(100, ErrorMessage = "DeptIcon 不能超过 100 个字符")]
public string DeptIcon { get; set; }
/// <summary>
/// ShortName
/// </summary>
[Display(Name = "ShortName"), Description("ShortName"), MaxLength(200, ErrorMessage = "ShortName 不能超过 200 个字符")]
public string ShortName { get; set; }
/// <summary>
/// DeptDataType
/// </summary>
[Display(Name = "DeptDataType"), Description("DeptDataType"), MaxLength(100, ErrorMessage = "DeptDataType 不能超过 100 个字符")]
public string DeptDataType { get; set; }
}
}

@ -0,0 +1,42 @@
/* ,
* Ghre_Teacher.cs
*
* N / A
* Ghre_Teacher
*
* Ver
*
*V0.01 2024/6/27 14:05:58 SimonHsiao
*
* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved.
*
*  
* SimonHsiao
*
*/
namespace Tiobon.Core.Model.Models;
/// <summary>
/// Ghre_Teacher(Dto.View)
/// </summary>
public class Ghre_TeacherDto : Ghre_Teacher
{
/// <summary>
/// 创建信息
/// </summary>
public string CreateDataInfo { get; set; }
/// <summary>
/// 修改信息
/// </summary>
public string UpdateDataInfo { get; set; }
public string TeacherTypeLabel { get; set; }
public string TeacherLevelLabel { get; set; }
public string DeptOrSchoolName { get; set; }
public string GenderLabel { get; set; }
public List<Ghre_TeacherAttachmentDto> TeacherAttachments { get; set; }
}

@ -0,0 +1,36 @@
/* ,
* Ghre_TeacherAttachment.cs
*
* N / A
* Ghre_TeacherAttachment
*
* Ver
*
*V0.01 2024/6/27 14:06:11 SimonHsiao
*
* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved.
*
*  
* SimonHsiao
*
*/
namespace Tiobon.Core.Model.Models;
/// <summary>
/// Ghre_TeacherAttachment(Dto.View)
/// </summary>
public class Ghre_TeacherAttachmentDto : Ghre_TeacherAttachment
{
/// <summary>
/// 创建信息
/// </summary>
public string CreateDataInfo { get; set; }
/// <summary>
/// 修改信息
/// </summary>
public string UpdateDataInfo { get; set; }
public List<Ghrs_AttachmentDto> Attachments { get; set; } = new List<Ghrs_AttachmentDto>();
}

@ -0,0 +1,34 @@
/* ,
* Ghro_Dept.cs
*
* N / A
* Ghro_Dept
*
* Ver
*
*V0.01 2024/6/27 15:40:05 SimonHsiao
*
* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved.
*
*  
* SimonHsiao
*
*/
namespace Tiobon.Core.Model.Models;
/// <summary>
/// Ghro_Dept(Dto.View)
/// </summary>
public class Ghro_DeptDto : Ghro_Dept
{
/// <summary>
/// 创建信息
/// </summary>
public string CreateDataInfo { get; set; }
/// <summary>
/// 修改信息
/// </summary>
public string UpdateDataInfo { get; set; }
}

@ -715,7 +715,7 @@ public class BaseServices<TEntity, TEntityDto, TInsertDto, TEditDto> : IBaseServ
{ {
return await QueryFilterPage(filter, null); return await QueryFilterPage(filter, null);
} }
public virtual async Task<ServicePageResult<TEntityDto>> QueryFilterPage(QueryBody filter, string condition) public virtual async Task<ServicePageResult<TEntityDto>> QueryFilterPage(QueryBody filter, string condition, bool? IsEnable = true)
{ {
if (string.IsNullOrWhiteSpace(filter.orderBy)) if (string.IsNullOrWhiteSpace(filter.orderBy))
filter.orderBy = "CreateTime1 DESC"; filter.orderBy = "CreateTime1 DESC";
@ -738,10 +738,15 @@ public class BaseServices<TEntity, TEntityDto, TInsertDto, TEditDto> : IBaseServ
'') UpdateDataInfo, ISNULL(A.UpdateTime, A.CreateTime) CreateTime1 '') UpdateDataInfo, ISNULL(A.UpdateTime, A.CreateTime) CreateTime1
FROM {entityType.GetEntityTableName()} A"; FROM {entityType.GetEntityTableName()} A";
string conditions = " WHERE IsEnable = 1"; string conditions = " WHERE 1=1 ";
if (!string.IsNullOrWhiteSpace(condition))
conditions += "AND " + condition; if (IsEnable == true)
conditions += " AND IsEnable = 1";
else if (IsEnable == false)
conditions += " AND IsEnable = 0";
if (!string.IsNullOrWhiteSpace(condition))
conditions += " AND " + condition;
var properties = entityType.GetGenericProperties(); var properties = entityType.GetGenericProperties();
@ -789,7 +794,7 @@ public class BaseServices<TEntity, TEntityDto, TInsertDto, TEditDto> : IBaseServ
conditions += $" AND {name} <'{jsonParam.columnValue}'"; conditions += $" AND {name} <'{jsonParam.columnValue}'";
break; break;
default: default:
break; break;
} }
} }
} }
@ -824,7 +829,7 @@ public class BaseServices<TEntity, TEntityDto, TInsertDto, TEditDto> : IBaseServ
AND defaultHidden = 'false' AND defaultHidden = 'false'
ORDER BY SortNo ASC"; ORDER BY SortNo ASC";
var columns = await Db.Ado.SqlQueryAsync<QueryExportColumn>(sql); var columns = await Db.Ado.SqlQueryAsync<QueryExportColumn>(sql);
var fieldDescs = new Dictionary<string, string>(); var fieldDescs = new Dictionary<string, string>();
if (body.exportSet.ExFields.Any()) if (body.exportSet.ExFields.Any())

@ -1042,8 +1042,9 @@ public partial class CommonServices : BaseServices<RootEntityTkey<int>>, ICommon
case "F_CourseScene": case "F_CourseScene":
index = result.JM_PageControlT1.Toolbar.FindIndex(x => x.fnKey == "BatchUpdateYN"); index = result.JM_PageControlT1.Toolbar.FindIndex(x => x.fnKey == "BatchUpdateYN");
result.JM_PageControlT1.Toolbar.RemoveAt(index); result.JM_PageControlT1.Toolbar.RemoveAt(index);
break; break;
case "F_SchoolManage": case "F_SchoolManage":
case "F_TeacherManage":
toolbar = result.JM_PageControlT1.Toolbar.Where(x => x.fnKey == "NewYN").FirstOrDefault(); toolbar = result.JM_PageControlT1.Toolbar.Where(x => x.fnKey == "NewYN").FirstOrDefault();
if (toolbar != null) { toolbar.fnKey = "TBD1YN"; } if (toolbar != null) { toolbar.fnKey = "TBD1YN"; }
toolbar = result.JM_PageControlT1.Toolbar.Where(x => x.fnKey == "UpdateYN").FirstOrDefault(); toolbar = result.JM_PageControlT1.Toolbar.Where(x => x.fnKey == "UpdateYN").FirstOrDefault();

@ -8,8 +8,6 @@ using Tiobon.Core.Common;
using Tiobon.Core.Model; using Tiobon.Core.Model;
using Newtonsoft.Json.Linq; using Newtonsoft.Json.Linq;
using Newtonsoft.Json; using Newtonsoft.Json;
using MathNet.Numerics.Distributions;
using K4os.Hash.xxHash;
using AgileObjects.AgileMapper; using AgileObjects.AgileMapper;
namespace Tiobon.Core.Services; namespace Tiobon.Core.Services;

@ -0,0 +1,23 @@

using Tiobon.Core.IServices;
using Tiobon.Core.Model.Models;
using Tiobon.Core.Services.BASE;
using Tiobon.Core.IRepository.Base;
using Tiobon.Core.Common.Caches;
namespace Tiobon.Core.Services
{
/// <summary>
/// Ghre_TeacherAttachment (服务)
/// </summary>
public class Ghre_TeacherAttachmentServices : BaseServices<Ghre_TeacherAttachment, Ghre_TeacherAttachmentDto, InsertGhre_TeacherAttachmentInput, EditGhre_TeacherAttachmentInput>, IGhre_TeacherAttachmentServices
{
private readonly IBaseRepository<Ghre_TeacherAttachment> _dal;
public Ghre_TeacherAttachmentServices(ICaching caching, IBaseRepository<Ghre_TeacherAttachment> dal)
{
this._dal = dal;
base.BaseDal = dal;
base._caching = caching;
}
}
}

@ -0,0 +1,273 @@

using Tiobon.Core.IServices;
using Tiobon.Core.Model.Models;
using Tiobon.Core.Services.BASE;
using Tiobon.Core.IRepository.Base;
using Tiobon.Core.Common.Caches;
using Tiobon.Core.Common;
using Tiobon.Core.Model;
using AgileObjects.AgileMapper;
using Newtonsoft.Json.Linq;
using Tiobon.Core.Common.DB.Dapper.Extensions;
using Newtonsoft.Json;
namespace Tiobon.Core.Services;
/// <summary>
/// Ghre_Teacher (服务)
/// </summary>
public class Ghre_TeacherServices : BaseServices<Ghre_Teacher, Ghre_TeacherDto, InsertGhre_TeacherInput, EditGhre_TeacherInput>, IGhre_TeacherServices
{
private readonly IBaseRepository<Ghre_Teacher> _dal;
private IGhrs_AttachmentServices _ghrs_AttachmentServices;
private IGhre_TeacherAttachmentServices _ghre_TeacherAttachmentServices;
public Ghre_TeacherServices(ICaching caching,
IGhrs_AttachmentServices ghrs_AttachmentServices,
IGhre_TeacherAttachmentServices ghre_TeacherAttachmentServices,
IBaseRepository<Ghre_Teacher> dal)
{
this._dal = dal;
base.BaseDal = dal;
base._caching = caching;
_ghrs_AttachmentServices = ghrs_AttachmentServices;
_ghre_TeacherAttachmentServices = ghre_TeacherAttachmentServices;
}
public override async Task<ServicePageResult<Ghre_TeacherDto>> QueryFilterPage(QueryBody filter, string condition, bool? IsEnable = true)
{
if (string.IsNullOrWhiteSpace(filter.orderBy))
filter.orderBy = "CreateTime1 DESC";
if (filter.pageSize == 0)
filter.pageSize = 10000;
var countSql = @$" SELECT COUNT (1)
FROM (SELECT A.*,
A.TeacherNo + A.TeacherName TeacherName1,
CASE A.TeacherType
WHEN 'In' THEN B.DeptName
WHEN 'Out' THEN C.SchoolName
ELSE NULL
END 'DeptOrSchoolName1'
FROM Ghre_Teacher A
LEFT JOIN Ghro_Dept B ON A.DeptID = B.DeptID
LEFT JOIN Ghre_School C ON A.SchoolId = C.Id) A";
var sql1 = @$"DECLARE @langId INT = {filter.langId};";
var sql = @$"SELECT *
FROM (SELECT A.*,
ISNULL
((SELECT CASE WHEN @langId = 1 THEN UserName ELSE UserEname END
FROM Ghrs_User B
WHERE B.UserId = A.CreateBy),
'') CreateDataInfo,
ISNULL
((SELECT CASE WHEN @langId = 1 THEN UserName ELSE UserEname END
FROM Ghrs_User B
WHERE B.UserId = A.UpdateBy),
'') UpdateDataInfo,
ISNULL (A.UpdateTime, A.CreateTime) CreateTime1,
A.TeacherNo + A.TeacherName TeacherName1,
CASE A.TeacherType
WHEN 'In' THEN B.DeptName
WHEN 'Out' THEN C.SchoolName
ELSE NULL
END 'DeptOrSchoolName1'
FROM Ghre_Teacher A
LEFT JOIN Ghro_Dept B ON A.DeptID = B.DeptID
LEFT JOIN Ghre_School C ON A.SchoolId = C.Id) A";
string conditions = " WHERE 1=1 ";
if (IsEnable == true)
conditions += " AND IsEnable = 1";
else if (IsEnable == false)
conditions += " AND IsEnable = 0";
if (!string.IsNullOrWhiteSpace(condition))
conditions += " AND " + condition;
if (filter.jsonParam != null)
foreach (JProperty jProperty in filter.jsonParam.Properties())
{
var name = jProperty.Name;
var value = jProperty.Value.ToString();
if (name == "page" || name == "pageSize")
continue;
if (!string.IsNullOrWhiteSpace(value))
{
var jsonParam = JsonConvert.DeserializeObject<JsonParam>(value);
switch (jsonParam.operationKey)
{
case "Include":
conditions += $" AND {name} LIKE '%{jsonParam.columnValue}%'";
break;
case "NotInclude":
conditions += $" AND {name} NOT LIKE '%{jsonParam.columnValue}%'";
break;
case "IsNull":
conditions += $" AND {name} IS NULL";
break;
case "NotNull":
conditions += $" AND {name} IS NOT NULL";
break;
case "Equal":
conditions += $" AND {name} ='{jsonParam.columnValue}'";
break;
case "NotEqual":
conditions += $" AND {name} !='{jsonParam.columnValue}'";
break;
case "GreaterOrEqual"://大于等于
conditions += $" AND {name} >='{jsonParam.columnValue}'";
break;
case "Greater"://大于
conditions += $" AND {name} >'{jsonParam.columnValue}'";
break;
case "LessOrEqual"://小于等于
conditions += $" AND {name} <='{jsonParam.columnValue}'";
break;
case "Less "://小于
conditions += $" AND {name} <'{jsonParam.columnValue}'";
break;
default:
break;
}
}
}
sql += conditions;
countSql += conditions;
int total = await Db.Ado.GetIntAsync(countSql);
sql = "SELECT * FROM (SELECT *, ROW_NUMBER() OVER (ORDER BY " + filter.orderBy + ") NUM FROM (SELECT * FROM (" + sql + " ";
sql += ") A ) B ) C";
sql += " WHERE NUM <= " + filter.pageNum * filter.pageSize + " AND NUM >" + (filter.pageNum - 1) * filter.pageSize;
sql = sql1 + sql;
var entitys = await Db.Ado.SqlQueryAsync<Ghre_TeacherDto>(sql);
var data = new ServicePageResult<Ghre_TeacherDto>(filter.pageNum, total, filter.pageSize, entitys);
//});
var schoolIds = data.result.DT_TableDataT1.Where(x => x.SchoolId != null).Select(x => x.SchoolId.Value).Distinct().ToList();
var deptIDs = data.result.DT_TableDataT1.Where(x => x.DeptID != null).Select(x => x.DeptID).Distinct().ToList();
var depts = await Db.Queryable<Ghro_Dept>().Where(x => deptIDs.Contains(x.DeptID)).Select(x => new { x.DeptID, x.DeptName }).ToListAsync();
var schools = await Db.Queryable<Ghre_School>().Where(x => schoolIds.Contains(x.Id)).Select(x => new { x.Id, x.SchoolName }).ToListAsync();
data.result.DT_TableDataT1.ForEach(async x =>
{
x.GenderLabel = await GetParaLabel("Gender", x.Gender);
x.TeacherTypeLabel = await GetParaLabel("TrainingTeacherType", x.TeacherType);
x.TeacherLevelLabel = await GetParaLabel("TrainingTeacherLevel", x.TeacherLevel);
x.DeptOrSchoolName = x.TeacherType == "Out" ? schools.FirstOrDefault(o => o.Id == x.SchoolId)?.SchoolName : depts.FirstOrDefault(o => o.DeptID == x.DeptID)?.DeptName;
});
return data;
}
public override async Task<ServiceFormResult<Ghre_TeacherDto>> QueryForm(QueryForm body)
{
var data = await base.QueryForm(body);
var entitys = data.result.DT_TableDataT1;
var ids = entitys.Select(x => x.Id).ToList();
var teacherAttachments = await _ghre_TeacherAttachmentServices.QueryDto(x => ids.Contains(x.TeacherId.Value));
var ids1 = teacherAttachments.Select(x => x.Id.ToString()).ToList();
var attachments = await _ghrs_AttachmentServices.QueryDto(x => ids1.Contains(x.TableName));
teacherAttachments.ForEach(x =>
{
x.Attachments = attachments.Where(o => o.TableName == x.Id.ToString()).ToList();
});
entitys.ForEach(x =>
{
x.TeacherAttachments = teacherAttachments.Where(o => o.TeacherId == x.Id).ToList();
});
data.result.DT_TableDataT1 = entitys;
return data;
}
public override async Task<long> Add(InsertGhre_TeacherInput entity)
{
if (entity.TeacherType == "In")
{
entity.SchoolId = null;
var staff = await Db.Queryable<Ghra_Staff>().FirstAsync(x => x.StaffID == entity.StaffId);
if (staff != null)
{
entity.TeacherNo = staff.StaffNo;
entity.TeacherName = staff.StaffName;
}
}
else
{
entity.DeptID = null;
entity.StaffId = null;
}
var id = await base.Add(entity);
if (entity.TeacherAttachments != null && entity.TeacherAttachments.Any())
{
for (int i = 0; i < entity.TeacherAttachments.Count; i++)
{
var insert = entity.TeacherAttachments[i];
insert.TeacherId = id;
var teacherAttachmentId = await _ghre_TeacherAttachmentServices.Add(insert);
if (insert.Attachments != null && insert.Attachments.Any())
for (int j = 0; j < insert.Attachments.Count; j++)
{
await Db.Updateable<Ghrs_Attachment>()
.SetColumns(it => new Ghrs_Attachment() { TableName = teacherAttachmentId.ToString(), UpdateTime = DateTime.Now })
.Where(it => it.RelativePath == insert.Attachments[j].RelativePath)
.ExecuteCommandAsync();
}
}
}
return id;
}
public override async Task<bool> Update(long Id, EditGhre_TeacherInput editModel)
{
if (editModel.TeacherType == "In")
{
editModel.SchoolId = null;
var staff = await Db.Queryable<Ghra_Staff>().FirstAsync(x => x.StaffID == editModel.StaffId);
if (staff != null)
{
editModel.TeacherNo = staff.StaffNo;
editModel.TeacherName = staff.StaffName;
}
}
else
{
editModel.DeptID = null;
editModel.StaffId = null;
}
var result = await base.Update(Id, editModel);
await _ghre_TeacherAttachmentServices.Delete(x => x.TeacherId == Id);
if (editModel.TeacherAttachments != null && editModel.TeacherAttachments.Any())
{
for (int i = 0; i < editModel.TeacherAttachments.Count; i++)
{
var insert = editModel.TeacherAttachments[i];
insert.TeacherId = Id;
var TeacherAttachmentId = await _ghre_TeacherAttachmentServices.Add(Mapper.Map(insert).ToANew<InsertGhre_TeacherAttachmentInput>());
if (insert.Attachments != null && insert.Attachments.Any())
for (int j = 0; j < insert.Attachments.Count; j++)
{
await Db.Updateable<Ghrs_Attachment>()
.SetColumns(it => new Ghrs_Attachment() { TableName = TeacherAttachmentId.ToString(), UpdateTime = DateTime.Now })
.Where(it => it.RelativePath == insert.Attachments[j].RelativePath)
.ExecuteCommandAsync();
}
}
}
return result;
}
}

@ -0,0 +1,23 @@

using Tiobon.Core.IServices;
using Tiobon.Core.Model.Models;
using Tiobon.Core.Services.BASE;
using Tiobon.Core.IRepository.Base;
using Tiobon.Core.Common.Caches;
namespace Tiobon.Core.Services
{
/// <summary>
/// Ghro_Dept (服务)
/// </summary>
public class Ghro_DeptServices : BaseServices<Ghro_Dept, Ghro_DeptDto, InsertGhro_DeptInput, EditGhro_DeptInput>, IGhro_DeptServices
{
private readonly IBaseRepository<Ghro_Dept> _dal;
public Ghro_DeptServices(ICaching caching, IBaseRepository<Ghro_Dept> dal)
{
this._dal = dal;
base.BaseDal = dal;
base._caching = caching;
}
}
}

File diff suppressed because it is too large Load Diff

@ -821,6 +821,21 @@
培训机构(Controller) 培训机构(Controller)
</summary> </summary>
</member> </member>
<member name="T:Tiobon.Core.Api.Controllers.Ghre_TeacherAttachmentController">
<summary>
Ghre_TeacherAttachment(Controller)
</summary>
</member>
<member name="T:Tiobon.Core.Api.Controllers.Ghre_TeacherController">
<summary>
Ghre_Teacher(Controller)
</summary>
</member>
<member name="T:Tiobon.Core.Api.Controllers.Ghro_DeptController">
<summary>
Ghro_Dept(Controller)
</summary>
</member>
<member name="T:Tiobon.Core.Api.Controllers.Ghrs_AttachmentController"> <member name="T:Tiobon.Core.Api.Controllers.Ghrs_AttachmentController">
<summary> <summary>
Ghrs_Attachment(Controller) Ghrs_Attachment(Controller)

Loading…
Cancel
Save