X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=rt%2Fhtml%2FElements%2FLogin;h=cd39b87d849bdb994b6e236080db9282a20044c8;hp=1d4bfd5eca9b3b8a359596c2056c2e04ca9e7ee4;hb=ef20b2b6b1feb47ad02b5ff7525f1a0fd11d0fa4;hpb=a513c0bef534d05f03c1242831b6f3be19b97dae diff --git a/rt/html/Elements/Login b/rt/html/Elements/Login index 1d4bfd5ec..cd39b87d8 100644 --- a/rt/html/Elements/Login +++ b/rt/html/Elements/Login @@ -2,7 +2,7 @@ %# %# COPYRIGHT: %# -%# This software is Copyright (c) 1996-2005 Best Practical Solutions, LLC +%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC %# %# %# (Except where explicitly superseded by other copyright notices) @@ -22,7 +22,9 @@ %# %# You should have received a copy of the GNU General Public License %# along with this program; if not, write to the Free Software -%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +%# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +%# 02110-1301 or visit their web page on the internet at +%# http://www.gnu.org/copyleft/gpl.html. %# %# %# CONTRIBUTION SUBMISSION POLICY: @@ -51,36 +53,58 @@ if ($m->request_comp->path =~ '^/REST/\d+\.\d+/') { $m->out("\n$Error\n") if $Error; $m->abort; } + +my $req_uri; + +if (UNIVERSAL::can($r, 'uri') and $r->uri =~ m{.*/(.*)}) { + $req_uri = $1; +} + +my $form_action = defined $goto ? $goto + : defined $req_uri ? $req_uri + : $RT::WebPath + ; <& /Elements/Callback, %ARGS, _CallbackName => 'Header' &> <& /Elements/Header, Title => loc('Login'), Focus => 'user' &> -
+%# End of div#quickbar from /Elements/Header +
+ +
+ % if ($Error) { -<& /Elements/TitleBoxStart, title => loc('Error') &> +<&| "/Widgets/TitleBox", title => loc('Error'), hideable => 0 &> <% $Error %> -<& /Elements/TitleBoxEnd &> + % } -
-<& /Elements/TitleBoxStart, width=> "40%", titleright => loc("RT [_1]", $RT::VERSION), title => loc('Login') , -contentbg=>"#cccccc" &> + +<& /Elements/Callback, %ARGS, _CallbackName => 'BeforeForm' &> + +
+<&| /Widgets/TitleBox, title => loc('Login'), titleright => $RT::VERSION, hideable => 0 &> % unless ($RT::WebExternalAuth and !$RT::WebFallbackToInternalAuth) { -
- - - - - -
<&|/l&>Username:
<&|/l&>Password:
- -
+ + +
+ <&|/l&>Username: + +
+ +
+ <&|/l&>Password: + +
+ +
+ +
%# Give callbacks a chance to add more control elements <& /Elements/Callback, %ARGS &> -<&/Elements/TitleBoxEnd&> % # From mason 1.0.1 forward, this doesn't work. in fact, it breaks things. % # But on Mason 1.15 it's fixed again, so we still use it. % # The code below iterates through everything in the passed in arguments @@ -92,27 +116,19 @@ contentbg=>"#cccccc" &> % if (($key ne 'user') and ($key ne 'pass')) { % if (ref($ARGS{$key}) =~ /ARRAY/) { % foreach $val (@{$ARGS{$key}}) { - + % } % } % else { - + % } % } % } -
+ % } -
- -
- -
-
-
-
+ +
+<& /Elements/Callback, %ARGS, _CallbackName => 'AfterForm' &> <& /Elements/Footer, Menu => 0 &> <%ARGS> $user => ""