madeon (madeon) wrote in changelog,
madeon
madeon
changelog

[livejournal] r19816: LJSUP-9307: Fix: Incorrect date on Entry...

Committer: sbelyaev
LJSUP-9307: Fix: Incorrect date on EntryPage
U   branches/delayed_entries/cgi-bin/Apache/LiveJournal.pm
U   branches/delayed_entries/cgi-bin/LJ/S2/EntryPage.pm
Modified: branches/delayed_entries/cgi-bin/Apache/LiveJournal.pm
===================================================================
--- branches/delayed_entries/cgi-bin/Apache/LiveJournal.pm	2011-08-23 09:50:22 UTC (rev 19815)
+++ branches/delayed_entries/cgi-bin/Apache/LiveJournal.pm	2011-08-23 11:31:29 UTC (rev 19816)
@@ -797,7 +797,7 @@
                 return LJ::Request::NOT_FOUND;
             }
             
-            $ljentry = LJ::DelayedEntry->get_entry_by_id($u, $1);
+            $ljentry = LJ::DelayedEntry->get_entry_by_id($u, $1, { 'dateformat' => 'S2'});
             
             if ( $GET{'mode'} eq "reply" || $GET{'replyto'} || $GET{'edit'} ) {
                 $mode = "reply";

Modified: branches/delayed_entries/cgi-bin/LJ/S2/EntryPage.pm
===================================================================
--- branches/delayed_entries/cgi-bin/LJ/S2/EntryPage.pm	2011-08-23 09:50:22 UTC (rev 19815)
+++ branches/delayed_entries/cgi-bin/LJ/S2/EntryPage.pm	2011-08-23 11:31:29 UTC (rev 19816)
@@ -554,8 +554,10 @@
     my $s2entry = Entry($u, {
         'subject' => $subject,
         'text' => $event,
-        'dateparts' => LJ::TimeUtil->alldatepart_s2($entry->eventtime_mysql),
-        'system_dateparts' => LJ::TimeUtil->alldatepart_s2($entry->logtime_mysql),
+        'dateparts' => $entry->is_delayed ? $entry->alldatepart :
+                    LJ::TimeUtil->alldatepart_s2($entry->eventtime_mysql),
+        'system_dateparts' => $entry->is_delayed ? $entry->system_alldatepart :
+                    LJ::TimeUtil->alldatepart_s2($entry->logtime_mysql),
         'security' => $entry->security,
         'allowmask' => $entry->allowmask,
         'props' => $entry->props,

Tags: livejournal, madeon, pm
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments