[Rt-commit] rt branch, 4.2/move-user-prefs-page-to-prefs-aboutme, created. rt-4.1.8-228-g0283363
? sunnavy
sunnavy at bestpractical.com
Sun May 5 12:32:37 EDT 2013
The branch, 4.2/move-user-prefs-page-to-prefs-aboutme has been created
at 028336317767fc7655d84fa5cc2dabfd0f002d54 (commit)
- Log -----------------------------------------------------------------
commit e6b2eed67f10865484d409e094ee912a7ec60b05
Author: sunnavy <sunnavy at bestpractical.com>
Date: Sun May 5 12:58:25 2013 +0800
move /User/Prefs.html to /Prefs/AboutMe.html for consistency, see also #14200
diff --git a/share/html/Elements/Tabs b/share/html/Elements/Tabs
index eb84dde..e5af4dd 100644
--- a/share/html/Elements/Tabs
+++ b/share/html/Elements/Tabs
@@ -549,7 +549,7 @@ my $build_main_nav = sub {
&& $session{'CurrentUser'}->HasRight( Right => 'ModifySelf', Object => RT->System )) {
my $settings = $about_me->child( settings => title => loc('Settings'), path => '/Prefs/Other.html' );
$settings->child( options => title => loc('Options'), path => '/Prefs/Other.html' );
- $settings->child( about_me => title => loc('About me'), path => '/User/Prefs.html' );
+ $settings->child( about_me => title => loc('About me'), path => '/Prefs/AboutMe.html' );
$settings->child( search_options => title => loc('Search options'), path => '/Prefs/SearchOptions.html' );
$settings->child( myrt => title => loc('RT at a glance'), path => '/Prefs/MyRT.html' );
$settings->child( dashboards_in_menu =>
diff --git a/share/html/User/Prefs.html b/share/html/Prefs/AboutMe.html
similarity index 99%
rename from share/html/User/Prefs.html
rename to share/html/Prefs/AboutMe.html
index e7b3c9a..15a805d 100644
--- a/share/html/User/Prefs.html
+++ b/share/html/Prefs/AboutMe.html
@@ -50,7 +50,7 @@
<& /Elements/ListActions, actions => \@results &>
-<form action="<%RT->Config->Get('WebPath')%>/User/Prefs.html" method="post">
+<form action="<%RT->Config->Get('WebPath')%>/Prefs/AboutMe.html" method="post">
<input type="hidden" class="hidden" name="id" value="<%$UserObj->Id%>" />
<table width="100%" border="0">
commit 028336317767fc7655d84fa5cc2dabfd0f002d54
Author: sunnavy <sunnavy at bestpractical.com>
Date: Sun May 5 13:26:37 2013 +0800
redirect old /User/Prefs.html and deprecate it
diff --git a/lib/RT/Interface/Web.pm b/lib/RT/Interface/Web.pm
index d88fe12..3ba9e5f 100644
--- a/lib/RT/Interface/Web.pm
+++ b/lib/RT/Interface/Web.pm
@@ -655,6 +655,15 @@ sub ShowRequestedPage {
# precache all system level rights for the current user
$HTML::Mason::Commands::session{CurrentUser}->PrincipalObj->HasRights( Object => RT->System );
+ if ( $HTML::Mason::Commands::r->path_info =~ m{^(/+)User/Prefs.html} ) {
+ RT->Deprecated(
+ Message => '/User/Prefs.html is deprecated',
+ Instead => "/Prefs/AboutMe.html",
+ Stack => 0,
+ );
+ RT::Interface::Web::Redirect( RT->Config->Get('WebURL') . 'Prefs/AboutMe.html' );
+ }
+
# If the user isn't privileged, they can only see SelfService
unless ( $HTML::Mason::Commands::session{'CurrentUser'}->Privileged ) {
-----------------------------------------------------------------------
More information about the Rt-commit
mailing list