1 <%= header('Edit Configuration', menubar( 'Main Menu' => $p ) ) %>
3 <% my $conf = new FS::Conf; my @config_items = $conf->config_items; %>
5 <form action="config-process.cgi">
7 <% foreach my $section ( qw(required billing username password UI session
10 '', 'depreciated') { %>
11 <%= table("#cccccc", 2) %>
13 <th colspan="2" bgcolor="#dcdcdc">
14 <%= ucfirst($section || 'unclassified') %> configuration options
17 <% foreach my $i (grep $_->section eq $section, @config_items) { %>
21 foreach my $type ( ref($i->type) ? @{$i->type} : $i->type ) {
22 #warn $i->key unless defined($type);
24 <% if ( $type eq '' ) { %>
25 <font color="#ff0000">no type</font>
26 <% } elsif ( $type eq 'textarea' ) { %>
27 <textarea name="<%= $i->key. $n %>" rows=5><%= join("\n", $conf->config($i->key) ) %></textarea>
28 <% } elsif ( $type eq 'checkbox' ) { %>
29 <input name="<%= $i->key. $n %>" type="checkbox" value="1"<%= $conf->exists($i->key) ? ' CHECKED' : '' %>>
30 <% } elsif ( $type eq 'text' ) { %>
31 <input name="<%= $i->key. $n %>" type="<%= $type %>" value="<%= $conf->exists($i->key) ? $conf->config($i->key) : '' %>">
33 <font color="#ff0000">unknown type <%= $type %></font>
37 <td><a name="<%= $i->key %>">
38 <b><%= $i->key %></b> - <%= $i->description %>
45 <input type="submit" value="Apply changes">