Fixed wrong date/time in discussion message notification email.
This commit is contained in:
parent
bff8f0bbe2
commit
b5af76db00
2 changed files with 6 additions and 6 deletions
|
@ -16,5 +16,5 @@ using System.Reflection;
|
||||||
//
|
//
|
||||||
// You can specify all the values or you can default the Revision and Build Numbers
|
// You can specify all the values or you can default the Revision and Build Numbers
|
||||||
// by using the '*' as shown below:
|
// by using the '*' as shown below:
|
||||||
[assembly: AssemblyVersion("3.0.4.563")]
|
[assembly: AssemblyVersion("3.0.4.564")]
|
||||||
[assembly: AssemblyFileVersion("3.0.4.563")]
|
[assembly: AssemblyFileVersion("3.0.4.564")]
|
|
@ -1410,8 +1410,7 @@ namespace ScrewTurn.Wiki {
|
||||||
|
|
||||||
bool done = page.Provider.AddMessage(page, username, subject, dateTime, body, parent);
|
bool done = page.Provider.AddMessage(page, username, subject, dateTime, body, parent);
|
||||||
if(done) {
|
if(done) {
|
||||||
SendEmailNotificationForMessage(page, Users.FindUser(username),
|
SendEmailNotificationForMessage(page, Users.FindUser(username), Tools.GetMessageIdForAnchor(dateTime), subject, dateTime);
|
||||||
Tools.GetMessageIdForAnchor(dateTime), subject);
|
|
||||||
|
|
||||||
PageContent content = Content.GetPageContent(page, false);
|
PageContent content = Content.GetPageContent(page, false);
|
||||||
RecentChanges.AddChange(page.FullName, content.Title, subject, dateTime, username, Change.MessagePosted, "");
|
RecentChanges.AddChange(page.FullName, content.Title, subject, dateTime, username, Change.MessagePosted, "");
|
||||||
|
@ -1427,7 +1426,8 @@ namespace ScrewTurn.Wiki {
|
||||||
/// <param name="author">The author of the message.</param>
|
/// <param name="author">The author of the message.</param>
|
||||||
/// <param name="id">The message ID to be used for anchors.</param>
|
/// <param name="id">The message ID to be used for anchors.</param>
|
||||||
/// <param name="subject">The message subject.</param>
|
/// <param name="subject">The message subject.</param>
|
||||||
private static void SendEmailNotificationForMessage(PageInfo page, UserInfo author, string id, string subject) {
|
/// <param name="dateTime">The message date/time.</param>
|
||||||
|
private static void SendEmailNotificationForMessage(PageInfo page, UserInfo author, string id, string subject, DateTime dateTime) {
|
||||||
if(page == null) return;
|
if(page == null) return;
|
||||||
|
|
||||||
PageContent content = Content.GetPageContent(page, false);
|
PageContent content = Content.GetPageContent(page, false);
|
||||||
|
@ -1443,7 +1443,7 @@ namespace ScrewTurn.Wiki {
|
||||||
EmailTools.AsyncSendMassEmail(recipients, Settings.SenderEmail,
|
EmailTools.AsyncSendMassEmail(recipients, Settings.SenderEmail,
|
||||||
Settings.WikiTitle + " - " + title,
|
Settings.WikiTitle + " - " + title,
|
||||||
body.Replace("##PAGE##", title).Replace("##USER##", author != null ? Users.GetDisplayName(author) : "anonymous").Replace("##DATETIME##",
|
body.Replace("##PAGE##", title).Replace("##USER##", author != null ? Users.GetDisplayName(author) : "anonymous").Replace("##DATETIME##",
|
||||||
Preferences.AlignWithServerTimezone(content.LastModified).ToString(Settings.DateTimeFormat)).Replace("##SUBJECT##",
|
Preferences.AlignWithServerTimezone(dateTime).ToString(Settings.DateTimeFormat)).Replace("##SUBJECT##",
|
||||||
subject).Replace("##LINK##", Settings.MainUrl + Tools.UrlEncode(page.FullName) +
|
subject).Replace("##LINK##", Settings.MainUrl + Tools.UrlEncode(page.FullName) +
|
||||||
Settings.PageExtension + "?Discuss=1#" + id).Replace("##WIKITITLE##", Settings.WikiTitle),
|
Settings.PageExtension + "?Discuss=1#" + id).Replace("##WIKITITLE##", Settings.WikiTitle),
|
||||||
false);
|
false);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue