fu: Close-up of Fu, bringing a scoop of water to her mouth (Default)
fu ([personal profile] fu) wrote in [site community profile] changelog2011-05-02 11:55 am

[dw-free] Move manage/subscriptions/user.bml to use "tracking"

[commit: http://hg.dwscoalition.org/dw-free/rev/034efde6e7ca]

http://bugs.dwscoalition.org/show_bug.cgi?id=2718

Change user-facing text to notifications/tracked items as appropriate.

Patch by [personal profile] ninetydegrees.

Files modified:
  • bin/upgrading/en.dat
  • cgi-bin/LJ/Subscription.pm
  • cgi-bin/weblib.pl
  • htdocs/manage/index.bml
  • htdocs/manage/index.bml.text
  • htdocs/manage/settings/index.bml
  • htdocs/manage/settings/index.bml.text
  • htdocs/tools/endpoints/esn_subs.bml
--------------------------------------------------------------------------------
diff -r 349e60113ca0 -r 034efde6e7ca bin/upgrading/en.dat
--- a/bin/upgrading/en.dat	Mon May 02 19:39:53 2011 +0800
+++ b/bin/upgrading/en.dat	Mon May 02 19:54:51 2011 +0800
@@ -3565,7 +3565,7 @@ subscribe_interface.manage_settings=Mana
 
 subscribe_interface.nosubs.text=Track entries, comments, and account updates by clicking the [[img]] icon or the "Track This" link that appears on entries, comments, and the Profile page.
 
-subscribe_interface.nosubs.title=You don't have any subscriptions
+subscribe_interface.nosubs.title2=You aren't tracking any items
 
 subscribe_interface.notify_me=Notify me when...
 
@@ -3575,7 +3575,7 @@ subscribe_interface.save=Save
 
 subscribe_interface.special_subs.note=These notification options are only available by email and won't show in your [[sitenameabbrev]] Inbox.
 
-subscribe_interface.subs.total=You are using [[active]] out of [[max_active]] active subscriptions.
+subscribe_interface.subs.total2=You are using [[active]] out of [[max_active]] active notifications.
 
 subscribe_interface.unavailable_subs.note=These notification options are only available to certain account types.
 
diff -r 349e60113ca0 -r 034efde6e7ca cgi-bin/LJ/Subscription.pm
--- a/cgi-bin/LJ/Subscription.pm	Mon May 02 19:39:53 2011 +0800
+++ b/cgi-bin/LJ/Subscription.pm	Mon May 02 19:54:51 2011 +0800
@@ -613,8 +613,8 @@ sub as_string {
 sub as_string {
     my $self = shift;
     my $max = $self->field('u')->count_max_subscriptions;
-    return 'The subscription "' . $self->field('subscr')->as_html . '" was not saved because you have' .
-        " reached your limit of $max active subscriptions. Subscriptions need to be deactivated before more can be added.";
+    return 'The notification tracking "' . $self->field('subscr')->as_html . '" was not saved because you have' .
+        " reached your limit of $max active notifications. Notifications need to be deactivated before more can be added.";
 }
 
 # Too many subscriptions exist, not necessarily active
@@ -625,8 +625,8 @@ sub as_string {
 sub as_string {
     my $self = shift;
     my $max = $self->field('max');
-    return 'The subscription "' . $self->field('subscr')->as_html . '" was not saved because you have' .
-        " more than $max existing subscriptions. Subscriptions need to be completely removed before more can be added.";
+    return 'The notification tracking "' . $self->field('subscr')->as_html . '" was not saved because you have' .
+        " more than $max existing notifications. Notifications need to be completely removed before more can be added.";
 }
 
 1;
diff -r 349e60113ca0 -r 034efde6e7ca cgi-bin/weblib.pl
--- a/cgi-bin/weblib.pl	Mon May 02 19:39:53 2011 +0800
+++ b/cgi-bin/weblib.pl	Mon May 02 19:54:51 2011 +0800
@@ -3629,7 +3629,7 @@ sub subscribe_interface {
 
         # show blurb if not tracking anything
         if ($cat_empty && $is_tracking_category) {
-            my $blurb = "<?p <strong>" . LJ::Lang::ml('subscribe_interface.nosubs.title') . "</strong><br />";
+            my $blurb = "<?p <strong>" . LJ::Lang::ml('subscribe_interface.nosubs.title2') . "</strong><br />";
             $blurb .= LJ::Lang::ml( 'subscribe_interface.nosubs.text',
                 { img => LJ::img( 'track', '', { align => 'absmiddle',
                                   alt => $ui_notify } ) } ) . " p?>";
@@ -3685,7 +3685,7 @@ sub subscribe_interface {
         # max for total number of subscriptions (generally it is $paid_max)
         my $system_max  = $u_max > $paid_max ? $u_max : $paid_max;
 
-        $subscription_stats .= "<div class='subscription_stats'>" . LJ::Lang::ml( 'subscribe_interface.subs.total',  {
+        $subscription_stats .= "<div class='subscription_stats'>" . LJ::Lang::ml( 'subscribe_interface.subs.total2',  {
                             active =>  $max_active_method,
                             max_active => $u_max,
                             total => $max_total_method,
diff -r 349e60113ca0 -r 034efde6e7ca htdocs/manage/index.bml
--- a/htdocs/manage/index.bml	Mon May 02 19:39:53 2011 +0800
+++ b/htdocs/manage/index.bml	Mon May 02 19:54:51 2011 +0800
@@ -147,7 +147,7 @@ _code?>
     my $remote = LJ::get_remote();
 
     if ($remote && $remote->can_use_esn) {
-        return '<li><a href="/manage/subscriptions/" title="<?_ml .manage.subscriptions.about _ml?>"><?_ml .manage.subscriptions _ml?></a></li>';
+        return '<li><a href="/manage/subscriptions/" title="<?_ml .manage.notifications.about _ml?>"><?_ml .manage.notifications _ml?></a></li>';
     } else {
         return '';
     }
diff -r 349e60113ca0 -r 034efde6e7ca htdocs/manage/index.bml.text
--- a/htdocs/manage/index.bml.text	Mon May 02 19:39:53 2011 +0800
+++ b/htdocs/manage/index.bml.text	Mon May 02 19:54:51 2011 +0800
@@ -105,9 +105,9 @@
 
 .manage.logins=Manage Logins
 
-.manage.subscriptions=Manage Message Settings
+.manage.notifications=Manage Notification Options
 
-.manage.subscriptions.about=Manage notifications and subscriptions
+.manage.notifications.about=Manage your notification tracking options
 
 .mobile.settings=Mobile Settings
 
diff -r 349e60113ca0 -r 034efde6e7ca htdocs/manage/settings/index.bml
--- a/htdocs/manage/settings/index.bml	Mon May 02 19:39:53 2011 +0800
+++ b/htdocs/manage/settings/index.bml	Mon May 02 19:54:51 2011 +0800
@@ -205,7 +205,7 @@ body<=
 
         if ( $given_cat eq "notifications" && $POST{deleteinactive} ) {
             $u->delete_all_inactive_subscriptions;
-            $submit_msg .= "<?errorbar $ML{'.success.deleteinactive'} errorbar?><br />";
+            $submit_msg .= "<?errorbar $ML{'.success.deleteinactive2'} errorbar?><br />";
         } elsif ( $given_cat eq "notifications" ) {
             my @notif_errors;
 
@@ -429,10 +429,10 @@ body<=
     $ret .= "<div id='settings_save' class='action-bar'>";
     $ret .= $cats_with_settings{$given_cat}->{form} ? LJ::html_submit($ML{'.btn.save'}) : "&nbsp;";
     $ret .= "&nbsp;";
-    my $del_conf = LJ::ejs( $ML{'.confirm.deleteinactive'} );
-    $ret .= LJ::html_submit( 'deleteinactive', $ML{'.btn.deleteinactive'}, {
+    my $del_conf = LJ::ejs( $ML{'.confirm.deleteinactive2'} );
+    $ret .= LJ::html_submit( 'deleteinactive', $ML{'.btn.deleteinactive2'}, {
         class => 'btn',
-        title => $ML{'.btn.deleteinactive'},
+        title => $ML{'.btn.deleteinactive2'},
         onClick => "return confirm( '$del_conf' )"
         } );
     $ret .= "</div>";
@@ -564,10 +564,10 @@ body<=
     $ret .= $cats_with_settings{$given_cat}->{form} ? LJ::html_submit($ML{'.btn.save'}) : "&nbsp;";
     if ( $given_cat eq "notifications" ) {
         $ret .= "&nbsp;";
-        my $del_conf = LJ::ejs( $ML{'.confirm.deleteinactive'} );
-        $ret .= LJ::html_submit( 'deleteinactive', $ML{'.btn.deleteinactive'}, {
+        my $del_conf = LJ::ejs( $ML{'.confirm.deleteinactive2'} );
+        $ret .= LJ::html_submit( 'deleteinactive', $ML{'.btn.deleteinactive2'}, {
             class => 'btn',
-            title => $ML{'.btn.deleteinactive'},
+            title => $ML{'.btn.deleteinactive2'},
             onClick => "return confirm( '$del_conf' )"
             } );
     }
diff -r 349e60113ca0 -r 034efde6e7ca htdocs/manage/settings/index.bml.text
--- a/htdocs/manage/settings/index.bml.text	Mon May 02 19:39:53 2011 +0800
+++ b/htdocs/manage/settings/index.bml.text	Mon May 02 19:54:51 2011 +0800
@@ -13,7 +13,7 @@
 
 .bdayreminder=Receive email reminders for the birthdays of people in your Circle.
 
-.btn.deleteinactive=Delete all inactive subscriptions
+.btn.deleteinactive2=Delete all inactive tracked items
 
 .btn.save=Save
 
@@ -49,7 +49,7 @@
 
 .commentpage.text=When you follow a comment link from your Reading page, you can view that comment page in your own journal style.
 
-.confirm.deleteinactive=Are you sure you want to delete all inactive subscriptions?
+.confirm.deleteinactive2=Are you sure you want to delete all inactive tracked items?
 
 .contextualhover=Show contextual hover menu
 
@@ -161,7 +161,7 @@
 
 .success=You've successfully saved your account settings.
 
-.success.deleteinactive=You have successfully deleted all inactive subscriptions.
+.success.deleteinactive2=You have successfully deleted all inactive tracked items.
 
 .success.header=Success!
 
diff -r 349e60113ca0 -r 034efde6e7ca htdocs/tools/endpoints/esn_subs.bml
--- a/htdocs/tools/endpoints/esn_subs.bml	Mon May 02 19:39:53 2011 +0800
+++ b/htdocs/tools/endpoints/esn_subs.bml	Mon May 02 19:54:51 2011 +0800
@@ -59,7 +59,7 @@ _c?>
 
         $subscr->delete;
         $success = 1;
-        $ret{msg} = "Subscription deleted";
+        $ret{msg} = "Notification Tracking Removed";
         $ret{subscribed} = 0;
 
 
@@ -75,12 +75,12 @@ _c?>
         }
     } elsif ($action eq 'addsub') {
 
-        return $err->("Reached limit of " . $remote->count_max_subscriptions . " active subscriptions")
+        return $err->("Reached limit of " . $remote->count_max_subscriptions . " active notifications")
             unless $remote->can_add_inbox_subscription;
 
         my %subparams = ();
 
-        return $err->("Invalid subscription parameters") unless (defined $POST{journalid}) && $POST{etypeid}+0;
+        return $err->("Invalid notification tracking parameters") unless (defined $POST{journalid}) && $POST{etypeid}+0;
 
         foreach my $param (qw(journalid etypeid arg1 arg2)) {
             $subparams{$param} = $POST{$param}+0;
@@ -97,7 +97,7 @@ _c?>
         if ($subscr) {
             $subscr->activate;
             $success = 1;
-            $ret{msg} = "Subscribed";
+            $ret{msg} = "Notification Tracking Added";
             $ret{subscribed} = 1;
             $ret{event_class} = $subscr->event_class;
             my %sub_info = $subscr->sub_info;
--------------------------------------------------------------------------------