2 <%= header('View Configuration', menubar( 'Main Menu' => $p,
3 'Edit Configuration' => 'config.cgi' ) ) %>
5 <% my $conf = new FS::Conf; my @config_items = $conf->config_items; %>
7 <% foreach my $section ( qw(required billing username password UI session
10 '', 'deprecated') { %>
11 <A NAME="<%= $section || 'unclassified' %>"></A>
13 <% foreach my $nav_section ( qw(required billing username password UI session
16 '', 'deprecated') { %>
17 <% if ( $section eq $nav_section ) { %>
18 [<A NAME="not<%= $nav_section || 'unclassified' %>" style="background-color: #cccccc"><%= ucfirst($nav_section || 'unclassified') %></A>]
20 [<A HREF="#<%= $nav_section || 'unclassified' %>"><%= ucfirst($nav_section || 'unclassified') %></A>]
24 <%= table("#cccccc", 2) %>
26 <th colspan="2" bgcolor="#dcdcdc">
27 <%= ucfirst($section || 'unclassified') %> configuration options
30 <% foreach my $i (grep $_->section eq $section, @config_items) { %>
32 <td><a name="<%= $i->key %>">
33 <b><%= $i->key %></b> - <%= $i->description %>
36 <% foreach my $type ( ref($i->type) ? @{$i->type} : $i->type ) {
38 <% if ( $type eq '' ) { %>
40 <td><font color="#ff0000">no type</font></td>
42 <% } elsif ( $type eq 'textarea'
43 || $type eq 'editlist'
44 || $type eq 'selectmultiple' ) { %>
46 <td bgcolor="#ffffff">
48 <%= encode_entities(join("\n", $conf->config($i->key) ) ) %>
52 <% } elsif ( $type eq 'checkbox' ) { %>
54 <td bgcolor="#<%= $conf->exists($i->key) ? '00ff00">YES' : 'ff0000">NO' %></td>
56 <% } elsif ( $type eq 'text' || $type eq 'select' ) { %>
58 <td bgcolor="#ffffff">
59 <%= $conf->exists($i->key) ? $conf->config($i->key) : '' %>
61 <% } elsif ( $type eq 'select-sub' ) { %>
63 <td bgcolor="#ffffff">
64 <%= $conf->config($i->key) %>:
65 <%= &{ $i->option_sub }( $conf->config($i->key) ) %>
70 <font color="#ff0000">unknown type <%= $type %></font>