torrus , RT#10574
[freeside.git] / httemplate / elements / menu.html
index cc52aae..ec176c9 100644 (file)
@@ -190,6 +190,11 @@ foreach my $svcdb ( FS::part_svc->svc_tables() ) {
       [ $fsurl."search/report_$svcdb.html", '' ];
   }
 
+  if ( $svcdb eq 'svc_phone' ) {
+    $report_svc{"Phone number (DID) availability"} =
+      [ $fsurl."search/report_phone_avail.html", '' ];
+  }
+
   $report_services{$name} = [ \%report_svc, $longname ];
 
 }
@@ -224,6 +229,7 @@ tie my %report_rating, 'Tie::IxHash',
   'RADIUS sessions' => [ $fsurl.'search/sqlradius.html', '' ],
   'Call Detail Records (CDRs)' => [ $fsurl.'search/report_cdr.html', '' ],
   'Time worked' => [ $fsurl.'search/report_rt_transaction.html', '' ],
+  'Time worked summary' => [ $fsurl.'search/report_rt_ticket.html', '' ],
 ;
 
 tie my %report_ticketing_statistics, 'Tie::IxHash',
@@ -418,6 +424,9 @@ tie my %config_cust, 'Tie::IxHash',
   'Customer classes'    =>  [ $fsurl.'browse/cust_class.html', 'Customer classes define groups of customers for reporting.' ],
   'Customer categories' =>  [ $fsurl.'browse/cust_category.html', 'Customer categories define groups of customer classes.' ],
 ;
+  
+$config_cust{'Customer note classes'} = [ $fsurl.'browse/cust_note_class.html', 'Customer note classes define groups of notes for reporting.' ]
+    if ($conf->exists('note-classes') && $conf->config('note-classes') > 0);
 
 tie my %config_agent, 'Tie::IxHash',
   'Agent types' => [ $fsurl.'browse/agent_type.cgi', 'Agent types define groups of package definitions that you can then assign to particular agents' ],
@@ -548,15 +557,29 @@ eval "use RT;"
 tie my %help_menu, 'Tie::IxHash', 'Billing documentation' => [ $doc_link, 'Freeside documentation' ];
 $help_menu{'Ticketing documentation'} = [ 'http://wiki.bestpractical.com/', 'Request Tracker Wiki' ]
   if $conf->config('ticket_system') eq 'RT_Internal';
+$help_menu{'Networking monitoring documentation'} = [ 'http://torrus.org/userguide.pod.html', 'Torrus User Guide' ]
+  if $conf->config('network_monitoring_system') eq 'Torrus_Internal';
 $help_menu{'separator'} = '';
 $help_menu{"About Freeside v$FS::VERSION"} = [ "javascript:about_freeside()", '' ];
 $help_menu{"About RT v$RT::VERSION"} = [ 'http://www.bestpractical.com/rt', 'Request Tracker Homepage' ]
   if $conf->config('ticket_system') eq 'RT_Internal';
+$help_menu{"About Torrus v1.0.9"} = [ 'http://www.torrus.org/', 'Torrus Homepage' ] #XXX manual version
+  if $conf->config('network_monitoring_system') eq 'Torrus_Internal';
 
 
-tie my %menu, 'Tie::IxHash',
-  'Billing Main'   => [ $fsurl, 'Billing start page', ],
-;
+tie my %menu, 'Tie::IxHash';
+
+if ( $conf->config('menu-prepend_links')) {
+  my @links = split(/\n/, $conf->config('menu-prepend_links'));
+  foreach my $link (@links) {
+    $link =~ /^\s*(\S+)\s+(.*?)(\s*\(([^\)]*)\))?$/ or next;
+    my($url, $label, $alt) = ($1, $2, $4);
+    $menu{$label} = [ $url, $alt ];
+  }
+}
+
+$menu{'Billing Main'} = [ $fsurl, 'Billing start page', ];
+
 if ( $conf->config('ticket_system') ) {
   $menu{'Ticketing Main'} =
     [ 
@@ -567,6 +590,12 @@ if ( $conf->config('ticket_system') ) {
       'Ticketing start page',
     ],
 }
+
+if ( $conf->config('network_monitoring_system') eq 'Torrus_Internal' ) {
+  $menu{'Network Main'} =
+    [ $fsurl.'torrus/main', 'Network monitoring start page' ],
+}
+
 $menu{'New prospect'} = [ $fsurl.'edit/prospect_main.html', 'Add a new prospect' ]
   if $curuser->access_right('New prospect');
 $menu{'New customer'} = [ $fsurl.'edit/cust_main.cgi', 'Add a new customer' ]