X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fconfig%2Fconfig-view.cgi;h=7516dabab4bf9c64e65800f3ec3583e8d4aa58b0;hb=b5c4237a34aef94976bc343c8d9e138664fc3984;hp=9e9e64eb2c7b4e410e8893c1a197f2d0031cd88d;hpb=44a63e5978af2b5b4e00cabbc4b3541df4144305;p=freeside.git
diff --git a/httemplate/config/config-view.cgi b/httemplate/config/config-view.cgi
index 9e9e64eb2..7516dabab 100644
--- a/httemplate/config/config-view.cgi
+++ b/httemplate/config/config-view.cgi
@@ -43,12 +43,16 @@ Click on a configuration value to change it.
- <% ucfirst($section || 'unclassified') %> configuration options
+ <% ucfirst($section || 'unclassified') %>
+% if ( $curuser->option('show_confitem_counts') ) {
+ (<% scalar( @{ $section_items{$section} } ) %> items)
+% }
|
% foreach my $i (@{ $section_items{$section} }) {
% my @types = ref($i->type) ? @{$i->type} : ($i->type);
-% my( $width, $height ) = ( 522, 336 );
+%# my( $width, $height ) = ( 522, 336 );
+% my( $width, $height ) = ( 600, 336 );
% if ( grep $_ eq 'textarea', @types ) {
% #800x600
% $width = 763;
@@ -66,7 +70,7 @@ Click on a configuration value to change it.
% @agents = ( '' );
% if ( $i->per_agent ) {
% foreach my $agent (@all_agents) {
-% if ( defined(_config_agentonly($conf, $i->key, $agent->agentnum)) ) {
+% if ( defined($conf->conf( $i->key, $agent->agentnum, 1 ) ) ) {
% push @agents, $agent;
% } else {
% push @add_agents, $agent;
@@ -99,15 +103,14 @@ Click on a configuration value to change it.
)
%>: <% $i->description %>
% if ( $agent && $cgi->param('showagent') ) {
-% my $confnum =
-% _config_agentonly($conf, $i->key, $agent->agentnum)->confnum;
+% my $confnum = $conf->conf( $i->key, $agent->agentnum, 1 )->confnum;
(delete agent override)
% } elsif ( $i->base_key
% || ( $deleteable{$i->key} && $conf->exists($i->key) ) ) {
% my $confnum =
% $agent
-% ? _config_agentonly($conf, $i->key, $agent->agentnum)->confnum
-% : $conf->_config( $i->key )->confnum;
+% ? $conf->conf( $i->key, $agent->agentnum, 1 )->confnum
+% : $conf->conf( $i->key )->confnum;
% my $showagent = $cgi->param('showagent') ? '_showagent' : '';
(delete configuration item)
% }
@@ -157,7 +160,9 @@ Click on a configuration value to change it.
% } elsif ( $type eq 'textarea'
% || $type eq 'editlist'
-% || $type eq 'selectmultiple' ) {
+% || $type eq 'selectmultiple'
+% )
+% {
@@ -198,7 +203,7 @@ Click on a configuration value to change it.
|
-% } elsif ( $type eq 'select-sub' ) {
+% } elsif ( $type eq 'select-sub' ) {
@@ -207,12 +212,33 @@ Click on a configuration value to change it.
|
-% } else {
+% } elsif ( $type =~ /^select-(part_svc|part_pkg|pkg_class)$/ ) {
+%
+% my $table = $1;
+% my $namecol = $namecol{$table};
+% my $pkey = dbdef->table($table)->primary_key;
+%
+% my @keys = $conf->config($i->key, $agentnum);
+
+
+
+ <% join( ' ',
+ map {
+ my $key = $_;
+ my $record = qsearchs($table, { $pkey => $key });
+ $record ? "$key: ".$record->$namecol() : $key;
+ } @keys
+ )
+ %>
+ |
+
+
+% } else {
unknown type <% $type %>
|
-% }
+% }
% $n++;
% }
@@ -287,21 +313,18 @@ Click on a configuration value to change it.