diff options
Diffstat (limited to 'rt/html/Elements')
-rw-r--r-- | rt/html/Elements/AddCustomers | 59 | ||||
-rw-r--r-- | rt/html/Elements/CollectionAsTable/Row | 4 | ||||
-rw-r--r-- | rt/html/Elements/EditCustomers | 63 | ||||
-rw-r--r-- | rt/html/Elements/Footer | 46 | ||||
-rw-r--r-- | rt/html/Elements/FreesideInvoiceSearch | 20 | ||||
-rw-r--r-- | rt/html/Elements/FreesideNewCust | 3 | ||||
-rw-r--r-- | rt/html/Elements/FreesideSearch | 13 | ||||
-rw-r--r-- | rt/html/Elements/FreesideSvcSearch | 13 | ||||
-rw-r--r-- | rt/html/Elements/Header | 113 | ||||
-rw-r--r-- | rt/html/Elements/Menu | 4 | ||||
-rw-r--r-- | rt/html/Elements/PageLayout | 164 | ||||
-rw-r--r-- | rt/html/Elements/QuickCreate | 8 | ||||
-rw-r--r-- | rt/html/Elements/SelectDate | 19 | ||||
-rw-r--r-- | rt/html/Elements/ShadedBox | 33 | ||||
-rw-r--r-- | rt/html/Elements/ShadedInputRow | 35 | ||||
-rw-r--r-- | rt/html/Elements/ShadedRow | 31 | ||||
-rw-r--r-- | rt/html/Elements/SimpleSearch | 17 | ||||
-rw-r--r-- | rt/html/Elements/Tabs | 26 | ||||
-rw-r--r-- | rt/html/Elements/TicketList | 7 | ||||
-rw-r--r-- | rt/html/Elements/TitleBoxStart | 4 | ||||
-rw-r--r-- | rt/html/Elements/ViewUser | 51 |
21 files changed, 432 insertions, 301 deletions
diff --git a/rt/html/Elements/AddCustomers b/rt/html/Elements/AddCustomers new file mode 100644 index 000000000..aaf8ca8ba --- /dev/null +++ b/rt/html/Elements/AddCustomers @@ -0,0 +1,59 @@ +%# Copyright (c) 2004 Ivan Kohler <ivan-rt@420.am> +%# Copyright (c) 2008 Freeside Internet Services, Inc. +%# +%# This work is made available to you under the terms of Version 2 of +%# the GNU General Public License. A copy of that license should have +%# been provided with this software, but in any event can be snarfed +%# from www.gnu.org. +%# +%# This work is distributed in the hope that it will be useful, but +%# WITHOUT ANY WARRANTY; without even the implied warranty of +%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +%# General Public License for more details. +<BR> +<%$msg%><br> + +% if (@Customers) { + +<br><i>(Check box to link)<i> +<table> +% foreach my $customer (@Customers) { +<tr> + <td> + <input type="checkbox" name="Object-AddCustomer-<% $customer->{'custnum'} %>" VALUE="1" <% scalar(@Customers) == 1 ? 'CHECKED' : '' %>> + <A HREF="<%$freeside_url%>/view/cust_main.cgi?<% $customer->{'custnum'} %>"><% &RT::URI::freeside::small_custview($customer->{'custnum'}, &RT::URI::freeside::FreesideGetConfig('countrydefault'), 1) |n %> + </td> +</tr> +% } +</table> + +% } + +<%INIT> +my ($msg); + +my $freeside_url = &RT::URI::freeside::FreesideURL(); + +warn "/Elements/AddCustomers called with CustomerString $CustomerString\n" + if $Debug; + +my @Customers = (); +if ( $CustomerString ) { + @Customers = &RT::URI::freeside::smart_search( 'search' => $CustomerString ); +} + +my @Services = (); +if ($ServiceString) { + @Services = (); #service_search(); +} + +warn "/Elements/AddCustomers displaying ". scalar(@Customers). " customers\n" + if $Debug; + +</%INIT> + +<%ARGS> +$CustomerString => undef +$ServiceString => undef +$Debug => 0 +</%ARGS> diff --git a/rt/html/Elements/CollectionAsTable/Row b/rt/html/Elements/CollectionAsTable/Row index bb9032149..d8492265e 100644 --- a/rt/html/Elements/CollectionAsTable/Row +++ b/rt/html/Elements/CollectionAsTable/Row @@ -2,7 +2,7 @@ %# %# COPYRIGHT: %# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC +%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC %# <jesse@bestpractical.com> %# %# (Except where explicitly superseded by other copyright notices) @@ -24,7 +24,7 @@ %# along with this program; if not, write to the Free Software %# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA %# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html. +%# http://www.gnu.org/copyleft/gpl.html. %# %# %# CONTRIBUTION SUBMISSION POLICY: diff --git a/rt/html/Elements/EditCustomers b/rt/html/Elements/EditCustomers new file mode 100644 index 000000000..68efb5f40 --- /dev/null +++ b/rt/html/Elements/EditCustomers @@ -0,0 +1,63 @@ +%# Copyright (c) 2004 Ivan Kohler <ivan-rt@420.am> +%# Copyright (c) 2008 Freeside Internet Services, Inc. +%# +%# This work is made available to you under the terms of Version 2 of +%# the GNU General Public License. A copy of that license should have +%# been provided with this software, but in any event can be snarfed +%# from www.gnu.org. +%# +%# This work is distributed in the hope that it will be useful, but +%# WITHOUT ANY WARRANTY; without even the implied warranty of +%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +%# General Public License for more details. +<TABLE width=100%> + <TR> + <TD VALIGN=TOP WIDTH=50%> + <h3><&|/l&>Current Customers</&></h3> + +<table> + <tr> + <td><i><&|/l&>(Check box to disassociate)</&></i></td> + </tr> + <tr> + <td class="value"> +% foreach my $link ( @{ $Object->Customers->ItemsArrayRef } ) { + + <INPUT TYPE=CHECKBOX NAME="DeleteLink--<%$link->Type%>-<%$link->Target%>"> +%# <& ShowLink, URI => $link->TargetURI &><br> + <A HREF="<% $link->TargetURI->Resolver->HREF %>"><% $link->TargetURI->Resolver->AsStringLong |n %></A> + <BR> +% } + </td> + </tr> +</table> + +</TD> + +<TD VALIGN=TOP> +<h3><&|/l&>New Customer Links</&></h3> +<&|/l&>Find customer</&><BR> +<input name="CustomerString"> +<input type=submit name="OnlySearchForCustomers" value="<&|/l&>Go!</&>"> +<br><i>cust #, name, company or phone</i> +<BR> +%#<BR> +%#<&|/l&>Find service</&><BR> +%#<input name="ServiceString"> +%#<input type=submit name="OnlySearchForServices" value="<&|/l&>Go!</&>"> +%#<br><i>username, username@domain, domain, or IP address</i> +%#<BR> + +<& AddCustomers, Object => $Object, + CustomerString => $CustomerString, + ServiceString => $ServiceString, &> + +</TD> +</TR> +</TABLE> + +<%ARGS> +$CustomerString => undef +$ServiceString => undef +$Object => undef +</%ARGS> diff --git a/rt/html/Elements/Footer b/rt/html/Elements/Footer index c3d766258..6604bd211 100644 --- a/rt/html/Elements/Footer +++ b/rt/html/Elements/Footer @@ -2,7 +2,7 @@ %# %# COPYRIGHT: %# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC +%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC %# <jesse@bestpractical.com> %# %# (Except where explicitly superseded by other copyright notices) @@ -24,7 +24,7 @@ %# along with this program; if not, write to the Free Software %# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA %# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html. +%# http://www.gnu.org/copyleft/gpl.html. %# %# %# CONTRIBUTION SUBMISSION POLICY: @@ -47,25 +47,31 @@ %# END BPS TAGGED BLOCK }}} %# End of div#body from /Elements/PageLayout </div> +</td> +</tr> +<tr> +<td> <& /Elements/Callback, %ARGS &> -<div id="footer"> - <p id="time"> - <span><&|/l&>Time to display</&>: <%Time::HiRes::tv_interval( $m->{'rt_base_time'} )%></span> - </p> - <p id="bpscredits"> - <span> -<&|/l, '»|«', $RT::VERSION, '2009', '<a href="http://www.bestpractical.com?rt='.$RT::VERSION.'">Best Practical Solutions, LLC</a>', &>[_1] RT [_2] Copyright 1996-[_3] [_4].</&> -</span> -</p> -% if (!$Menu) { - <p id="legal"> -<&|/l&>Distributed under version 2 <a href="http://www.gnu.org/copyleft/gpl.html"> of the GNU GPL.</a></&><br /> -<&|/l, '<a href="mailto:sales@bestpractical.com">sales@bestpractical.com</a>' &>To inquire about support, training, custom development or licensing, please contact [_1].</&><br /> - </p> -% } +%# <div id="footer"> +%# <p id="time"> +%# <span><&|/l&>Time to display</&>: <%Time::HiRes::tv_interval( $m->{'rt_base_time'} )%></span> +%# </p> + +%# <p id="bpscredits"> +%# <span> +%# <&|/l, '»|«', $RT::VERSION, '2006', '<a href="http://www.bestpractical.com?rt='.$RT::VERSION.'">Best Practical Solutions, LLC</a>', &>[_1] RT [_2] Copyright 1996-[_3] [_4].</&> +%# </span> +%# </p> +%# % if (!$Menu) { +%# <p id="legal"> +%# <&|/l&>Distributed under version 2 <a href="http://www.gnu.org/copyleft/gpl.html"> of the GNU GPL.</a></&><br /> +%# <&|/l, '<a href="mailto:sales@bestpractical.com">sales@bestpractical.com</a>' &>To inquire about support, training, custom development or licensing, please contact [_1].</&><br /> +%# </p> +%# % } + +%# </div> -</div> % if ($Debug >= 2 ) { % require Data::Dumper; % my $d = Data::Dumper->new([\%ARGS], [qw(%ARGS)]); @@ -74,6 +80,10 @@ </pre> % } +</TD> +</TR> +</TABLE> + </body> </html> % $m->abort(); diff --git a/rt/html/Elements/FreesideInvoiceSearch b/rt/html/Elements/FreesideInvoiceSearch new file mode 100644 index 000000000..3842b2ff9 --- /dev/null +++ b/rt/html/Elements/FreesideInvoiceSearch @@ -0,0 +1,20 @@ +% if ( $FS::CurrentUser::CurrentUser->access_right('View invoices') ) { + + <form action="<% $RT::URI::freeside::URL %>/search/cust_bill.html" STYLE="margin:0"> + <SCRIPT TYPE="text/javascript"> + function clearhint_search_invoice (what) { + if ( what.value == '(inv #)' ) + what.value = ''; + } + </SCRIPT> + <input name="invnum" accesskey="0" VALUE="(inv #)" SIZE="4" onFocus="clearhint_search_invoice(this);" onClick="clearhint_search_invoice(this);" STYLE="text-align:right; margin-bottom:1px; font-family: Arial, Verdana, Helvetica, sans-serif;"> + +% if ( $FS::CurrentUser::CurrentUser->access_right('List invoices') ) { + <A HREF="<% $RT::URI::freeside::URL %>search/report_cust_bill.html" STYLE="color: #ffffff; font-size: 70%; font-weight:normal">Advanced</A> +% } + <BR> + + <input type="submit" value="<&|/l&>Search invoices</&>" CLASS="fsblackbutton" onMouseOver="this.className='fsblackbuttonselected'; return true;" onMouseOut="this.className='fsblackbutton'; return true;" STYLE="font-size:70%"> + </form> + +% } diff --git a/rt/html/Elements/FreesideNewCust b/rt/html/Elements/FreesideNewCust new file mode 100644 index 000000000..f60e99559 --- /dev/null +++ b/rt/html/Elements/FreesideNewCust @@ -0,0 +1,3 @@ +<form action="<% $RT::URI::freeside::URL %>/edit/cust_main.cgi" STYLE="margin:0"> +<INPUT TYPE="submit" VALUE="<&|/l&>New customer</&>" CLASS="fsblackbutton" onMouseOver="this.className='fsblackbuttonselected'; return true;" onMouseOut="this.className='fsblackbutton'; return true;" STYLE="vertical-align:bottom; font-size:100%"> +</FORM> diff --git a/rt/html/Elements/FreesideSearch b/rt/html/Elements/FreesideSearch new file mode 100644 index 000000000..8e609bb4b --- /dev/null +++ b/rt/html/Elements/FreesideSearch @@ -0,0 +1,13 @@ +% if ( $FS::CurrentUser::CurrentUser->access_right('List customers') ) { +<form action="<% $RT::URI::freeside::URL %>/search/cust_main.cgi" STYLE="margin:0"> + <SCRIPT TYPE="text/javascript"> + function clearhint_search_cust (what) { + if ( what.value == '(cust #, name, company or phone)' ) + what.value = ''; + } + </SCRIPT> +<input name="search_cust" accesskey="0" VALUE="(cust #, name, company or phone)" SIZE="28" onFocus="clearhint_search_cust(this);" onClick="clearhint_search_cust(this);" STYLE="text-align:right; font-family: Arial, Verdana, Helvetica, sans-serif;"><BR> +<A HREF="<% $RT::URI::freeside::URL %>/search/report_cust_main.html" STYLE="color: #ffffff; font-size: 70%; font-weight:normal">Advanced</A> +<input type="submit" value="<&|/l&>Search customers</&>" CLASS="fsblackbutton" onMouseOver="this.className='fsblackbuttonselected'; return true;" onMouseOut="this.className='fsblackbutton'; return true;" STYLE="font-size:70%"> +</form> +% } diff --git a/rt/html/Elements/FreesideSvcSearch b/rt/html/Elements/FreesideSvcSearch new file mode 100644 index 000000000..d68122da5 --- /dev/null +++ b/rt/html/Elements/FreesideSvcSearch @@ -0,0 +1,13 @@ +% if ( $FS::CurrentUser::CurrentUser->access_right('View customer services') ) { +<form action="<% $RT::URI::freeside::URL %>/search/cust_svc.html" STYLE="margin:0"> + <SCRIPT TYPE="text/javascript"> + function clearhint_search_svc (what) { + if ( what.value == '(user, user@domain or domain)' ) + what.value = ''; + } + </SCRIPT> +<input name="search_svc" accesskey="0" VALUE="(user, user@domain or domain)" SIZE="26" onFocus="clearhint_search_svc(this);" onClick="clearhint_search_svc(this);" STYLE="text-align:right; font-family: Arial, Verdana, Helvetica, sans-serif;"><BR> + <A NOTYET="<% $RT::URI::freeside::URL %>search/svc_Smarter.html" STYLE="color: #000000; font-size: 70%; font-weight:normal">Advanced</A> +<input type="submit" value="<&|/l&>Search services</&>" CLASS="fsblackbutton" onMouseOver="this.className='fsblackbuttonselected'; return true;" onMouseOut="this.className='fsblackbutton'; return true;" STYLE="font-size:70%"> +</form> +% } diff --git a/rt/html/Elements/Header b/rt/html/Elements/Header index 02450b1e0..a32784e35 100644 --- a/rt/html/Elements/Header +++ b/rt/html/Elements/Header @@ -2,7 +2,7 @@ %# %# COPYRIGHT: %# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC +%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC %# <jesse@bestpractical.com> %# %# (Except where explicitly superseded by other copyright notices) @@ -24,7 +24,7 @@ %# along with this program; if not, write to the Free Software %# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA %# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html. +%# http://www.gnu.org/copyleft/gpl.html. %# %# %# CONTRIBUTION SUBMISSION POLICY: @@ -45,70 +45,24 @@ %# those contributions and any derivatives thereof. %# %# END BPS TAGGED BLOCK }}} -<!DOCTYPE html - PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" - "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> +<% include( '/elements/header.html', { + 'title' => $Title, + 'head' => $head, + 'nobr' => 1, + 'nocss' => 1, + }) |n +%> -<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"><head> - -<title><%$Title%></title> - -% if ($Refresh && $Refresh > 0) { - <meta http-equiv="refresh" content="<%$Refresh%>" /> -% } - -<link rel="shortcut icon" href="<%$RT::WebImagesURL%>/favicon.png" type="image/png" /> -<link rel="stylesheet" href="<%$RT::WebPath%>/NoAuth/css/<% $RT::WebDefaultStylesheet %>/main-squished.css" type="text/css" media="all" /> -<link rel="stylesheet" href="<%$RT::WebPath%>/NoAuth/css/print.css" type="text/css" media="print" /> - -% if ( $RSSAutoDiscovery ) { - <link rel="alternate" href="<%$RSSAutoDiscovery%>" type="application/rss+xml" title="RSS RT Search" /> -% } - -<script type="text/javascript" src="<%$RT::WebPath%>/NoAuth/js/util.js"></script> -<script type="text/javascript" src="<%$RT::WebPath%>/NoAuth/js/ahah.js"></script> -<script type="text/javascript" src="<%$RT::WebPath%>/NoAuth/js/titlebox-state.js"></script> -<script type="text/javascript"><!-- - onLoadHook("loadTitleBoxStates()"); -% if ( $Focus ) { - onLoadHook("focusElementById('<% $Focus %>')"); -% } -% if ( $onload ) { - onLoadHook("<% $onload |n %>"); -% } ---></script> - -<& /Elements/Callback, _CallbackName => 'Head', %ARGS &> - -</head> - <body<% $id && qq[ id="comp-$id"] |n %>> - -% if ($ShowBar) { -<& /Elements/Logo &> - -<div id="quickbar"> - <div id="quick-personal"> - <span class="hide"><a href="#skipnav"><&|/l&>Skip Menu</&></a> | </span> -% if ($session{'CurrentUser'}->Name) { - <&|/l, "<span>".$session{'CurrentUser'}->Name."</span>" &>Logged in as [_1]</&> -% if ($session{'CurrentUser'}->HasRight( Right => 'ModifySelf', Object => $RT::System )) { - | <a href="<%$RT::WebPath%><%$Prefs%>"><&|/l&>Preferences</&></a> -% } -% } else { - <&|/l&>Not logged in.</&> -% } - <& /Elements/Callback, %ARGS &> -% unless (!$session{'CurrentUser'}->Name -% or ($RT::WebExternalAuth and !$RT::WebFallbackToInternalAuth)) { - | <a href="<%$RT::WebPath%>/NoAuth/Logout.html<%$URL ? "?URL=".$URL : ''%>"><&|/l&>Logout</&></a> -% } - </div> -% } +%# if ($session{'CurrentUser'}->HasRight( Right => 'ModifySelf', Object => $RT::System )) { +%# | <a href="<%$RT::WebPath%><%$Prefs%>"><&|/l&>Preferences</&></a> +%# } <%INIT> $r->headers_out->{'Pragma'} = 'no-cache'; $r->headers_out->{'Cache-control'} = 'no-cache'; +require RT::URI::freeside; + my $id = $m->request_comp->path; $id =~ s|^/||g; $id =~ s|/|-|g; @@ -116,6 +70,45 @@ $id =~ s|\.html$||g; $id =~ s|index$||g if $id ne 'index'; $id =~ s|-$||g; + +my $head = ''; + +if ($Refresh && $Refresh > 0) { + $head .= '<meta http-equiv="refresh" content="$Refresh" />'; +} + +$head .= <<END; +<link rel="shortcut icon" href="$RT::WebImagesURL/favicon.png" type="image/png" /> +<link rel="stylesheet" href="$RT::WebPath/NoAuth/css/$RT::WebDefaultStylesheet/main-squished.css" type="text/css" media="all" /> +<link rel="stylesheet" href="$RT::WebPath/NoAuth/css/print.css" type="text/css" media="print" /> +END + +if ( $RSSAutoDiscovery ) { + $head .= qq(<link rel="alternate" href="$RSSAutoDiscovery" type="application/rss+xml" title="RSS RT Search" />); +} + +$head .= <<END; +<script type="text/javascript" src="$RT::WebPath/NoAuth/js/util.js"></script> +<script type="text/javascript" src="$RT::WebPath/NoAuth/js/ahah.js"></script> +<script type="text/javascript" src="$RT::WebPath/NoAuth/js/titlebox-state.js"></script> +<script type="text/javascript"><!-- + onLoadHook("loadTitleBoxStates()"); +END + +if ( $Focus ) { + $head .= qq{ onLoadHook("focusElementById('$Focus')");\n}; +} +if ( $onload ) { + $head .= qq{ onLoadHook("$onload");\n}; +} + +$head .= '--></script>'; + +$head .= $m->scomp( '/Elements/Callback', _CallbackName => 'Head', %ARGS ); + +my $etc = ''; +$etc .= qq[ id="comp-$id"] if $id; + </%INIT> <%ARGS> diff --git a/rt/html/Elements/Menu b/rt/html/Elements/Menu index 48fceebc0..b5b2bdad5 100644 --- a/rt/html/Elements/Menu +++ b/rt/html/Elements/Menu @@ -2,7 +2,7 @@ %# %# COPYRIGHT: %# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC +%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC %# <jesse@bestpractical.com> %# %# (Except where explicitly superseded by other copyright notices) @@ -24,7 +24,7 @@ %# along with this program; if not, write to the Free Software %# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA %# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html. +%# http://www.gnu.org/copyleft/gpl.html. %# %# %# CONTRIBUTION SUBMISSION POLICY: diff --git a/rt/html/Elements/PageLayout b/rt/html/Elements/PageLayout index 6897ede1a..b9d15e9d3 100644 --- a/rt/html/Elements/PageLayout +++ b/rt/html/Elements/PageLayout @@ -2,7 +2,7 @@ %# %# COPYRIGHT: %# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC +%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC %# <jesse@bestpractical.com> %# %# (Except where explicitly superseded by other copyright notices) @@ -24,7 +24,7 @@ %# along with this program; if not, write to the Free Software %# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA %# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html. +%# http://www.gnu.org/copyleft/gpl.html. %# %# %# CONTRIBUTION SUBMISSION POLICY: @@ -45,34 +45,116 @@ %# those contributions and any derivatives thereof. %# %# END BPS TAGGED BLOCK }}} - <div id="topactions"> -% foreach my $action (reverse sort keys %{$topactions}) { - <span class="topaction"> -% $m->out($topactions->{"$action"}->{'html'}); - </span> -% } - </div> +% #false laziness w/menubar.html... shouldn't these just go in freeside.css? +<style type="text/css"> +a.fsblackbutton { + background-color:#333333; + color: #ffffff; + border:1px solid; + border-top-color:#cccccc; + border-left-color:#cccccc; + border-right-color:#aaaaaa; + border-bottom-color:#aaaaaa; + /*font-weight:bold;*/ + /*padding-left:12px; + padding-right:12px;*/ + padding-left:4px; + padding-right:4px; + font-size:16px; + text-decoration:none; + overflow:visible; + filter:progid:DXImageTransform.Microsoft.Gradient(GradientType=0,StartColorStr='#ff333333',EndColorStr='#ff666666') +} -%# End of div#quickbar from /Elements/Header -</div> +a.fsblackbuttonselected, +a:link:hover.fsblackbutton, +a:visited:hover.fsblackbutton { + background-color:#7e0079; + color: #ffffff; + border:1px solid; + border-top-color:#cccccc; + border-left-color:#cccccc; + border-right-color:#aaaaaa; + border-bottom-color:#aaaaaa; + /*font-weight:bold;*/ + /*padding-left:12px; + padding-right:12px;*/ + padding-left:4px; + padding-right:4px; + font-size:16px; + text-decoration:none; + overflow:visible; + filter:progid:DXImageTransform.Microsoft.Gradient(GradientType=0,StartColorStr='#ff330033',EndColorStr='#ff7e0079') +} + +a.fsdarkbutton { + background-color:#555555; + color: #ffffff; + border:1px solid; + border-top-color:#cccccc; + border-left-color:#cccccc; + border-right-color:#aaaaaa; + border-bottom-color:#aaaaaa; + /*font-weight:bold;*/ + /*padding-left:12px; + padding-right:12px;*/ + padding-left:4px; + padding-right:4px; + font-size:16px; + text-decoration:none; + overflow:visible; + filter:progid:DXImageTransform.Microsoft.Gradient(GradientType=0,StartColorStr='#ff555555',EndColorStr='#ff666666') +} + +a.fsdarkbuttonselected, +a:link:hover.fsdarkbutton, +a:visited:hover.fsdarkbutton { + background-color:#7e0079; + color: #ffffff; + border:1px solid; + border-top-color:#cccccc; + border-left-color:#cccccc; + border-right-color:#aaaaaa; + border-bottom-color:#aaaaaa; + /*font-weight:bold;*/ + /*padding-left:12px; + padding-right:12px;*/ + padding-left:4px; + padding-right:4px; + font-size:16px; + text-decoration:none; + overflow:visible; + filter:progid:DXImageTransform.Microsoft.Gradient(GradientType=0,StartColorStr='#ff330033',EndColorStr='#ff7e0079') +} +</style> +<% include('/elements/init_calendar.html') |n %> +<table border=0 cellspacing=0 cellpadding=0 width="100%" height="100%"> + <TR HEIGHT="100%"> + <TD valign="top"> -% if ( $show_menu ) { +% if (0) { ##FREESIDE MENUS INSTEAD## if ( $show_menu ) { +%# if ( $show_menu ) { <div id="nav"> <& /Elements/Menu, toptabs => $toptabs, current_toptab => $current_toptab &> </div> % } -<div id="header"> - <h1><%$title%></h1> +%#already shown <h1><%$title%></h1> % my $sep = 0; % my $postsep = 0; % my $count = 0; % my $class = { }; % - <ul id="page-menu"<% (($actions && %$actions) || ($subactions && %$subactions)) && q[ class="actions-present"] | n %>> - <div><div><div> + + <TABLE BGCOLOR="#000000" BORDER=0 CELLSPACING=0 CELLPADDING=0> + <TR> + +%# <ul id="page-menu"<% (($actions && %$actions) || ($subactions && %$subactions)) && q[ class="actions-present"] | n %>> + % if ($page_tabs) { + <TD><IMG SRC="<%$fsurl%>images/gray-black-side.png" WIDTH=13 HEIGHT=25></TD> + <TD> % foreach my $tab (sort keys %{$page_tabs}) { % next if $tab =~ /^(?:current_toptab|this)$/; % $count++; @@ -100,22 +182,24 @@ % $class->{li} = join ' ', @li; % % - <li<% $class->{li} ? qq[ class="$class->{li}"] : ''|n %>><% $count > 1 && !$postsep && "· "|n%><a href="<%$RT::WebPath%>/<%$page_tabs->{$tab}->{'path'}%>"<%$class->{a}|n%><% $class->{a} ? ' name="focus"' : ''|n %>><% $page_tabs->{$tab}->{'title'} %></a></li> -% -% if ($sep) { - <li class="separator">···</li> -% } -% $postsep = $sep; + +%# <li<% $class->{li} ? qq[ class="$class->{li}"] : ''|n %>><% $count > 1 && !$postsep && "· "|n%><a href="<%$RT::WebPath%>/<%$page_tabs->{$tab}->{'path'}%>"<%$class->{a}|n%><% $class->{a} ? ' name="focus"' : ''|n %>><% $page_tabs->{$tab}->{'title'} %></a></li> + +% $class->{a} = $path eq $current ? ' class="fsblackbuttonselected"' : ' class="fsblackbutton"'; + <a href="<%$RT::WebPath%>/<%$page_tabs->{$tab}->{'path'}%>"<%$class->{a}|n%><% $class->{a} =~ 'selected' ? ' name="focus"' : ''|n %>><% $page_tabs->{$tab}->{'title'} %></a> + % } -% } else { - + </TD> +%# } else { +%# % } - </div></div></div> - </ul> % if (($actions && %$actions) || ($subactions && %$subactions)) { - <ul id="actions-menu"> - <div><div><div> + <TD><IMG SRC="<%$fsurl%>images/<% $page_tabs ? 'black-gray' : 'gray-black' %>-side.png" WIDTH=13 HEIGHT=25></TD> +% if ( $page_tabs ) { + <TD BGCOLOR="#333333"> </TD> +% } + <TD BGCOLOR="#333333"> % $sep = 0; % $postsep = 0; % $count = 0; @@ -141,24 +225,30 @@ % % $class->{li} = join ' ', @li; % - <li<% $class->{li} ? qq[ class="$class->{li}"] : ''|n %>><% $count > 1 && !$postsep && qq[<span class="bullet">· </span>]|n%> + +%# <li<% $class->{li} ? qq[ class="$class->{li}"] : ''|n %>><% $count > 1 && !$postsep && qq[<span class="bullet">· </span>]|n%> + +% #$class->{a} = $path eq $current ? ' class="fsblackbuttonselected"' : ' class="fsblackbutton"'; +% $type->{$action}->{class} ||= 'fsdarkbutton'; + % if ($type->{"$action"}->{'html'}) { <% $type->{"$action"}->{'html'} | n %> % } else { <a href="<%$RT::WebPath%>/<%$type->{$action}->{'path'}%>"<% $type->{$action}->{class} && ' class="'.$type->{$action}->{class}.'"' |n %><% $type->{$action}->{id} && ' id="'.$type->{$action}->{id}.'"' |n %>><%$type->{$action}->{'title'}%></a> % } - </li> -% if ($sep) { - <li class="separator">···</li> -% } -% $postsep = $sep; + % } % } % } - </div></div></div> - </ul> + + </TD> + % } -</div> + + <TD><IMG SRC="<%$fsurl%>images/black-gray-side.png" WIDTH=13 HEIGHT=25></TD> + </TR> +</TABLE> + <div id="body"> <& /Elements/Callback, _CallbackName => 'BeforeBody', %ARGS &> diff --git a/rt/html/Elements/QuickCreate b/rt/html/Elements/QuickCreate index 5669a4544..75b3a4598 100644 --- a/rt/html/Elements/QuickCreate +++ b/rt/html/Elements/QuickCreate @@ -2,7 +2,7 @@ %# %# COPYRIGHT: %# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC +%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC %# <jesse@bestpractical.com> %# %# (Except where explicitly superseded by other copyright notices) @@ -24,7 +24,7 @@ %# along with this program; if not, write to the Free Software %# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA %# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html. +%# http://www.gnu.org/copyleft/gpl.html. %# %# %# CONTRIBUTION SUBMISSION POLICY: @@ -47,11 +47,11 @@ %# END BPS TAGGED BLOCK }}} <div class="quick-create"> <&| /Widgets/TitleBox, title => loc('Quick ticket creation') &> -<form method="post" action="<%$RT::WebPath%>/index.html"> +<form method="post" action="<%$RT::WebPath%>/<% $RT::QuickCreateLong ? 'Ticket/Create.html' : 'index.html' %>"> <input type="hidden" class="hidden" name="QuickCreate" value="1" /> <table> <tr><td> -<&|/l&>Subject</&>:<br /><input size="15" name="Subject" /> +<&|/l&>Subject</&>:<br /><input size="30" name="Subject" /> </td><td> <&|/l&>Queue</&>:<br /><& /Elements/SelectNewTicketQueue, Name => 'Queue', ShowNullOption => 0 &> </td><td> diff --git a/rt/html/Elements/SelectDate b/rt/html/Elements/SelectDate index 5767074fb..23df246ce 100644 --- a/rt/html/Elements/SelectDate +++ b/rt/html/Elements/SelectDate @@ -2,7 +2,7 @@ %# %# COPYRIGHT: %# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC +%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC %# <jesse@bestpractical.com> %# %# (Except where explicitly superseded by other copyright notices) @@ -24,7 +24,7 @@ %# along with this program; if not, write to the Free Software %# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA %# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html. +%# http://www.gnu.org/copyleft/gpl.html. %# %# %# CONTRIBUTION SUBMISSION POLICY: @@ -45,10 +45,21 @@ %# those contributions and any derivatives thereof. %# %# END BPS TAGGED BLOCK }}} +%# in PageLayout instead, once <% include('/elements/init_calendar.html') |n %> +<input type="text" id="<% $Name %>" name="<% $Name %>" value="<% $Default %>" size="<% $Size %>" /> +<IMG SRC="<%$fsurl%>images/calendar.png" ID="<% $Name %>_date_button" STYLE="cursor: pointer" TITLE="Select date"> <script type="text/javascript"><!-- - onLoadHook('createCalendarLink("<% $Name %>");'); +Calendar.setup({ + inputField: "<%$Name%>", +% if ( defined($ShowTime) && $ShowTime ) { + ifFormat: "%Y-%m-%d %H:%M", + showsTime: true, +% } else { + ifFormat: "%Y-%m-%d", +% } + button: "<%$Name%>_date_button", +}); --></script> -<input type="text" id="<% $Name %>" name="<% $Name %>" value="<% $Default %>" size="<% $Size %>" /> <%init> unless ((defined $Default) or ($current <= 0)) { diff --git a/rt/html/Elements/ShadedBox b/rt/html/Elements/ShadedBox deleted file mode 100644 index 36b9cae7c..000000000 --- a/rt/html/Elements/ShadedBox +++ /dev/null @@ -1,33 +0,0 @@ -%# BEGIN LICENSE BLOCK -%# -%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com> -%# -%# (Except where explictly superceded by other copyright notices) -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# Unless otherwise specified, all modifications, corrections or -%# extensions to this work which alter its source code become the -%# property of Best Practical Solutions, LLC when submitted for -%# inclusion in the work. -%# -%# -%# END LICENSE BLOCK -<table> - <tr> - <td class="label"><%$title |n %>:</td> - <td class="value"><%$content |n %></td> - </tr> -</table> -<%ARGS> -$title => undef -$content => " " -</%ARGS> diff --git a/rt/html/Elements/ShadedInputRow b/rt/html/Elements/ShadedInputRow deleted file mode 100644 index e9fb69e5f..000000000 --- a/rt/html/Elements/ShadedInputRow +++ /dev/null @@ -1,35 +0,0 @@ -%# BEGIN LICENSE BLOCK -%# -%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com> -%# -%# (Except where explictly superceded by other copyright notices) -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# Unless otherwise specified, all modifications, corrections or -%# extensions to this work which alter its source code become the -%# property of Best Practical Solutions, LLC when submitted for -%# inclusion in the work. -%# -%# -%# END LICENSE BLOCK -<tr> - <td class="label"><%$title |n %>:</td> - <td class="value"> - <input name=<%$name%> value="<%$content|h%>" SIZE=<%$size%>> - </td> -</tr> -<%ARGS> -$title => undef -$content => " " -$name => undef -$size => undef -</%ARGS> diff --git a/rt/html/Elements/ShadedRow b/rt/html/Elements/ShadedRow deleted file mode 100644 index 8947fcd82..000000000 --- a/rt/html/Elements/ShadedRow +++ /dev/null @@ -1,31 +0,0 @@ -%# BEGIN LICENSE BLOCK -%# -%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com> -%# -%# (Except where explictly superceded by other copyright notices) -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# Unless otherwise specified, all modifications, corrections or -%# extensions to this work which alter its source code become the -%# property of Best Practical Solutions, LLC when submitted for -%# inclusion in the work. -%# -%# -%# END LICENSE BLOCK -<tr> - <td class="label"><%$title |n %>:</td> - <td class="value"><%$content |n %></td> -</tr> -<%ARGS> -$title => undef -$content => " " -</%ARGS> diff --git a/rt/html/Elements/SimpleSearch b/rt/html/Elements/SimpleSearch index 2876a2957..a4fd7e270 100644 --- a/rt/html/Elements/SimpleSearch +++ b/rt/html/Elements/SimpleSearch @@ -2,7 +2,7 @@ %# %# COPYRIGHT: %# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC +%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC %# <jesse@bestpractical.com> %# %# (Except where explicitly superseded by other copyright notices) @@ -24,7 +24,7 @@ %# along with this program; if not, write to the Free Software %# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA %# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html. +%# http://www.gnu.org/copyleft/gpl.html. %# %# %# CONTRIBUTION SUBMISSION POLICY: @@ -45,7 +45,14 @@ %# those contributions and any derivatives thereof. %# %# END BPS TAGGED BLOCK }}} -<form action="<% $RT::WebPath %>/Search/Simple.html"> - <input size="12" name="q" autocomplete="off" accesskey="0" class="field" /> - <input type="submit" class="button" value="<&|/l&>Search</&>" /> +<form action="<% $RT::WebPath %>/Search/Simple.html" STYLE="margin:0"> +<SCRIPT TYPE="text/javascript"> + function clearhint_search_ticket (what) { + if ( what.value == '(ticket # or subject string)' ) + what.value = ''; + } +</SCRIPT> +<input name="q" autocomplete="off" accesskey="0" class="field" VALUE="(ticket # or subject string)" onFocus="clearhint_search_ticket(this);" onClick="clearhint_search_ticket(this);" STYLE="text-align:right; font-family: Arial, Verdana, Helvetica, sans-serif;"><BR> +<A HREF="<% $RT::WebPath %>/Search/Build.html" STYLE="color: #ffffff; font-size: 70%; font-weight:normal">Advanced</A> +<input type="submit" class="fsblackbutton" value="<&|/l&>Search tickets</&>" onMouseOver="this.className='fsblackbuttonselected'; return true;" onMouseOut="this.className='fsblackbutton'; return true;" STYLE="font-size:70%;padding-left:2px;padding-right:2px"> </form> diff --git a/rt/html/Elements/Tabs b/rt/html/Elements/Tabs index 3b0f3da6d..36ecfa5a6 100644 --- a/rt/html/Elements/Tabs +++ b/rt/html/Elements/Tabs @@ -2,7 +2,7 @@ %# %# COPYRIGHT: %# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC +%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC %# <jesse@bestpractical.com> %# %# (Except where explicitly superseded by other copyright notices) @@ -24,7 +24,7 @@ %# along with this program; if not, write to the Free Software %# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA %# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html. +%# http://www.gnu.org/copyleft/gpl.html. %# %# %# CONTRIBUTION SUBMISSION POLICY: @@ -59,19 +59,18 @@ <a name="skipnav" id="skipnav" accesskey="8"></a> <%INIT> my $action; -my $basetopactions = { - A => { html => $m->scomp('/Elements/CreateTicket') - }, - B => { html => $m->scomp('/Elements/SimpleSearch') - } - }; -my $basetabs = { A => { title => loc('Homepage'), +my $basetabs = { + ' A'=> { title => 'Billing Main', + path => &RT::URI::freeside::FreesideURL(), + }, + A => { #title => loc('Homepage'), + title => 'Ticketing Main', path => '', }, - Ab => { title => loc('Simple Search'), + Ab => { title => loc('Simple Ticket Search'), path => 'Search/Simple.html' }, - B => { title => loc('Tickets'), + B => { title => loc('Adv. Ticket Search'), path => 'Search/Build.html' }, C => { title => loc('Tools'), @@ -99,9 +98,8 @@ if ($session{'CurrentUser'}->HasRight( Right => 'ModifySelf', if (!defined $toptabs) { $toptabs = $basetabs; } -if (!defined $topactions) { - $topactions = $basetopactions; -} + + require RT::URI::freeside; # Now let callbacks add their extra tabs $m->comp('/Elements/Callback', diff --git a/rt/html/Elements/TicketList b/rt/html/Elements/TicketList index 81e265d93..b36101e73 100644 --- a/rt/html/Elements/TicketList +++ b/rt/html/Elements/TicketList @@ -2,7 +2,7 @@ %# %# COPYRIGHT: %# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC +%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC %# <jesse@bestpractical.com> %# %# (Except where explicitly superseded by other copyright notices) @@ -24,7 +24,7 @@ %# along with this program; if not, write to the Free Software %# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA %# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html. +%# http://www.gnu.org/copyleft/gpl.html. %# %# %# CONTRIBUTION SUBMISSION POLICY: @@ -65,7 +65,8 @@ % while (my $record = $Collection->Next) { % $i++; % # Every ten rows, flush the buffer and put something on the page. -% $m->flush_buffer() unless ($i % 10); +% # hun, this flushes things out out-of-order for me on "RT at a glance"...? +% # $m->flush_buffer() unless ($i % 10); <& /Elements/CollectionAsTable/Row, Format => \@Format, i => $i, record => $record, maxitems => $maxitems &> % } diff --git a/rt/html/Elements/TitleBoxStart b/rt/html/Elements/TitleBoxStart index da04f8b7d..ba24fd92e 100644 --- a/rt/html/Elements/TitleBoxStart +++ b/rt/html/Elements/TitleBoxStart @@ -2,7 +2,7 @@ %# %# COPYRIGHT: %# -%# This software is Copyright (c) 1996-2009 Best Practical Solutions, LLC +%# This software is Copyright (c) 1996-2007 Best Practical Solutions, LLC %# <jesse@bestpractical.com> %# %# (Except where explicitly superseded by other copyright notices) @@ -24,7 +24,7 @@ %# along with this program; if not, write to the Free Software %# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA %# 02110-1301 or visit their web page on the internet at -%# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html. +%# http://www.gnu.org/copyleft/gpl.html. %# %# %# CONTRIBUTION SUBMISSION POLICY: diff --git a/rt/html/Elements/ViewUser b/rt/html/Elements/ViewUser deleted file mode 100644 index 657272496..000000000 --- a/rt/html/Elements/ViewUser +++ /dev/null @@ -1,51 +0,0 @@ -%# BEGIN LICENSE BLOCK -%# -%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com> -%# -%# (Except where explictly superceded by other copyright notices) -%# -%# This work is made available to you under the terms of Version 2 of -%# the GNU General Public License. A copy of that license should have -%# been provided with this software, but in any event can be snarfed -%# from www.gnu.org. -%# -%# This work is distributed in the hope that it will be useful, but -%# WITHOUT ANY WARRANTY; without even the implied warranty of -%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -%# General Public License for more details. -%# -%# Unless otherwise specified, all modifications, corrections or -%# extensions to this work which alter its source code become the -%# property of Best Practical Solutions, LLC when submitted for -%# inclusion in the work. -%# -%# -%# END LICENSE BLOCK -<& /Elements/TitleBoxStart, - title => "<a class='inverse' href=\"$RT::WebPath/Search/Listing.html?LimitRequestorById=1&IdOfRequestor=".$User->id."\">".loc("Tickets from [_1]", $name)."</a>", - titleright=> "<a class='inverse' href=\"$RT::WebPath/EditUserComments.html?id=".$User->id."\">".loc("Comments about [_1]", $name)."</a>" &> -<TABLE WIDTH="100%"> -<tr> -<td halign=left valign=top> -%while (my $w=$tickets->Next) { -<%$w->Id%>: <a href="<%$RT::WebPath%>/Ticket/Display.html?id=<%$w->id%>"><%$w->Subject%></a> (<%$w->Status%>)<BR> -%} -</td> -<td align=right valign=top> - <% ($User->Comments || loc("No comment entered about this user")) %> -</tr> -</table> -<& /Elements/TitleBoxEnd &> - -<%ARGS> -$User=>undef -</%ARGS> - -<%INIT> -my $name=$User->RealName || $User->EmailAddress; - -my $tickets = new RT::Tickets($session{'CurrentUser'}); -$tickets->LimitWatcher(TYPE => 'Requestor', VALUE => $User->EmailAddress); - - -</%INIT> |