sunnyman's (sunnyman) wrote in changelog,
sunnyman's
sunnyman
changelog

[ljcom] r11391: LJSUP-10937: Shop history items updated....

Committer: vtroitsky
LJSUP-10937: Shop history items updated.
U   trunk/cgi-bin/LJ/Pay/Payment/PayItem/SelfPromo.pm
Modified: trunk/cgi-bin/LJ/Pay/Payment/PayItem/SelfPromo.pm
===================================================================
--- trunk/cgi-bin/LJ/Pay/Payment/PayItem/SelfPromo.pm	2012-02-01 15:25:56 UTC (rev 11390)
+++ trunk/cgi-bin/LJ/Pay/Payment/PayItem/SelfPromo.pm	2012-02-01 15:27:52 UTC (rev 11391)
@@ -27,11 +27,11 @@
     #return  LJ::Pay::SelfPromo::Promo->create_from_item($self);
     my ($self) = @_;
 
-    my $sp_class = $self->get_prop('selfpromo');
+    my $sp_type = $self->get_prop('selfpromo');
     my $journalid = $self->get_prop('selfpromo_journalid');
 
   #  print "journalid: $journalid\n";
-    if ($sp_class eq 'entry') {
+    if ($sp_type eq 'entry') {
         my $ditemid  = $self->get_prop('selfpromo_ditemid');
    #     print "ditemid: $ditemid\n";
         return unless $journalid && $ditemid;
@@ -50,8 +50,8 @@
 
     my $object = $self->get_object;
     return unless $object;
-    my $sp_class = $self->get_prop('selfpromo');
-    return  ($sp_class eq 'entry' ? $object->url : $object->journal_base); 
+    my $sp_type = $self->get_prop('selfpromo');
+    return  ($sp_type eq 'entry' ? $object->url : $object->journal_base); 
 }
 
 sub get_object_owner {
@@ -63,8 +63,8 @@
 
     my $object = $self->get_object;
     return unless $object;
-    my $sp_class = $self->get_prop('selfpromo');
-    return  ($sp_class eq 'entry' ? $object->poster : $sp_class eq 'community' ? $object : $object); 
+    my $sp_type = $self->get_prop('selfpromo');
+    return  ($sp_type eq 'entry' ? $object->poster : $sp_type eq 'community' ? $object : $object); 
 }
 
 #sub get_entry_url {
@@ -82,8 +82,8 @@
 
 sub get_product_name {
     my ($self) = @_;
-
-    return LJ::Lang::ml( 'selfpromo.shop_item.name',
+    my $sp_type = $self->get_prop('selfpromo');
+    return LJ::Lang::ml( "selfpromo.$sp_type.shop_item.name",
         { 'object_url' => $self->get_object_url } );
 }
 

Tags: ljcom, pm, sunnyman, vtroitsky
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