Skip to content

Commit

Permalink
SAK-30000 site creation notification emails should use the site title…
Browse files Browse the repository at this point in the history
… instead of the site ID
  • Loading branch information
bjones86 committed Oct 22, 2015
1 parent 01fdfd2 commit b07f463
Show file tree
Hide file tree
Showing 5 changed files with 97 additions and 72 deletions.
28 changes: 28 additions & 0 deletions reference/docs/conversion/sakai_11_mysql_conversion.sql
Original file line number Diff line number Diff line change
Expand Up @@ -421,3 +421,31 @@ INSERT INTO SAKAI_SITE_TOOL VALUES('!contact-us', '!contact-us', '!contact-us',
-- SAK-29733 Change Schedule to Calendar for existing sites
UPDATE SAKAI_SITE_TOOL SET TITLE="Calendar" WHERE REGISTRATION = "sakai.schedule" AND TITLE = "Schedule";
UPDATE SAKAI_SITE_PAGE SET TITLE="Calendar" WHERE TITLE = "Schedule";

-- SAK-30000 Site creation notification email template updates
UPDATE email_template_item
SET message = '
From Worksite Setup to ${serviceName} support:
<#if courseSite ="true">Official Course Site<#else>Site </#if> ${siteTitle} (ID ${siteId}) was set up by ${currentUserDisplayName} (${currentUserDisplayId}, email ${currentUserEmail}) on ${dateDisplay} <#if courseSite ="true">for ${termTitle} </#if>
<#if numSections = "1">with access to the roster for this section:<#elseif numSections != "0">with access to rosters for these ${numSections} sections:</#if>
${sections}
'
WHERE template_key = 'sitemanage.notifySiteCreation' AND template_locale = 'default';
UPDATE email_template_item
SET subject = 'Site "${siteTitle}" was successfully created by ${currentUserDisplayName}', message = '
Hi, ${currentUserDisplayName}:
Your site "${siteTitle}" has been successfully created. The following is a copy of the site creation notification email sent to ${serviceName} support:
From Worksite Setup to ${serviceName} support:
<#if courseSite ="true">Official Course Site<#else>Site </#if> ${siteTitle} (ID ${siteId}) was set up by ${currentUserDisplayName} (${currentUserDisplayId}, email ${currentUserEmail}) on ${dateDisplay} <#if courseSite ="true">for ${termTitle} </#if>
<#if numSections = "1">with access to the roster for this section:<#elseif numSections != "0">with access to rosters for these ${numSections} sections:</#if>
${sections}
'
WHERE template_key = 'sitemanage.notifySiteCreation.confirmation' AND template_locale = 'default';
-- END SAK-30000
28 changes: 28 additions & 0 deletions reference/docs/conversion/sakai_11_oracle_conversion.sql
Original file line number Diff line number Diff line change
Expand Up @@ -438,3 +438,31 @@ INSERT INTO SAKAI_SITE_TOOL VALUES('!contact-us', '!contact-us', '!contact-us',
--KNL-1379 Bigger SESSION_USER_AGENT
ALTER TABLE SAKAI_SESSION MODIFY SESSION_USER_AGENT VARCHAR2 (255 CHAR);
-- END KNL-1379

-- SAK-30000 Site creation notification email template updates
UPDATE email_template_item
SET message = '
From Worksite Setup to ${serviceName} support:

<#if courseSite ="true">Official Course Site<#else>Site </#if> ${siteTitle} (ID ${siteId}) was set up by ${currentUserDisplayName} (${currentUserDisplayId}, email ${currentUserEmail}) on ${dateDisplay} <#if courseSite ="true">for ${termTitle} </#if>
<#if numSections = "1">with access to the roster for this section:<#elseif numSections != "0">with access to rosters for these ${numSections} sections:</#if>

${sections}
'
WHERE template_key = 'sitemanage.notifySiteCreation' AND template_locale = 'default';
UPDATE email_template_item
SET subject = 'Site "${siteTitle}" was successfully created by ${currentUserDisplayName}', message = '
Hi, ${currentUserDisplayName}:

Your site "${siteTitle}" has been successfully created. The following is a copy of the site creation notification email sent to ${serviceName} support:


From Worksite Setup to ${serviceName} support:

<#if courseSite ="true">Official Course Site<#else>Site </#if> ${siteTitle} (ID ${siteId}) was set up by ${currentUserDisplayName} (${currentUserDisplayId}, email ${currentUserEmail}) on ${dateDisplay} <#if courseSite ="true">for ${termTitle} </#if>
<#if numSections = "1">with access to the roster for this section:<#elseif numSections != "0">with access to rosters for these ${numSections} sections:</#if>

${sections}
'
WHERE template_key = 'sitemanage.notifySiteCreation.confirmation' AND template_locale = 'default';
-- END SAK-30000
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
<subject>Site Created by ${currentUserDisplayName}</subject>
<message>

From Worksite Setup to ${serverName} Support:
&lt;#if courseSite ="true"&gt;Official Course Site&lt;#else&gt;Site &lt;/#if&gt; ${siteTitle} (id ${siteId}) was set up by ${currentUserDisplayName} (${currentUserDisplayId}, email ${currentUserEmail}) on ${dateDisplay} &lt;#if courseSite ="true"&gt; for ${termTitle} &lt;/#if&gt;
&lt;#if numSections = "1"&gt;with access to roster for this section:&lt;#elseif numSections != "0"&gt;with access to rosters for these ${numSections} sections:&lt;/#if&gt;
From Worksite Setup to ${serviceName} support:

&lt;#if courseSite ="true"&gt;Official Course Site&lt;#else&gt;Site &lt;/#if&gt; ${siteTitle} (ID ${siteId}) was set up by ${currentUserDisplayName} (${currentUserDisplayId}, email ${currentUserEmail}) on ${dateDisplay} &lt;#if courseSite ="true"&gt;for ${termTitle} &lt;/#if&gt;
&lt;#if numSections = "1"&gt;with access to the roster for this section:&lt;#elseif numSections != "0"&gt;with access to rosters for these ${numSections} sections:&lt;/#if&gt;

${sections}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
<?xml version="1.0"?>
<emailTemplates>
<emailTemplate>
<subject>Site ${siteId} was successfully created by ${currentUserDisplayName}</subject>
<subject>Site "${siteTitle}" was successfully created by ${currentUserDisplayName}</subject>
<message>

Hi, ${currentUserDisplayName}:

Your site ${siteId} has been successfully created. Following is a copy of Site Creation Email sent to ${serverName} Support:
Your site "${siteTitle}" has been successfully created. The following is a copy of the site creation notification email sent to ${serviceName} support:


From Worksite Setup to ${serverName} Support:
&lt;#if courseSite ="true"&gt;Official Course Site&lt;#else&gt;Site &lt;/#if&gt; ${siteTitle} (id ${siteId}) was set up by ${currentUserDisplayName} (${currentUserDisplayId}, email ${currentUserEmail}) on ${dateDisplay} &lt;#if courseSite ="true"&gt; for ${termTitle} &lt;/#if&gt;
&lt;#if numSections = "1"&gt;with access to roster for this section:&lt;#elseif numSections != "0"&gt;with access to rosters for these ${numSections} sections:&lt;/#if&gt;
From Worksite Setup to ${serviceName} support:

&lt;#if courseSite ="true"&gt;Official Course Site&lt;#else&gt;Site &lt;/#if&gt; ${siteTitle} (ID ${siteId}) was set up by ${currentUserDisplayName} (${currentUserDisplayId}, email ${currentUserEmail}) on ${dateDisplay} &lt;#if courseSite ="true"&gt;for ${termTitle} &lt;/#if&gt;
&lt;#if numSections = "1"&gt;with access to the roster for this section:&lt;#elseif numSections != "0"&gt;with access to rosters for these ${numSections} sections:&lt;/#if&gt;

${sections}

Expand Down
Loading

0 comments on commit b07f463

Please sign in to comment.