minor tyop
[freeside.git] / httemplate / elements / menu.html
index 80a664c..328e24a 100644 (file)
@@ -51,8 +51,9 @@ tie my %report_customers_lists, 'Tie::IxHash',
   'by customer number' => [ $fsurl. 'search/cust_main.cgi?browse=custnum', '' ],
   'by last name' => [ $fsurl. 'search/cust_main.cgi?browse=last', '' ],
   'by company name' => [ $fsurl. 'search/cust_main.cgi?browse=company', '' ],
-  'by active trouble tickets' => [ $fsurl. 'search/cust_main.cgi?browse=tickets', '' ],
 ;
+$report_customers_lists{'by active trouble tickets'} = [ $fsurl. 'search/cust_main.cgi?browse=tickets', '' ]
+  if $conf->config('ticket_system');
 
 tie my %report_customers_search, 'Tie::IxHash',
   'by ordering employee' => [ $fsurl. 'search/cust_main-otaker.cgi' ],
@@ -83,7 +84,7 @@ tie my %report_services_acct, 'Tie::IxHash',
   'All accounts by username' => [ $fsurl.'search/svc_acct.cgi?username', '' ],
   'All accounts by UID'      => [ $fsurl.'search/svc_acct.cgi?uid', '' ],
 ;
-$report_services_acct{'Unlinked accounts'} = [ $fsurl.'search/svc_acct.cgi?UN_uid', 'Pre-Freeside accounts without a customer record' ]
+$report_services_acct{'Unlinked accounts'} = [ $fsurl.'search/svc_acct.cgi?UN_username', 'Pre-Freeside accounts without a customer record' ]
   if $curuser->access_right('View/link unlinked services');
 
 tie my %report_services_domain, 'Tie::IxHash',
@@ -106,7 +107,7 @@ $report_services_www{'Unlinked virtual hosts'} = [ $fsurl.'search/svc_www.cgi?UN
 
 tie my %report_services_broadband, 'Tie::IxHash',
   'All broadband services' => [ $fsurl.'search/svc_broadband.cgi?svcnum', '' ],
-  #'Unlinked domain' => [ $fsurl.'search/svc_acct.cgi?UN_uid', 'Pre-Freeside domains without a customer record' ],
+  #'Unlinked domain' => [ $fsurl.'search/svc_acct.cgi?UN_uid', 'Pre-Freeside broadband services without a customer record' ],
 ;
 
 tie my %report_services_phone, 'Tie::IxHash',
@@ -116,7 +117,7 @@ tie my %report_services_phone, 'Tie::IxHash',
 tie my %report_services_external, 'Tie::IxHash',
   'All external services' => [ $fsurl.'search/svc_external.cgi?id', '' ],
 ;
-$report_services_external{'Unlinked external services'} = [ $fsurl.'search/svc_external.cgi?UN_id', 'Pre-Freeside domains without a customer record' ]
+$report_services_external{'Unlinked external services'} = [ $fsurl.'search/svc_external.cgi?UN_id', 'Pre-Freeside external services without a customer record' ]
   if $curuser->access_right('View/link unlinked services');
 
 tie my %report_services, 'Tie::IxHash';
@@ -143,6 +144,7 @@ $report_packages{'Customer packages with unconfigured services'} =  [ $fsurl.'se
 $report_packages{'Advanced package reports'} =  [ $fsurl.'search/report_cust_pkg.html', 'by agent, date range, status, package definition' ];
 
 tie my %report_rating, 'Tie::IxHash',
+  'RADIUS sessions' => [ $fsurl.'search/sqlradius.html', '' ],
   'Call Detail Records (CDRs)' => [ $fsurl.'search/report_cdr.html', '' ],
 ;
 
@@ -155,10 +157,13 @@ tie my %report_financial, 'Tie::IxHash',
   'Sales, Credits and Receipts' => [ $fsurl.'graph/report_money_time.html', 'Sales, credits and receipts summary graph' ],
   'Sales Report' => [ $fsurl.'graph/report_cust_bill_pkg.html', 'Sales report and graph (by agent, package class and/or date range)' ],
   'Credit Report' => [ $fsurl.'search/report_cust_credit.html', 'Credit report (by employee and/or date range)' ],
-  'Payment Report' => [ $fsurl.'search/report_cust_pay.html', 'Credit report (by type and/or date range)' ],
-  'A/R Aging' => [ $fsurl.'search/report_receivables.html', 'Accounts Receivable Aging report' ],
-  'Prepaid Income' => [ $fsurl.'search/report_prepaid_income.html', 'Prepaid income (unearned revenue)  report' ],
-  'Sales Tax Liability' => [ $fsurl.'search/report_tax.html', 'Sales tax liability report' ],
+  'Payment Report' => [ $fsurl.'search/report_cust_pay.html', 'Payment report (by type and/or date range)' ],
+;
+$report_financial{'Payment Batch Report'} = [ $fsurl.'search/pay_batch.html', 'Payment batches (by status and/or date range)' ]
+  if $conf->exists('batch-enable');
+$report_financial{'A/R Aging'} = [ $fsurl.'search/report_receivables.html', 'Accounts Receivable Aging report' ];
+$report_financial{'Prepaid Income'} = [ $fsurl.'search/report_prepaid_income.html', 'Prepaid income (unearned revenue)  report' ];
+$report_financial{'Sales Tax Liability'} = [ $fsurl.'search/report_tax.html', 'Sales tax liability report' ];
 ;
 
 tie my %report_menu, 'Tie::IxHash';
@@ -170,7 +175,7 @@ $report_menu{'Packages'}    =  [ \%report_packages,  'Package reports'   ]
   if $curuser->access_right('List packages');
 $report_menu{'Services'}    =  [ \%report_services,  'Services reports'  ]
   if $curuser->access_right('List services');
-$report_menu{'Rating data'} =  [ \%report_rating,    'Rating reports'  ]
+$report_menu{'Usage'} =  [ \%report_rating,    'Usage reports'  ]
   if $curuser->access_right('List rating data');
 $report_menu{'Billing events'} =  [ \%report_bill_event, 'Billing events' ]
   if $curuser->access_right('Billing event reports');
@@ -195,6 +200,8 @@ tie my %tools_exporting, 'Tie::IxHash',
 tie my %tools_menu, 'Tie::IxHash', ();
 $tools_menu{'Quick payment entry'} =  [ $fsurl.'misc/batch-cust_pay.html', 'Enter multiple payments in a batch' ]
   if $curuser->access_right('Post payment batch');
+$tools_menu{'Process payment batches'} = [ $fsurl.'search/pay_batch.cgi?magic=_date;open=1;intransit=1', 'Process credit card and electronic check batches' ]
+  if $conf->exists('batch-enable') && $curuser->access_right('Process batches');
 $tools_menu{'Job Queue'} =  [ $fsurl.'search/queue.html', 'View pending job queue' ]
   if $curuser->access_right('Job queue');
 $tools_menu{'Importing'} =  [ \%tools_importing, 'Import tools' ]
@@ -208,10 +215,14 @@ tie my %config_employees, 'Tie::IxHash',
 ;
 
 tie my %config_export_svc_pkg, 'Tie::IxHash',
-  'View/Edit exports'             => [ $fsurl.'browse/part_export.cgi', 'Provisioning services to external machines, databases and APIs' ],
-  'View/Edit service definitions' => [ $fsurl.'browse/part_svc.cgi', 'Services are items you offer to your customers' ],
-  'View/Edit package definitions' => [ $fsurl.'browse/part_pkg.cgi', 'One or more services are grouped together into a package and given pricing information. Customers purchase packages, not services' ],
-  'View/Edit package classes'     => [ $fsurl.'browse/pkg_class.html', 'Package classes define groups of packages, for reporting and convenience purposes.' ],
+  'View/Edit exports'              => [ $fsurl.'browse/part_export.cgi', 'Provisioning services to external machines, databases and APIs' ],
+  'View/Edit service definitions'  => [ $fsurl.'browse/part_svc.cgi', 'Services are items you offer to your customers' ],
+  'View/Edit package definitions'  => [ $fsurl.'browse/part_pkg.cgi', 'One or more services are grouped together into a package and given pricing information. Customers purchase packages, not services' ],
+  'View/Edit package classes'      => [ $fsurl.'browse/pkg_class.html', 'Package classes define groups of packages, for reporting and convenience purposes.' ],
+  'View/Edit cancel reason types'  => [ $fsurl.'browse/reason_type.html?class=C', 'Cancel reason types define groups of reasons, for reporting and convenience purposes.' ],
+  'View/Edit cancel reasons'       => [ $fsurl.'browse/reason.html?class=C', 'Cancel reasons explain why a service was cancelled.' ],
+  'View/Edit suspend reason types' => [ $fsurl.'browse/reason_type.html?class=S', 'Suspend reason types define groups of reasons, for reporting and convenience purposes.' ],
+  'View/Edit suspend reasons' => [ $fsurl.'browse/reason.html?class=S', 'Suspend reasons explain why a service was suspended.' ],
 ;
 
 tie my %config_agent, 'Tie::IxHash',
@@ -269,14 +280,17 @@ $config_menu{'Miscellaneous'} = [ \%config_misc, ''    ]
 
 tie my %menu, 'Tie::IxHash',
   'Billing Main'   => [ $fsurl, 'Billing start page', ],
-  'Ticketing Main' => [ 
-                        ( $conf->config('ticket_system') eq 'RT_External'
-                          ? FS::TicketSystem->baseurl()
-                          : $fsurl.'rt/'
-                        ),
-                        'Ticketing start page',
-                      ],
 ;
+if ( $conf->config('ticket_system') ) {
+  $menu{'Ticketing Main'} =
+    [ 
+      ( $conf->config('ticket_system') eq 'RT_External'
+        ? FS::TicketSystem->baseurl()
+        : $fsurl.'rt/'
+      ),
+      'Ticketing start page',
+    ],
+}
 $menu{'Reports'} = [ \%report_menu, 'Lists, reporting and graphing' ]
   if keys %report_menu;
 $menu{'Tools'} = [ \%tools_menu, 'Tools' ]
@@ -326,7 +340,7 @@ sub submenu {
 
     } keys %$submenu )
   ). "\n".
-  "myMenu$menunum.width = 224\n",
+  "myMenu$menunum.width = 224;\n",
 
   "myMenu$menunum";