Commit 5a46ecbd authored by Frank Bergmann's avatar Frank Bergmann

-- minor improvements logging

   send notification to PM
parent 87775a10
......@@ -147,16 +147,17 @@ ad_proc -private im_project_reminders_send_notification_to_object_members {
# Based on type we evaluate the mail recipient
db_1row select_foo "
select
task_type_id,
task_name as object_name,
trans_id,
edit_id,
proof_id,
other_id
tt.task_type_id,
(select project_lead_id from im_projects where project_id = tt.project_id) as trans_project_lead_id,
tt.task_name as object_name,
tt.trans_id,
tt.edit_id,
tt.proof_id,
tt.other_id
from
im_trans_tasks
im_trans_tasks tt
where
task_id = :object_id
tt.task_id = :object_id
"
# Get final responsible in workflow
......@@ -165,6 +166,9 @@ ad_proc -private im_project_reminders_send_notification_to_object_members {
if { "" ne $proof_id } { lappend parties_to_be_notified_id $proof_id }
if { "" ne $other_id } { lappend parties_to_be_notified_id $other_id }
# Send additional email to Project Manager
lappend parties_to_be_notified_id $trans_project_lead_id
if { "" eq $parties_to_be_notified_id } {
ns_log Notice "im_project_reminders_send_notification_to_object_members: Exit - No assignments found for translation_task_id: $object_id ($parties_to_be_notified_id)"
return
......@@ -198,8 +202,8 @@ ad_proc -private im_project_reminders_send_notification_to_object_members {
}
}
set mail_subject [lang::message::lookup "" intranet-project-reminders.Mail_Subject_Text "Friendly Reminder - Task is due "]
set mail_body [lang::message::lookup "" intranet-project-reminders.Mail_Body_Text_Html "Planned end date of task: <br/> $object_name <br/> will be reached shortly.<br/>Please review."]
set mail_subject [lang::message::lookup "" intranet-project-reminders.Mail_Subject_Text "Friendly Reminder - Task is due soon "]
set mail_body [lang::message::lookup "" intranet-project-reminders.Mail_Body_Text_Html "Planned end date of task: <br/> $object_name <br/> will be reached shortly and task has not been marked as DONE yet.<br/>Please review."]
if { $log_p } {
if {[catch {
......@@ -211,7 +215,7 @@ ad_proc -private im_project_reminders_send_notification_to_object_members {
} else {
set sql "select acs_log__notice(
'intranet-project-reminders::im_project_reminders_send_notification_to_object_members',
'Found party/parties to be notified: $object_id')
'Found following party/parties to be notified for object_id $object_id: $parties_to_be_notified_id')
"
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment