From 23d18d2d5c2b502031ea5f5ec4372342330e2d77 Mon Sep 17 00:00:00 2001 From: xiaochanghai Date: Tue, 16 Jul 2024 18:08:15 +0800 Subject: [PATCH] =?UTF-8?q?=E5=9F=B9=E8=AE=AD=E8=AF=81=E4=B9=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Model/Tiobon.Web.pdm | 279 +++++++------- .../Ghre/Ghre_CertificateController.cs | 14 + Tiobon.Core.Api/Tiobon.Core.Model.xml | 350 ++++++++++++++++++ Tiobon.Core.Api/Tiobon.Core.xml | 5 + .../Ghre/IGhre_CertificateServices.cs | 12 + .../Base/Ghre/Ghre_Certificate.Dto.Base.cs | 153 ++++++++ .../Ghre/Ghre_Certificate.Dto.EditInput.cs | 27 ++ .../Ghre/Ghre_Certificate.Dto.InsertInput.cs | 27 ++ .../Models/Ghre/Ghre_Certificate.cs | 155 ++++++++ .../View/Ghre/Ghre_Certificate.Dto.View.cs | 128 +++++++ .../Ghre/Ghre_CertificateServices.cs | 120 ++++++ Tiobon.Core/Tiobon.Core.Model.xml | 350 ++++++++++++++++++ Tiobon.Core/Tiobon.Core.xml | 5 + 13 files changed, 1480 insertions(+), 145 deletions(-) create mode 100644 Tiobon.Core.Api/Controllers/Ghre/Ghre_CertificateController.cs create mode 100644 Tiobon.Core.IServices/Ghre/IGhre_CertificateServices.cs create mode 100644 Tiobon.Core.Model/Base/Ghre/Ghre_Certificate.Dto.Base.cs create mode 100644 Tiobon.Core.Model/Edit/Ghre/Ghre_Certificate.Dto.EditInput.cs create mode 100644 Tiobon.Core.Model/Insert/Ghre/Ghre_Certificate.Dto.InsertInput.cs create mode 100644 Tiobon.Core.Model/Models/Ghre/Ghre_Certificate.cs create mode 100644 Tiobon.Core.Model/View/Ghre/Ghre_Certificate.Dto.View.cs create mode 100644 Tiobon.Core.Services/Ghre/Ghre_CertificateServices.cs diff --git a/Model/Tiobon.Web.pdm b/Model/Tiobon.Web.pdm index 9555591e..cc9adf7c 100644 --- a/Model/Tiobon.Web.pdm +++ b/Model/Tiobon.Web.pdm @@ -1,5 +1,5 @@ - + @@ -119399,7 +119399,7 @@ LABL 0 Arial Unicode MS,8,N Ghre_Certificate 1721036545 Administrator -1721036571 +1721119686 Administrator 培训记录 @@ -119538,108 +119538,97 @@ LABL 0 Arial Unicode MS,8,N -25477CF8-B59B-4347-B907-7106A7BD4CEE +1A7C3A9A-A497-4620-83FD-36E0D6CDBB98 员工ID StaffId -1721036545 +1721119512 Administrator -1721036545 +1721119611 Administrator 员工ID int -23AC2E61-FEC2-4059-8DF6-A37A880B6211 -课程ID -CourseId -1721036545 +D0EF2B27-068E-430B-8400-513C4C97834C +课程快照ID +CourseSnapId +1721119512 Administrator -1721036545 +1721119611 Administrator -课程ID +课程快照ID bigint -4A64BE0F-14D6-4844-93A6-DF566588729C -必修分类 -RequiredClass -1721036545 +856317C8-AEF1-4CBE-9626-519B0311E2FE +课程ID +CourseId +1721119512 Administrator -1721036545 +1721119611 Administrator -必修分类 -nvarchar(32) -32 +课程ID +bigint -1BBD4C94-AAEC-4CC2-B070-60C2389AD948 -课程状态 -CourseStatus -1721036545 +1C3AC4D7-82D8-44A6-AA99-5D8D896BB7AE +证书类型 +CertificateType +1721119512 Administrator -1721036545 +1721119611 Administrator -课程状态 +证书类型 nvarchar(32) 32 -BB2E9160-1C23-4FF7-B4AB-C10FF9BA89A0 -学习状态 -StudyStatus -1721036545 +0B1B5407-A962-4DA7-89B5-6959E8DAD9E9 +证书Url +CertificateUrl +1721119512 Administrator -1721036545 +1721119686 Administrator -学习状态 -nvarchar(32) -32 +证书Url +nvarchar(128) +128 -D561C72C-75BE-4B0B-BA0A-D5BD47B4A468 -必修到期日 -DueDate -1721036545 +319305AD-326A-432B-80C9-721506A79263 +颁发日期 +AwardDate +1721119611 Administrator -1721036545 +1721119686 Administrator -必修到期日 +颁发日期 datetime -E37EB94F-180C-4E9A-B5D0-EC20C69B9164 -考试时间 -ExamDate -1721036545 +4372395C-A313-4F29-AF3F-230EB7ADE95D +有效期 +ValidityPeriod +1721119512 Administrator -1721036545 +1721119881 Administrator -考试时间 -datetime +有效期 +nvarchar(32) +32 -76D13D6A-7210-4E6E-B8D2-AA1D69B93E93 -是否合格 -IsPass -1721036545 +4B5789B7-9B7E-48FE-BA82-D96F444445A1 +有效期1 +ValidityPeriodTime +1721119512 Administrator -1721036545 +1721119881 Administrator -是否合格 -bit +结束时间 +datetime -35947182-0067-40B2-9D13-95097F001C45 -获得学分 -CreditPoints -1721036545 -Administrator -1721036545 -Administrator -获得学分 -int - - A8E011FB-9D06-4737-B071-400C7DBE021F 备注 RemarkSz @@ -119654,7 +119643,7 @@ LABL 0 Arial Unicode MS,8,N - + BB895B8A-6556-4A69-B2A6-3CBB8A10917B 默认标志 IsDefault @@ -119669,7 +119658,7 @@ LABL 0 Arial Unicode MS,8,N - + A32DC3B1-8A4A-4731-9048-7C7D5BEAE18D 删除标志 IsEnable @@ -119684,7 +119673,7 @@ LABL 0 Arial Unicode MS,8,N - + BAA75F53-F765-4653-A54F-6CD3E01741A2 预留字段1 Reverse1 @@ -119696,7 +119685,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + 5924E38A-E889-42F7-BE88-7A548D10E54D 预留字段2 Reverse2 @@ -119708,7 +119697,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + 8D8EBC2B-563A-40D1-9E24-F93E1F8722D1 预留字段3 Reverse3 @@ -119720,7 +119709,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + 8C8A268B-98C5-4E7B-B70A-3BC0011DE0E7 预留字段4 Reverse4 @@ -119732,7 +119721,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + 575E4CBB-3CDC-48BD-A0D3-5A197E966040 预留字段5 Reverse5 @@ -119744,7 +119733,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + 552E182E-6E51-45E7-88E9-A346E3878C1C 预留字段6 Reverse6 @@ -119756,7 +119745,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + EA79E16F-B832-49DA-A29A-7A7E6A3B5253 预留字段7 Reverse7 @@ -119768,7 +119757,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + 334FC158-33DC-452E-B7B2-F5CF611E4106 预留字段8 Reverse8 @@ -119780,7 +119769,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + 8C916540-CBDC-45CE-806D-12548E2AB615 预留字段9 Reverse9 @@ -119792,7 +119781,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + FB62856E-02E4-40F7-AB0A-25FFD2EB1827 预留字段10 Reverse10 @@ -119804,7 +119793,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + F82B1D37-5433-462A-984A-C2B5474EDCEF 预留字段I1 ReverseI1 @@ -119816,7 +119805,7 @@ LABL 0 Arial Unicode MS,8,N 0 int - + 3456F610-CA9D-4AEE-B5C4-F83EB9D628DB 预留字段I2 ReverseI2 @@ -119830,7 +119819,7 @@ LABL 0 Arial Unicode MS,8,N - + 1067DE8F-0741-499F-8684-0A62C0D4DCD7 Key_1 Key_1 @@ -119844,10 +119833,10 @@ LABL 0 Arial Unicode MS,8,N - + - + @@ -119860,7 +119849,7 @@ LABL 0 Arial Unicode MS,8,N Administrator 学分记录 - + 0609050B-2AD7-4E64-830A-D08C0630675B Id Id @@ -119875,7 +119864,7 @@ LABL 0 Arial Unicode MS,8,N - + ED3C4340-4B53-40C3-BA76-624016DF5C66 创建人 CreateBy @@ -119889,7 +119878,7 @@ LABL 0 Arial Unicode MS,8,N - + ECD05F00-C167-49C8-92B8-98833BA9EAEA 创建时间 CreateTime @@ -119903,7 +119892,7 @@ LABL 0 Arial Unicode MS,8,N - + 7168741B-FC64-4BC3-A52B-C425F08853E7 创建程序 CreateProg @@ -119915,7 +119904,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(100) 100 - + B9700C41-2D1D-4C71-8613-149E9D893835 创建人IP CreateIP @@ -119927,7 +119916,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(100) 100 - + 28F2FBE7-170C-4648-8D87-2804A904E1E2 修改人 UpdateBy @@ -119941,7 +119930,7 @@ LABL 0 Arial Unicode MS,8,N - + BD170693-2350-4F86-8D4B-91142F473B46 修改时间 UpdateTime @@ -119955,7 +119944,7 @@ LABL 0 Arial Unicode MS,8,N - + 896FC88C-C6F5-42D7-A194-1F1AE00E66E3 修改程序 UpdateProg @@ -119967,7 +119956,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(100) 100 - + 7093FE14-52BB-4BF4-8079-C8F1A530F791 修改人IP UpdateIP @@ -119979,7 +119968,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(100) 100 - + 412DF897-4FD5-4D39-9663-97DDBED5B2B9 操作日志ID OperateLogID @@ -119994,7 +119983,7 @@ LABL 0 Arial Unicode MS,8,N - + 1C59F865-077C-4F40-9D80-F014A5AA78E3 员工ID StaffId @@ -120005,7 +119994,7 @@ LABL 0 Arial Unicode MS,8,N 员工ID int - + 48FED72C-2120-43C7-B98A-B4845BB6185B 课程ID CourseId @@ -120016,7 +120005,7 @@ LABL 0 Arial Unicode MS,8,N 课程ID bigint - + 8C0E4190-FF55-4FD0-AAA2-282C7753A87F 课程快照ID CourseSnapId @@ -120027,7 +120016,7 @@ LABL 0 Arial Unicode MS,8,N 课程快照ID bigint - + BCB46406-51A1-4483-8518-0287F70CCADD 获得日期 Date @@ -120038,7 +120027,7 @@ LABL 0 Arial Unicode MS,8,N 获得日期 datetime - + 4C409552-962C-41B2-89F9-BEAE81BCD599 获得学分 CreditPoints @@ -120049,7 +120038,7 @@ LABL 0 Arial Unicode MS,8,N 获得学分 int - + AD0571FD-2B1E-4904-A50C-D31B9048E605 备注 RemarkSz @@ -120064,7 +120053,7 @@ LABL 0 Arial Unicode MS,8,N - + F8618A06-F8BE-4F38-AEBA-16354D8E2965 默认标志 IsDefault @@ -120079,7 +120068,7 @@ LABL 0 Arial Unicode MS,8,N - + D8C9B388-E4A8-4238-B1E6-1123562C2E52 删除标志 IsEnable @@ -120094,7 +120083,7 @@ LABL 0 Arial Unicode MS,8,N - + 2AB84A17-6A70-412F-A039-B358EC02F73C 预留字段1 Reverse1 @@ -120106,7 +120095,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + 5E174EBD-8179-423A-8635-135CFE32DBD8 预留字段2 Reverse2 @@ -120118,7 +120107,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + BDFC6CC3-1961-4DD9-8831-0100F96012FA 预留字段3 Reverse3 @@ -120130,7 +120119,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + 82A2EE6F-0ABB-443B-B19A-DF698D3059E6 预留字段4 Reverse4 @@ -120142,7 +120131,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + 3F262ED5-0B60-4E84-A082-30B8C0D11804 预留字段5 Reverse5 @@ -120154,7 +120143,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + 4C19F768-BC38-4DB1-95FE-A91FADC33E94 预留字段6 Reverse6 @@ -120166,7 +120155,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + C38AE6E3-5E73-4D38-8B0E-458AF13318A4 预留字段7 Reverse7 @@ -120178,7 +120167,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + 6E4597F1-CC80-46A1-8C33-BFA961059D50 预留字段8 Reverse8 @@ -120190,7 +120179,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + 03DBDADB-1656-42E3-99D9-18F072A408F0 预留字段9 Reverse9 @@ -120202,7 +120191,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + D52A9DD3-2CD7-4D4F-962F-83E1B8B50FF6 预留字段10 Reverse10 @@ -120214,7 +120203,7 @@ LABL 0 Arial Unicode MS,8,N nvarchar(1000) 1000 - + 35F0B2FC-591B-41A9-9FC8-A91CF502A61D 预留字段I1 ReverseI1 @@ -120226,7 +120215,7 @@ LABL 0 Arial Unicode MS,8,N 0 int - + D86F4790-2DAD-4A1A-8E8C-BA516A21B9A1 预留字段I2 ReverseI2 @@ -120240,7 +120229,7 @@ LABL 0 Arial Unicode MS,8,N - + 3BE0949D-16CB-473A-A62D-3A3DC1CC8E07 Key_1 Key_1 @@ -120249,15 +120238,15 @@ LABL 0 Arial Unicode MS,8,N 1721036579 Administrator - + - + - + @@ -120281,7 +120270,7 @@ LABL 0 Arial Unicode MS,8,N - + 7F0DCA7C-274D-48A8-B3D8-0FD7B707AFC2 1714101292 Administrator @@ -120315,7 +120304,7 @@ LABL 0 Arial Unicode MS,8,N - + D23C452C-4BB6-4C2A-AB2E-E8434D958A77 1714101335 Administrator @@ -120349,7 +120338,7 @@ LABL 0 Arial Unicode MS,8,N - + D4016F9D-5631-4F9E-A70D-D42133A4EBB7 1714107872 Administrator @@ -120383,7 +120372,7 @@ LABL 0 Arial Unicode MS,8,N - + BEBA3346-CCC6-41D9-B95B-12B8F81188BF 1714108449 Administrator @@ -120417,7 +120406,7 @@ LABL 0 Arial Unicode MS,8,N - + FC69BEF9-F863-4A65-903E-CB2850197526 1714109221 Administrator @@ -120451,7 +120440,7 @@ LABL 0 Arial Unicode MS,8,N - + ACE0AB02-0D27-4F1C-BF71-738C20DF96C2 1714120556 Administrator @@ -120485,7 +120474,7 @@ LABL 0 Arial Unicode MS,8,N - + B95672ED-9976-4742-9FFC-52B326620682 1715565535 Administrator @@ -120519,7 +120508,7 @@ LABL 0 Arial Unicode MS,8,N - + B6E89235-A6E0-460D-9228-DCA8C58EE2AD 1715570661 Administrator @@ -120553,7 +120542,7 @@ LABL 0 Arial Unicode MS,8,N - + 5D4938F3-7934-4F74-891C-97DC9DC47B1B 1716798640 Administrator @@ -120587,7 +120576,7 @@ LABL 0 Arial Unicode MS,8,N - + 179079CB-7169-4B19-A07A-A61C331F59CD 1716876897 Administrator @@ -120621,7 +120610,7 @@ LABL 0 Arial Unicode MS,8,N - + DD965546-2361-4301-82D7-446B823BDCFD 1717481682 Administrator @@ -120655,7 +120644,7 @@ LABL 0 Arial Unicode MS,8,N - + E78B14FB-C2C3-4DCA-A3B4-CA471817B9FC 1717726229 Administrator @@ -120689,7 +120678,7 @@ LABL 0 Arial Unicode MS,8,N - + 8C71D6B9-780B-4547-ADFD-986E619F4DCD 1719381914 Administrator @@ -120723,7 +120712,7 @@ LABL 0 Arial Unicode MS,8,N - + EB9D1A5A-99AB-44AD-9B1A-D45E66C0CFDE 1719468257 Administrator @@ -120757,7 +120746,7 @@ LABL 0 Arial Unicode MS,8,N - + ACF1454B-2C3F-40E5-ADC5-4A48787EB937 1720488320 Administrator @@ -120779,7 +120768,7 @@ LABL 0 Arial Unicode MS,8,N - + A1DD77B6-E48E-4C9D-947D-D42E3C5240C2 dbo dbo @@ -120792,7 +120781,7 @@ LABL 0 Arial Unicode MS,8,N - + C012A467-0031-4F3C-9D9D-13408491E147 DefaultSchema 1597196432 @@ -120800,12 +120789,12 @@ LABL 0 Arial Unicode MS,8,N 1597196433 ttsoftxch - + - + 41D2B655-5319-49C5-9BA6-133BB8B097CA dbo dbo @@ -120817,7 +120806,7 @@ LABL 0 Arial Unicode MS,8,N - + 2153E033-C4DC-4F90-B2F4-3B0F44BD33D5 文本 TEXT @@ -120827,7 +120816,7 @@ LABL 0 Arial Unicode MS,8,N ttsoftxch text - + AC8799D0-82CA-4B70-ADAC-18D8797720A9 图片 IMAGE @@ -120837,7 +120826,7 @@ LABL 0 Arial Unicode MS,8,N Administrator image - + DEC04470-B84A-413E-9B2A-C265C5506182 加密 ENCRYPT_STRING @@ -120905,7 +120894,7 @@ LABL 0 Arial Unicode MS,8,N varchar(4000) 4000 - + 703A2917-B6C4-4BC6-B2CB-6AB8E2B49D30 短字符串 SHORT_STRING @@ -120916,7 +120905,7 @@ LABL 0 Arial Unicode MS,8,N varchar(64) 64 - + 89A476D2-A1C0-428C-9875-26A50B7AFE1A 长字符串 LONG_STRING @@ -120938,7 +120927,7 @@ LABL 0 Arial Unicode MS,8,N varchar(2000) 2000 - + @@ -121016,7 +121005,7 @@ LABL 0 Arial Unicode MS,8,N varchar(32) 32 - + CB2F08D6-BE17-4046-B94A-4FD00EDA9015 文件 FILE @@ -121039,7 +121028,7 @@ LABL 0 Arial Unicode MS,8,N - + B41C21E8-76E9-4031-8EF0-34743E5525C5 PUBLIC PUBLIC @@ -121048,13 +121037,13 @@ LABL 0 Arial Unicode MS,8,N 1597196433 ttsoftxch - - + + - + 02EF92C9-49BF-45C7-934A-23BA290D5595 Microsoft SQL Server 2008 MSSQLSRV2008 diff --git a/Tiobon.Core.Api/Controllers/Ghre/Ghre_CertificateController.cs b/Tiobon.Core.Api/Controllers/Ghre/Ghre_CertificateController.cs new file mode 100644 index 00000000..feab0844 --- /dev/null +++ b/Tiobon.Core.Api/Controllers/Ghre/Ghre_CertificateController.cs @@ -0,0 +1,14 @@ +namespace Tiobon.Core.Api.Controllers; + +/// +/// 培训记录(Controller) +/// +[Route("api/[controller]")] +[ApiController, GlobalActionFilter] +[Authorize(Permissions.Name), ApiExplorerSettings(GroupName = Grouping.GroupName_Ghre)] +public class Ghre_CertificateController : BaseController +{ + public Ghre_CertificateController(IGhre_CertificateServices service) : base(service) + { + } +} \ No newline at end of file diff --git a/Tiobon.Core.Api/Tiobon.Core.Model.xml b/Tiobon.Core.Api/Tiobon.Core.Model.xml index 6718935c..0747f147 100644 --- a/Tiobon.Core.Api/Tiobon.Core.Model.xml +++ b/Tiobon.Core.Api/Tiobon.Core.Model.xml @@ -1025,6 +1025,121 @@ 预留字段12 + + + 培训记录 (Dto.Base) + + + + + 员工ID + + + + + 课程快照ID + + + + + 课程ID + + + + + 证书类型 + + + + + 证书Url + + + + + 颁发日期 + + + + + 有效期 + + + + + 结束时间 + + + + + 备注 + + + + + 默认标志 + + + + + 预留字段1 + + + + + 预留字段2 + + + + + 预留字段3 + + + + + 预留字段4 + + + + + 预留字段5 + + + + + 预留字段6 + + + + + 预留字段7 + + + + + 预留字段8 + + + + + 预留字段9 + + + + + 预留字段10 + + + + + 预留字段11 + + + + + 预留字段12 + + 课程 (Dto.Base) @@ -4337,6 +4452,11 @@ 附件 (Dto.EditInput) + + + 培训记录 (Dto.EditInput) + + 课程 (Dto.EditInput) @@ -4497,6 +4617,11 @@ 附件 (Dto.InsertInput) + + + 培训记录 (Dto.InsertInput) + + 课程 (Dto.InsertInput) @@ -5831,6 +5956,121 @@ 预留字段12 + + + 培训记录 (Model) + + + + + 员工ID + + + + + 课程快照ID + + + + + 课程ID + + + + + 证书类型 + + + + + 证书Url + + + + + 颁发日期 + + + + + 有效期 + + + + + 结束时间 + + + + + 备注 + + + + + 默认标志 + + + + + 预留字段1 + + + + + 预留字段2 + + + + + 预留字段3 + + + + + 预留字段4 + + + + + 预留字段5 + + + + + 预留字段6 + + + + + 预留字段7 + + + + + 预留字段8 + + + + + 预留字段9 + + + + + 预留字段10 + + + + + 预留字段11 + + + + + 预留字段12 + + 课程 (Model) @@ -9987,6 +10227,116 @@ 修改信息 + + + 培训记录(Dto.View) + + + + + 创建信息 + + + + + 修改信息 + + + + + 工号 + + + + + 员工姓名 + + + + + 部门编号 + + + + + 部门名称 + + + + + 岗位 + + + + + 入职日期 + + + + + 在职状态 + + + + + 课程分类 + + + + + 课程编号 + + + + + 课程名称 + + + + + 标准课时 + + + + + 考试日期 + + + + + 课程场景 + + + + + 考试分数 + + + + + 调整分 + + + + + 最终得分 + + + + + 是否合格 + + + + + 获得学分 + + + + + 来源 + + 课程(Dto.View) diff --git a/Tiobon.Core.Api/Tiobon.Core.xml b/Tiobon.Core.Api/Tiobon.Core.xml index 6d36d234..ea5a7266 100644 --- a/Tiobon.Core.Api/Tiobon.Core.xml +++ b/Tiobon.Core.Api/Tiobon.Core.xml @@ -582,6 +582,11 @@ 附件(Controller) + + + 培训记录(Controller) + + Ghre_CourseClass(Controller) diff --git a/Tiobon.Core.IServices/Ghre/IGhre_CertificateServices.cs b/Tiobon.Core.IServices/Ghre/IGhre_CertificateServices.cs new file mode 100644 index 00000000..e4f28d4b --- /dev/null +++ b/Tiobon.Core.IServices/Ghre/IGhre_CertificateServices.cs @@ -0,0 +1,12 @@ +using Tiobon.Core.IServices.BASE; +using Tiobon.Core.Model.Models; + +namespace Tiobon.Core.IServices +{ + /// + /// 培训记录(自定义服务接口) + /// + public interface IGhre_CertificateServices :IBaseServices + { + } +} \ No newline at end of file diff --git a/Tiobon.Core.Model/Base/Ghre/Ghre_Certificate.Dto.Base.cs b/Tiobon.Core.Model/Base/Ghre/Ghre_Certificate.Dto.Base.cs new file mode 100644 index 00000000..529d7cb5 --- /dev/null +++ b/Tiobon.Core.Model/Base/Ghre/Ghre_Certificate.Dto.Base.cs @@ -0,0 +1,153 @@ +/* 代码由框架生成,任何更改都可能导致被代码生成器覆盖,可自行修改。 +* Ghre_Certificate.cs +* +*功 能: N / A +* 类 名: Ghre_Certificate +* +* Ver 变更日期 负责人 变更内容 +* ─────────────────────────────────── +*V0.01 2024/7/16 16:52:58 SimonHsiao 初版 +* +* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved. +*┌──────────────────────────────────┐ +*│ 此技术信息为本公司机密信息,未经本公司书面同意禁止向第三方披露. │ +*│ 作者:SimonHsiao │ +*└──────────────────────────────────┘ +*/ +using System.ComponentModel; +using System.ComponentModel.DataAnnotations; + +namespace Tiobon.Core.Model.Models +{ + + /// + /// 培训记录 (Dto.Base) + /// + public class Ghre_CertificateBase + { + + /// + /// 员工ID + /// + public int? StaffId { get; set; } + + /// + /// 课程快照ID + /// + public long? CourseSnapId { get; set; } + + /// + /// 课程ID + /// + public long? CourseId { get; set; } + + /// + /// 证书类型 + /// + [Display(Name = "CertificateType"), Description("证书类型"), MaxLength(32, ErrorMessage = "证书类型 不能超过 32 个字符")] + public string CertificateType { get; set; } + + /// + /// 证书Url + /// + [Display(Name = "CertificateUrl"), Description("证书Url"), MaxLength(128, ErrorMessage = "证书Url 不能超过 128 个字符")] + public string CertificateUrl { get; set; } + + /// + /// 颁发日期 + /// + public DateTime? AwardDate { get; set; } + + /// + /// 有效期 + /// + [Display(Name = "ValidityPeriod"), Description("有效期"), MaxLength(32, ErrorMessage = "有效期 不能超过 32 个字符")] + public string ValidityPeriod { get; set; } + + /// + /// 结束时间 + /// + public DateTime? ValidityPeriodTime { get; set; } + + /// + /// 备注 + /// + [Display(Name = "RemarkSz"), Description("备注"), MaxLength(2000, ErrorMessage = "备注 不能超过 2000 个字符")] + public string RemarkSz { get; set; } + + /// + /// 默认标志 + /// + public int? IsDefault { get; set; } + + /// + /// 预留字段1 + /// + [Display(Name = "Reverse1"), Description("预留字段1"), MaxLength(1000, ErrorMessage = "预留字段1 不能超过 1000 个字符")] + public string Reverse1 { get; set; } + + /// + /// 预留字段2 + /// + [Display(Name = "Reverse2"), Description("预留字段2"), MaxLength(1000, ErrorMessage = "预留字段2 不能超过 1000 个字符")] + public string Reverse2 { get; set; } + + /// + /// 预留字段3 + /// + [Display(Name = "Reverse3"), Description("预留字段3"), MaxLength(1000, ErrorMessage = "预留字段3 不能超过 1000 个字符")] + public string Reverse3 { get; set; } + + /// + /// 预留字段4 + /// + [Display(Name = "Reverse4"), Description("预留字段4"), MaxLength(1000, ErrorMessage = "预留字段4 不能超过 1000 个字符")] + public string Reverse4 { get; set; } + + /// + /// 预留字段5 + /// + [Display(Name = "Reverse5"), Description("预留字段5"), MaxLength(1000, ErrorMessage = "预留字段5 不能超过 1000 个字符")] + public string Reverse5 { get; set; } + + /// + /// 预留字段6 + /// + [Display(Name = "Reverse6"), Description("预留字段6"), MaxLength(1000, ErrorMessage = "预留字段6 不能超过 1000 个字符")] + public string Reverse6 { get; set; } + + /// + /// 预留字段7 + /// + [Display(Name = "Reverse7"), Description("预留字段7"), MaxLength(1000, ErrorMessage = "预留字段7 不能超过 1000 个字符")] + public string Reverse7 { get; set; } + + /// + /// 预留字段8 + /// + [Display(Name = "Reverse8"), Description("预留字段8"), MaxLength(1000, ErrorMessage = "预留字段8 不能超过 1000 个字符")] + public string Reverse8 { get; set; } + + /// + /// 预留字段9 + /// + [Display(Name = "Reverse9"), Description("预留字段9"), MaxLength(1000, ErrorMessage = "预留字段9 不能超过 1000 个字符")] + public string Reverse9 { get; set; } + + /// + /// 预留字段10 + /// + [Display(Name = "Reverse10"), Description("预留字段10"), MaxLength(1000, ErrorMessage = "预留字段10 不能超过 1000 个字符")] + public string Reverse10 { get; set; } + + /// + /// 预留字段11 + /// + public int? ReverseI1 { get; set; } + + /// + /// 预留字段12 + /// + public int? ReverseI2 { get; set; } + } +} diff --git a/Tiobon.Core.Model/Edit/Ghre/Ghre_Certificate.Dto.EditInput.cs b/Tiobon.Core.Model/Edit/Ghre/Ghre_Certificate.Dto.EditInput.cs new file mode 100644 index 00000000..ec7252d0 --- /dev/null +++ b/Tiobon.Core.Model/Edit/Ghre/Ghre_Certificate.Dto.EditInput.cs @@ -0,0 +1,27 @@ +/* 代码由框架生成,任何更改都可能导致被代码生成器覆盖,可自行修改。 +* Ghre_Certificate.cs +* +*功 能: N / A +* 类 名: Ghre_Certificate +* +* Ver 变更日期 负责人 变更内容 +* ─────────────────────────────────── +*V0.01 2024/7/16 16:52:58 SimonHsiao 初版 +* +* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved. +*┌──────────────────────────────────┐ +*│ 此技术信息为本公司机密信息,未经本公司书面同意禁止向第三方披露. │ +*│ 作者:SimonHsiao │ +*└──────────────────────────────────┘ +*/ + +namespace Tiobon.Core.Model.Models +{ + + /// + /// 培训记录 (Dto.EditInput) + /// + public class EditGhre_CertificateInput : Ghre_CertificateBase + { + } +} diff --git a/Tiobon.Core.Model/Insert/Ghre/Ghre_Certificate.Dto.InsertInput.cs b/Tiobon.Core.Model/Insert/Ghre/Ghre_Certificate.Dto.InsertInput.cs new file mode 100644 index 00000000..957d479d --- /dev/null +++ b/Tiobon.Core.Model/Insert/Ghre/Ghre_Certificate.Dto.InsertInput.cs @@ -0,0 +1,27 @@ +/* 代码由框架生成,任何更改都可能导致被代码生成器覆盖,可自行修改。 +* Ghre_Certificate.cs +* +*功 能: N / A +* 类 名: Ghre_Certificate +* +* Ver 变更日期 负责人 变更内容 +* ─────────────────────────────────── +*V0.01 2024/7/16 16:52:58 SimonHsiao 初版 +* +* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved. +*┌──────────────────────────────────┐ +*│ 此技术信息为本公司机密信息,未经本公司书面同意禁止向第三方披露. │ +*│ 作者:SimonHsiao │ +*└──────────────────────────────────┘ +*/ + +namespace Tiobon.Core.Model.Models +{ + + /// + /// 培训记录 (Dto.InsertInput) + /// + public class InsertGhre_CertificateInput : Ghre_CertificateBase + { + } +} diff --git a/Tiobon.Core.Model/Models/Ghre/Ghre_Certificate.cs b/Tiobon.Core.Model/Models/Ghre/Ghre_Certificate.cs new file mode 100644 index 00000000..c3863c41 --- /dev/null +++ b/Tiobon.Core.Model/Models/Ghre/Ghre_Certificate.cs @@ -0,0 +1,155 @@ +/* 代码由框架生成,任何更改都可能导致被代码生成器覆盖,可自行修改。 +* Ghre_Certificate.cs +* +*功 能: N / A +* 类 名: Ghre_Certificate +* +* Ver 变更日期 负责人 变更内容 +* ─────────────────────────────────── +*V0.01 2024/7/16 16:52:58 SimonHsiao 初版 +* +* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved. +*┌──────────────────────────────────┐ +*│ 此技术信息为本公司机密信息,未经本公司书面同意禁止向第三方披露. │ +*│ 作者:SimonHsiao │ +*└──────────────────────────────────┘ +*/ +using System.ComponentModel; +using System.ComponentModel.DataAnnotations; +using SqlSugar; + +namespace Tiobon.Core.Model.Models +{ + + /// + /// 培训记录 (Model) + /// + [SugarTable("Ghre_Certificate", "Ghre_Certificate"), Entity(TableCnName = "培训记录", TableName = "Ghre_Certificate")] + public class Ghre_Certificate : BasePoco + { + + /// + /// 员工ID + /// + public int? StaffId { get; set; } + + /// + /// 课程快照ID + /// + public long? CourseSnapId { get; set; } + + /// + /// 课程ID + /// + public long? CourseId { get; set; } + + /// + /// 证书类型 + /// + [Display(Name = "CertificateType"), Description("证书类型"), MaxLength(32, ErrorMessage = "证书类型 不能超过 32 个字符")] + public string CertificateType { get; set; } + + /// + /// 证书Url + /// + [Display(Name = "CertificateUrl"), Description("证书Url"), MaxLength(128, ErrorMessage = "证书Url 不能超过 128 个字符")] + public string CertificateUrl { get; set; } + + /// + /// 颁发日期 + /// + public DateTime? AwardDate { get; set; } + + /// + /// 有效期 + /// + [Display(Name = "ValidityPeriod"), Description("有效期"), MaxLength(32, ErrorMessage = "有效期 不能超过 32 个字符")] + public string ValidityPeriod { get; set; } + + /// + /// 结束时间 + /// + public DateTime? ValidityPeriodTime { get; set; } + + /// + /// 备注 + /// + [Display(Name = "RemarkSz"), Description("备注"), MaxLength(2000, ErrorMessage = "备注 不能超过 2000 个字符")] + public string RemarkSz { get; set; } + + /// + /// 默认标志 + /// + public int? IsDefault { get; set; } + + /// + /// 预留字段1 + /// + [Display(Name = "Reverse1"), Description("预留字段1"), MaxLength(1000, ErrorMessage = "预留字段1 不能超过 1000 个字符")] + public string Reverse1 { get; set; } + + /// + /// 预留字段2 + /// + [Display(Name = "Reverse2"), Description("预留字段2"), MaxLength(1000, ErrorMessage = "预留字段2 不能超过 1000 个字符")] + public string Reverse2 { get; set; } + + /// + /// 预留字段3 + /// + [Display(Name = "Reverse3"), Description("预留字段3"), MaxLength(1000, ErrorMessage = "预留字段3 不能超过 1000 个字符")] + public string Reverse3 { get; set; } + + /// + /// 预留字段4 + /// + [Display(Name = "Reverse4"), Description("预留字段4"), MaxLength(1000, ErrorMessage = "预留字段4 不能超过 1000 个字符")] + public string Reverse4 { get; set; } + + /// + /// 预留字段5 + /// + [Display(Name = "Reverse5"), Description("预留字段5"), MaxLength(1000, ErrorMessage = "预留字段5 不能超过 1000 个字符")] + public string Reverse5 { get; set; } + + /// + /// 预留字段6 + /// + [Display(Name = "Reverse6"), Description("预留字段6"), MaxLength(1000, ErrorMessage = "预留字段6 不能超过 1000 个字符")] + public string Reverse6 { get; set; } + + /// + /// 预留字段7 + /// + [Display(Name = "Reverse7"), Description("预留字段7"), MaxLength(1000, ErrorMessage = "预留字段7 不能超过 1000 个字符")] + public string Reverse7 { get; set; } + + /// + /// 预留字段8 + /// + [Display(Name = "Reverse8"), Description("预留字段8"), MaxLength(1000, ErrorMessage = "预留字段8 不能超过 1000 个字符")] + public string Reverse8 { get; set; } + + /// + /// 预留字段9 + /// + [Display(Name = "Reverse9"), Description("预留字段9"), MaxLength(1000, ErrorMessage = "预留字段9 不能超过 1000 个字符")] + public string Reverse9 { get; set; } + + /// + /// 预留字段10 + /// + [Display(Name = "Reverse10"), Description("预留字段10"), MaxLength(1000, ErrorMessage = "预留字段10 不能超过 1000 个字符")] + public string Reverse10 { get; set; } + + /// + /// 预留字段11 + /// + public int? ReverseI1 { get; set; } + + /// + /// 预留字段12 + /// + public int? ReverseI2 { get; set; } + } +} diff --git a/Tiobon.Core.Model/View/Ghre/Ghre_Certificate.Dto.View.cs b/Tiobon.Core.Model/View/Ghre/Ghre_Certificate.Dto.View.cs new file mode 100644 index 00000000..11bd436d --- /dev/null +++ b/Tiobon.Core.Model/View/Ghre/Ghre_Certificate.Dto.View.cs @@ -0,0 +1,128 @@ +/* 代码由框架生成,任何更改都可能导致被代码生成器覆盖,可自行修改。 +* Ghre_Certificate.cs +* +*功 能: N / A +* 类 名: Ghre_Certificate +* +* Ver 变更日期 负责人 变更内容 +* ─────────────────────────────────── +*V0.01 2024/7/16 16:52:58 SimonHsiao 初版 +* +* Copyright(c) 2024 Tiobon Corporation. All Rights Reserved. +*┌──────────────────────────────────┐ +*│ 此技术信息为本公司机密信息,未经本公司书面同意禁止向第三方披露. │ +*│ 作者:SimonHsiao │ +*└──────────────────────────────────┘ +*/ + +namespace Tiobon.Core.Model.Models; + +/// +/// 培训记录(Dto.View) +/// +public class Ghre_CertificateDto : Ghre_Certificate +{ + /// + /// 创建信息 + /// + public string CreateDataInfo { get; set; } + + /// + /// 修改信息 + /// + public string UpdateDataInfo { get; set; } + + /// + /// 工号 + /// + public string StaffNo { get; set; } + + /// + /// 员工姓名 + /// + + public string StaffName { get; set; } + + /// + /// 部门编号 + /// + + public string DeptNo { get; set; } + + /// + /// 部门名称 + /// + + public string DepteName { get; set; } + + /// + /// 岗位 + /// + + public string TitleName { get; set; } + + /// + /// 入职日期 + /// + + public string Indate { get; set; } + + /// + /// 在职状态 + /// + + public string InStatusLabel { get; set; } + /// + /// 课程分类 + /// + public string CourseClass { get; set; } + /// + /// 课程编号 + /// + public string CourseNo { get; set; } + /// + /// 课程名称 + /// + public string CourseName { get; set; } + /// + /// 标准课时 + /// + public string StandardHour { get; set; } + /// + /// 考试日期 + /// + public string ExamDate { get; set; } + /// + /// 课程场景 + /// + + public string CourseScene { get; set; } + /// + /// 考试分数 + /// + public decimal? Score { get; set; } + /// + /// 调整分 + /// + public decimal? AdjustScore { get; set; } + /// + /// 最终得分 + /// + public decimal? TotalScore { get; set; } + /// + /// 是否合格 + /// + public string IsPassLabel { get; set; } + + + /// + /// 获得学分 + /// + + public string CreditPoints { get; set; } + /// + /// 来源 + /// + public string CertificateTypeLabel { get; set; } + public string IsExpiredLabel { get; set; } +} \ No newline at end of file diff --git a/Tiobon.Core.Services/Ghre/Ghre_CertificateServices.cs b/Tiobon.Core.Services/Ghre/Ghre_CertificateServices.cs new file mode 100644 index 00000000..81ce2442 --- /dev/null +++ b/Tiobon.Core.Services/Ghre/Ghre_CertificateServices.cs @@ -0,0 +1,120 @@ + +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 Newtonsoft.Json.Linq; +using Tiobon.Core.Common; +using Tiobon.Core.Model; +using Newtonsoft.Json; + +namespace Tiobon.Core.Services; + + /// + /// 培训记录 (服务) + /// +public class Ghre_CertificateServices : BaseServices, IGhre_CertificateServices +{ + private readonly IBaseRepository _dal; + public Ghre_CertificateServices(ICaching caching, IBaseRepository dal) + { + this._dal = dal; + base.BaseDal = dal; + base._caching = caching; + } + + public override async Task> 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 Ghre_Certificate_V"; + var sql = @$" SELECT * + FROM Ghre_Certificate_V 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 (name == "Date") + { + var jsonParam = JsonConvert.DeserializeObject(value); + conditions += $" AND (Date BETWEEN '{jsonParam.columnValue[0]}' AND '{jsonParam.columnValue[1]}')"; + + continue; + } + if (!string.IsNullOrWhiteSpace(value)) + { + var jsonParam = JsonConvert.DeserializeObject(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; + + var entitys = await Db.Ado.SqlQueryAsync(sql); + + return new ServicePageResult(filter.pageNum, total, filter.pageSize, entitys); + + } +} \ No newline at end of file diff --git a/Tiobon.Core/Tiobon.Core.Model.xml b/Tiobon.Core/Tiobon.Core.Model.xml index 6718935c..31254a9e 100644 --- a/Tiobon.Core/Tiobon.Core.Model.xml +++ b/Tiobon.Core/Tiobon.Core.Model.xml @@ -1025,6 +1025,121 @@ 预留字段12 + + + 培训记录 (Dto.Base) + + + + + 员工ID + + + + + 课程快照ID + + + + + 课程ID + + + + + 证书类型 + + + + + 证书Url + + + + + 颁发日期 + + + + + 有效期 + + + + + 结束时间 + + + + + 备注 + + + + + 默认标志 + + + + + 预留字段1 + + + + + 预留字段2 + + + + + 预留字段3 + + + + + 预留字段4 + + + + + 预留字段5 + + + + + 预留字段6 + + + + + 预留字段7 + + + + + 预留字段8 + + + + + 预留字段9 + + + + + 预留字段10 + + + + + 预留字段11 + + + + + 预留字段12 + + 课程 (Dto.Base) @@ -4337,6 +4452,11 @@ 附件 (Dto.EditInput) + + + 培训记录 (Dto.EditInput) + + 课程 (Dto.EditInput) @@ -4497,6 +4617,11 @@ 附件 (Dto.InsertInput) + + + 培训记录 (Dto.InsertInput) + + 课程 (Dto.InsertInput) @@ -5831,6 +5956,121 @@ 预留字段12 + + + 培训记录 (Model) + + + + + 员工ID + + + + + 课程快照ID + + + + + 课程ID + + + + + 证书类型 + + + + + 证书Url + + + + + 颁发日期 + + + + + 有效期 + + + + + 结束时间 + + + + + 备注 + + + + + 默认标志 + + + + + 预留字段1 + + + + + 预留字段2 + + + + + 预留字段3 + + + + + 预留字段4 + + + + + 预留字段5 + + + + + 预留字段6 + + + + + 预留字段7 + + + + + 预留字段8 + + + + + 预留字段9 + + + + + 预留字段10 + + + + + 预留字段11 + + + + + 预留字段12 + + 课程 (Model) @@ -9987,6 +10227,116 @@ 修改信息 + + + 培训记录(Dto.View) + + + + + 创建信息 + + + + + 修改信息 + + + + + 工号 + + + + + 员工姓名 + + + + + 部门编号 + + + + + 部门名称 + + + + + 岗位 + + + + + 入职日期 + + + + + 在职状态 + + + + + 课程分类 + + + + + 课程编号 + + + + + 课程名称 + + + + + 标准课时 + + + + + 考试日期 + + + + + 课程场景 + + + + + 考试分数 + + + + + 调整分 + + + + + 最终得分 + + + + + 是否合格 + + + + + 获得学分 + + + + + 来源 + + 课程(Dto.View) diff --git a/Tiobon.Core/Tiobon.Core.xml b/Tiobon.Core/Tiobon.Core.xml index 6d36d234..ea5a7266 100644 --- a/Tiobon.Core/Tiobon.Core.xml +++ b/Tiobon.Core/Tiobon.Core.xml @@ -582,6 +582,11 @@ 附件(Controller) + + + 培训记录(Controller) + + Ghre_CourseClass(Controller)