Start work for auto close notify
This commit is contained in:
@@ -17,6 +17,9 @@ Server:
|
||||
JobCleanupService:
|
||||
Need to update notification email
|
||||
|
||||
CompanyEmailVerify:
|
||||
Need to update notification email
|
||||
|
||||
Client:
|
||||
jobs/editor:
|
||||
Job Listing Skills exists but isn't implimented in the UI
|
||||
|
||||
@@ -11,6 +11,17 @@ namespace BoredCareers.Services.TimerService {
|
||||
_em = em;
|
||||
}
|
||||
|
||||
public string Substitue(string message, string subString, string Replacement) {
|
||||
for (int i = 0; i < (message.Length - subString.Length); i++) {
|
||||
if (message.Substring(i, subString.Length) == subString) {
|
||||
string before = message.Substring(0, i);
|
||||
string after = message.Substring(i + subString.Length);
|
||||
return before + Replacement + after;
|
||||
}
|
||||
}
|
||||
return message;
|
||||
}
|
||||
|
||||
protected override async Task ExecuteAsync(CancellationToken stoppingToken) {
|
||||
while (!stoppingToken.IsCancellationRequested) {
|
||||
try {
|
||||
@@ -37,7 +48,10 @@ namespace BoredCareers.Services.TimerService {
|
||||
string[] emails = await _db.GetApplicationResponseEmailFromJobListing(listing.JobListingID);
|
||||
foreach (string email in emails) {
|
||||
// Send Notify Email
|
||||
_em.Send(email, EmailService.JobAutoClosedSubject, EmailService.JobAutoClosedEmail);
|
||||
string emailbody = EmailService.JobAutoClosedBody;
|
||||
//Substitue(emailbody, "@job", listing.JobListingID);
|
||||
|
||||
_em.Send(email, EmailService.JobAutoClosedSubject, emailbody);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user