diff --git a/Tiobon.Core.Api/Controllers/Ghra/Ghra_StaffController.cs b/Tiobon.Core.Api/Controllers/Ghra/Ghra_StaffController.cs index 724611f7..7a2b9cf1 100644 --- a/Tiobon.Core.Api/Controllers/Ghra/Ghra_StaffController.cs +++ b/Tiobon.Core.Api/Controllers/Ghra/Ghra_StaffController.cs @@ -26,4 +26,15 @@ public class Ghra_StaffController : BaseController + /// 查询邮箱 + /// + /// + /// + [HttpPost("QueryEmail/{Id}")] + public async Task> QueryEmail(int Id) => await _service.QueryEmail(Id); + #endregion + } \ 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 487cedd7..5ea55656 100644 --- a/Tiobon.Core.Api/Tiobon.Core.Model.xml +++ b/Tiobon.Core.Api/Tiobon.Core.Model.xml @@ -23882,6 +23882,16 @@ 附件 + + + 部门负责人ID + + + + + 部门负责人邮箱 + + 员工ID diff --git a/Tiobon.Core.Api/Tiobon.Core.xml b/Tiobon.Core.Api/Tiobon.Core.xml index 488f4c95..d770247b 100644 --- a/Tiobon.Core.Api/Tiobon.Core.xml +++ b/Tiobon.Core.Api/Tiobon.Core.xml @@ -689,6 +689,13 @@ + + + 查询邮箱 + + + + Ghra_StaffLicence(Controller) diff --git a/Tiobon.Core.IServices/Ghra/IGhra_StaffServices.cs b/Tiobon.Core.IServices/Ghra/IGhra_StaffServices.cs index e475ab19..842e6e3d 100644 --- a/Tiobon.Core.IServices/Ghra/IGhra_StaffServices.cs +++ b/Tiobon.Core.IServices/Ghra/IGhra_StaffServices.cs @@ -7,7 +7,9 @@ namespace Tiobon.Core.IServices; /// /// Ghra_Staff(自定义服务接口) /// - public interface IGhra_StaffServices :IBaseServices +public interface IGhra_StaffServices : IBaseServices { - Task> QuerySimple(int id); - } \ No newline at end of file + Task> QuerySimple(int id); + + Task> QueryEmail(int id); +} \ No newline at end of file diff --git a/Tiobon.Core.Services/Ghra/Ghra_StaffServices.cs b/Tiobon.Core.Services/Ghra/Ghra_StaffServices.cs index eb63b68f..241bfda5 100644 --- a/Tiobon.Core.Services/Ghra/Ghra_StaffServices.cs +++ b/Tiobon.Core.Services/Ghra/Ghra_StaffServices.cs @@ -35,4 +35,15 @@ public class Ghra_StaffServices : BaseServices.OprateSuccess("查询成功!", entity); } + + public async Task> QueryEmail(int id) + { + string email = string.Empty; + var entity = await Db.Ado.SqlQuerySingleAsync($"SELECT * FROM Ghra_Staff WHERE StaffID='{id}' "); + + + if (entity != null) + email = entity.Email; + return ServiceResult.OprateSuccess("查询成功!", email); + } } \ No newline at end of file diff --git a/Tiobon.Core/Tiobon.Core.Model.xml b/Tiobon.Core/Tiobon.Core.Model.xml index 487cedd7..5ea55656 100644 --- a/Tiobon.Core/Tiobon.Core.Model.xml +++ b/Tiobon.Core/Tiobon.Core.Model.xml @@ -23882,6 +23882,16 @@ 附件 + + + 部门负责人ID + + + + + 部门负责人邮箱 + + 员工ID diff --git a/Tiobon.Core/Tiobon.Core.xml b/Tiobon.Core/Tiobon.Core.xml index 488f4c95..d770247b 100644 --- a/Tiobon.Core/Tiobon.Core.xml +++ b/Tiobon.Core/Tiobon.Core.xml @@ -689,6 +689,13 @@ + + + 查询邮箱 + + + + Ghra_StaffLicence(Controller)