index.php 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. <?php
  2. if ((cfr('REPORTFINANCE')) AND (cfr('PAYFIND'))) {
  3. $altcfg=$ubillingConfig->getAlter();
  4. if ($altcfg['AGENTS_ASSIGN']==2) {
  5. $assignReport=new agentAssignReport();
  6. //html print export
  7. if (wf_CheckGet(array('exporthtmlagentid'))) {
  8. $assignReport->exportHtml($_GET['exporthtmlagentid']);
  9. }
  10. //CSV data export
  11. if (wf_CheckGet(array('exportcsvagentid'))) {
  12. $assignReport->exportCSV($_GET['exportcsvagentid']);
  13. }
  14. //CSV data export short printable
  15. if (wf_CheckGet(array('exportcsvagentidshort'))) {
  16. $assignReport->exportCSV2($_GET['exportcsvagentidshort']);
  17. }
  18. //show search form
  19. show_window(__('Payment search'),$assignReport->paymentSearchForm());
  20. show_window('', wf_BackLink('?module=report_finance'));
  21. //do the search and display results
  22. if (wf_CheckPost(array('datefrom','dateto','dosearch','cashtypeid'))) {
  23. show_window(__('Search results'),$assignReport->paymentSearch($_POST['datefrom'], $_POST['dateto'],$_POST['cashtypeid']));
  24. }
  25. } else {
  26. show_error(__('This module is disabled'));
  27. }
  28. } else {
  29. show_error(__('Access denied'));
  30. }
  31. ?>