This commit was generated by cvs2svn to compensate for changes in r3883,
[freeside.git] / rt / html / Elements / PageLayout
1 %# BEGIN LICENSE BLOCK
2 %# 
3 %# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
4 %# 
5 %# (Except where explictly superceded by other copyright notices)
6 %# 
7 %# This work is made available to you under the terms of Version 2 of
8 %# the GNU General Public License. A copy of that license should have
9 %# been provided with this software, but in any event can be snarfed
10 %# from www.gnu.org.
11 %# 
12 %# This work is distributed in the hope that it will be useful, but
13 %# WITHOUT ANY WARRANTY; without even the implied warranty of
14 %# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
15 %# General Public License for more details.
16 %# 
17 %# Unless otherwise specified, all modifications, corrections or
18 %# extensions to this work which alter its source code become the
19 %# property of Best Practical Solutions, LLC when submitted for
20 %# inclusion in the work.
21 %# 
22 %# 
23 %# END LICENSE BLOCK
24 <table class="darkblue" border=0 cellspacing=0 cellpadding=0 width="100%">
25   <th class="titlebox" align="left"><span class="rtname"><%$AppName%></span>
26   </th>
27       <span class="topactions">
28 % foreach my $action (sort keys %{$topactions}) {
29         <td class="darkblueright">
30         <%$topactions->{"$action"}->{'html'} |n %>
31         </td>
32 % }
33       </span>
34 </table>
35 <table border=0 cellspacing=0 cellpadding=0 width="100%" height="100%">
36 %# Vertical menu
37 <TR height="100%">
38 <TD valign="top" width="140" class="blue">
39           <& /Elements/Menu, toptabs => $toptabs, current_toptab => $current_toptab &>
40 </TD>
41 <td valign="top">
42 <table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
43 <tr>
44   <td class="blue" valign="top">
45     <span class="title"><%$title%></span>
46 </td>
47 </tr>
48 <tr>
49 <td class="blueright" valign="top">
50     <span class="nav"> 
51 % if ($actions) {
52 % my @actions;
53 % foreach my $action (sort keys %{$actions}) {
54 % if ($actions->{"$action"}->{'html'}) {
55 % push @actions, $actions->{"$action"}->{'html'}; 
56 % } else {
57 % push @actions,  "<A class='nav' HREF=\"".$RT::WebPath."/".$actions->{$action}->{'path'}."\">".$actions->{$action}->{'title'}."</A>";
58 % }
59 %  }
60 <% join(" | ", @actions) | n %>
61 % if ($subactions) {
62 % my @actions;
63 % foreach my $action (sort keys %{$subactions}) {
64 % push @actions, $subactions->{"$action"}->{'html'}; 
65 %  }
66 <% join(" | ", @actions) | n %>
67 % }
68 % }
69     </span>
70   </td>
71 </tr>
72 <TR valign="top">
73 <TD valign="top" width="100%" height="100%" class="mainbody" >
74
75 <%INIT>
76
77   foreach my $tab (sort keys %{$toptabs}) {
78     if ($toptabs->{$tab}->{'path'} eq $current_toptab) {
79       $toptabs->{$tab}->{"subtabs"} = $tabs;
80       $toptabs->{$tab}->{"current_subtab"} = $current_tab;
81     }
82   }
83
84 if (! defined($AppName)) {
85   $AppName = loc("RT for [_1]", $RT::rtname);
86 }
87
88 </%INIT>
89 <%ARGS>
90 $current_toptab => undef
91 $current_tab => undef
92 $toptabs => undef
93 $topactions => undef
94 $tabs => undef
95 $actions => undef
96 $subactions => undef
97 $title => $m->callers(-1)->path
98 $AppName => undef
99 </%ARGS>