[freeside-commits] freeside/httemplate/browse part_export.cgi, 1.6, 1.7
Ivan,,,
ivan at wavetail.420.am
Tue Aug 14 20:26:15 PDT 2007
Update of /home/cvs/cvsroot/freeside/httemplate/browse
In directory wavetail:/tmp/cvs-serv28553
Modified Files:
part_export.cgi
Log Message:
little more low-hanging fruit: table-grid the export listing
Index: part_export.cgi
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/browse/part_export.cgi,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- part_export.cgi 30 Jan 2007 20:59:13 -0000 1.6
+++ part_export.cgi 15 Aug 2007 03:26:12 -0000 1.7
@@ -1,6 +1,9 @@
-<% include("/elements/header.html","Export Listing", menubar( 'Main Menu' => "$p#sysadmin" )) %>
+<% include("/elements/header.html", "Export Listing") %>
+
Provisioning services to external machines, databases and APIs.<BR><BR>
+
<A HREF="<% $p %>edit/part_export.cgi"><I>Add a new export</I></A><BR><BR>
+
<SCRIPT>
function part_export_areyousure(href) {
if (confirm("Are you sure you want to delete this export?") == true)
@@ -8,36 +11,54 @@
}
</SCRIPT>
-<% table() %>
+<% include('/elements/table-grid.html') %>
+% my $bgcolor1 = '#eeeeee';
+% my $bgcolor2 = '#ffffff';
+% my $bgcolor = '';
+
<TR>
- <TH COLSPAN=2>Export</TH>
- <TH>Options</TH>
+ <TH COLSPAN=2 CLASS="grid" BGCOLOR="#cccccc">Export</TH>
+ <TH CLASS="grid" BGCOLOR="#cccccc">Options</TH>
</TR>
+
% foreach my $part_export ( sort {
% $a->getfield('exportnum') <=> $b->getfield('exportnum')
-% } qsearch('part_export',{}) ) {
-%
+% } qsearch('part_export',{})
+% ) {
+% if ( $bgcolor eq $bgcolor1 ) {
+% $bgcolor = $bgcolor2;
+% } else {
+% $bgcolor = $bgcolor1;
+% }
- <TR>
- <TD><A HREF="<% $p %>edit/part_export.cgi?<% $part_export->exportnum %>"><% $part_export->exportnum %></A></TD>
- <TD><% $part_export->exporttype %> to <% $part_export->machine %> (<A HREF="<% $p %>edit/part_export.cgi?<% $part_export->exportnum %>">edit</A> | <A HREF="javascript:part_export_areyousure('<% $p %>misc/delete-part_export.cgi?<% $part_export->exportnum %>')">delete</A>)</TD>
- <TD>
- <% itable() %>
-% my %opt = $part_export->options;
+ <TR>
+
+ <TD CLASS="grid" BGCOLOR="<% $bgcolor %>"><A HREF="<% $p %>edit/part_export.cgi?<% $part_export->exportnum %>"><% $part_export->exportnum %></A></TD>
+
+ <TD CLASS="grid" BGCOLOR="<% $bgcolor %>"><% $part_export->exporttype %> to <% $part_export->machine %> (<A HREF="<% $p %>edit/part_export.cgi?<% $part_export->exportnum %>">edit</A> | <A HREF="javascript:part_export_areyousure('<% $p %>misc/delete-part_export.cgi?<% $part_export->exportnum %>')">delete</A>)</TD>
+
+ <TD CLASS="inv" BGCOLOR="<% $bgcolor %>">
+ <% itable() %>
+% my %opt = $part_export->options;
% foreach my $opt ( keys %opt ) {
+
+ <TR>
+ <TD ALIGN="right" VALIGN="top" WIDTH="33%"><% $opt %>: </TD>
+ <TD ALIGN="left" WIDTH="67%"><% encode_entities($opt{$opt}) %></TD>
+ </TR>
+% }
+
+ </TABLE>
+ </TD>
- <TR><TD><% $opt %></TD><TD><% encode_entities($opt{$opt}) %></TD></TR>
-% }
+ </TR>
- </TABLE>
- </TD>
- </TR>
% }
-
</TABLE>
-</BODY>
-</HTML>
+
+<% include('/elements/footer.html') %>
+
<%init>
die "access denied"
unless $FS::CurrentUser::CurrentUser->access_right('Configuration');
More information about the freeside-commits
mailing list