report.html.php 3.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. <?php
  2. /**
  3. * The report view file of flow module of ZDOO.
  4. *
  5. * @copyright Copyright 2009-2020 禅道软件(青岛)有限公司(ZenTao Software (Qingdao) Co., Ltd. www.cnezsoft.com)
  6. * @license ZPL(http://zpl.pub/page/zplv12.html) or AGPL(https://www.gnu.org/licenses/agpl-3.0.en.html)
  7. * @author Dongdong Jia <jiadongdong@easycorp.ltd>
  8. * @package flow
  9. * @version $Id$
  10. * @link http://www.zdoo.com
  11. */
  12. ?>
  13. <?php include $app->getModuleRoot() . 'common/view/header.html.php';?>
  14. <?php js::set('moduleName', $flow->module);?>
  15. <?php js::set('buildin', $flow->buildin);?>
  16. <div class='main-row'>
  17. <div class='side-col col-3'>
  18. <div class='panel panel-sm'>
  19. <div class='panel-heading'><strong><?php echo $lang->workflowreport->select;?></strong></div>
  20. <div class='panel-body'>
  21. <form method='post' action='<?php echo $this->createLink($flow->module, 'report');?>'>
  22. <?php echo html::checkBox('reports', $reportPairs, $checkedReports, '', 'block');?>
  23. <p><?php echo html::selectAll() . html::submitButton($lang->workflowreport->generate);?></p>
  24. </form>
  25. </div>
  26. </div>
  27. </div>
  28. <div class='main-col col-9'>
  29. <div class='panel panel-sm'>
  30. <div class='panel-heading'>
  31. <strong><?php echo $lang->workflowreport->report;?></strong>
  32. <span class='text-warning'><?php echo $lang->workflowreport->tips->source;?></span>
  33. </div>
  34. <table class='table active-disabled'>
  35. <?php foreach($charts as $chart):?>
  36. <?php $canvasID = "chart-{$chart->id}";?>
  37. <tr class='text-top'>
  38. <td>
  39. <div class='chart-wrapper text-center' style="position: relative;">
  40. <h5><?php echo $chart->name;?></h5>
  41. <div class='chart-canvas'>
  42. <?php if($chart->type != 'pie'):?>
  43. <div class="legend <?php echo $chart->type;?>-legend"></div>
  44. <?php endif;?>
  45. <canvas id='<?php echo $canvasID;?>' data-type='<?php echo $chart->type;?>' data-legend='<?php echo $chart->legend;?>' data-displaytype='<?php echo $chart->displayType;?>' width='<?php echo $config->flow->report->width;?>' height='<?php echo $config->flow->report->height;?>' data-responsive='true'></canvas>
  46. </div>
  47. <?php if($chart->type == 'pie'):?>
  48. <div class="legend pie-legend scrollbar-hover"></div>
  49. <?php endif;?>
  50. </div>
  51. <div class='side-col col-xl hidden'>
  52. <div style="overflow:auto;" class='table-wrapper'>
  53. <table class='table table-condensed table-hover table-striped table-bordered table-chart' data-chart='<?php echo $chart->type; ?>' data-target='#<?php echo $canvasID?>' data-animation='false'>
  54. <?php foreach($chartData[$canvasID] as $key => $data):?>
  55. <tr>
  56. <td class='chart-color'><i class='chart-color-dot'></i></td>
  57. <td class='chart-label text-left' title='<?php echo $data->label;?>'><?php echo $data->label;?></td>
  58. <td class='chart-value text-right'><?php echo $data->value;?></td>
  59. </tr>
  60. <?php endforeach;?>
  61. </table>
  62. </div>
  63. </div>
  64. </td>
  65. </tr>
  66. <?php endforeach;?>
  67. </table>
  68. </div>
  69. </div>
  70. </div>
  71. <?php include $app->getModuleRoot() . 'common/view/footer.html.php';?>