holyandrew (holyandrew) wrote in changelog,
holyandrew
holyandrew
changelog

[livejournal] r22500: LJSUP-13039: olympics2012.lenta.ru heade...

Committer: akanashin
LJSUP-13039: olympics2012.lenta.ru header
U   trunk/cgi-bin/LJ/SiteScheme.pm
Modified: trunk/cgi-bin/LJ/SiteScheme.pm
===================================================================
--- trunk/cgi-bin/LJ/SiteScheme.pm	2012-07-26 08:27:07 UTC (rev 22499)
+++ trunk/cgi-bin/LJ/SiteScheme.pm	2012-07-26 08:52:47 UTC (rev 22500)
@@ -110,6 +110,15 @@
     return 0;
 }
 
+sub lentaru_branding {
+    my $time = time;
+    my $time_start = 1343332800; # 27.07.2012 00:00 MSK
+    my $time_end   = 1344801599; # 12.08.2012 23:59 MSK
+
+    return 1 if ($time > $time_start && $time < $time_end);
+    return 0;
+}
+
 sub common_template_params {
     my ( $class, $args ) = @_;
 
@@ -209,6 +218,7 @@
     my $remote_wallet_link     = 0;
     my $remote_ljphoto_url     = '';
     my $remote_can_use_ljphoto = 0;
+    my $remote_is_sup          = 0;
 
     if ($remote) {
         my $username = $remote->username;
@@ -239,6 +249,7 @@
         $remote_wallet_link     = LJ::Pay::Wallet->get_wallet_link($remote);
         $remote_ljphoto_url     = $remote->journal_base . '/pics/';
         $remote_can_use_ljphoto = $remote->can_use_ljphoto ? 1 : 0;
+        $remote_is_sup          = LJ::SUP->is_remote_sup();
     }
 
     my $need_loginform = 0;
@@ -426,6 +437,7 @@
         'ml_copyright_header' => $ml_copyright_header,
 
         'branding'            => $branding,
+        'lentaru_branding'    => $remote_is_sup && lentaru_branding,
     };
 }
 

Tags: akanashin, holyandrew, livejournal, 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