send email
This commit is contained in:
parent
e7753c280d
commit
519ef2f143
2 changed files with 23 additions and 0 deletions
|
|
@ -192,6 +192,17 @@ namespace BMA.EHR.Placement.Service.Controllers
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[HttpPost("send-mail")]
|
||||||
|
public async Task<ActionResult<ResponseObject>> sendEmailOnly([FromBody] NotiEmailRequest req)
|
||||||
|
{
|
||||||
|
await _repositoryNoti.PushEmailAsync(
|
||||||
|
req.Subject,
|
||||||
|
req.Body,
|
||||||
|
req.Email
|
||||||
|
);
|
||||||
|
return Success();
|
||||||
|
}
|
||||||
|
|
||||||
[HttpPost("cronjob")]
|
[HttpPost("cronjob")]
|
||||||
public async Task<ActionResult<ResponseObject>> CornjobProbation([FromBody] NotiCronjobProbationRequest req)
|
public async Task<ActionResult<ResponseObject>> CornjobProbation([FromBody] NotiCronjobProbationRequest req)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
12
BMA.EHR.Placement.Service/Requests/NotiEmailRequest.cs
Normal file
12
BMA.EHR.Placement.Service/Requests/NotiEmailRequest.cs
Normal file
|
|
@ -0,0 +1,12 @@
|
||||||
|
using BMA.EHR.Domain.Models.MetaData;
|
||||||
|
using Microsoft.EntityFrameworkCore;
|
||||||
|
|
||||||
|
namespace BMA.EHR.Placement.Service.Requests
|
||||||
|
{
|
||||||
|
public class NotiEmailRequest
|
||||||
|
{
|
||||||
|
public string Subject { get; set; }
|
||||||
|
public string Body { get; set; }
|
||||||
|
public string Email { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue