Added filterable to summary and histogram controllers
[ninja.git] / modules / reports / views / summary / options.php
blob14b8bc378b684bdb7d196eb3182e98d3e5e57810
1 <?php defined('SYSPATH') OR die('No direct access allowed.'); ?>
2 <form action="<?php echo url::base(true) ?>summary/generate" method="post" class="report_form">
3 <div class="standard setup-table">
4 <input type="hidden" name="report_id" value="<?php echo $options['report_id'] ?>" />
5 <table class="setup-tbl report_block auto_width">
6 <tr>
7 <td>
8 <?php echo help::render('standardreport') ?>
9 <label for="standardreport"><?php echo _('Standard type') ?></label>
10 </td>
11 <td></td>
12 <td>
13 <?php echo help::render('summary_items') ?>
14 <label for="summary_items"><?php echo _('Items to show') ?></label>
15 </td>
16 </tr>
17 <tr>
18 <td>
19 <?php echo form::dropdown(array('name' => 'standardreport'), $options->get_alternatives('standardreport'), $options['standardreport']); ?>
20 </td>
21 <td></td>
22 <td>
23 <?php echo form::input(array('name' => 'summary_items', 'maxlength' => 7), $options['summary_items']) ?>
24 </td>
25 </tr>
26 <tr>
27 <td colspan="3"><input id="reports_submit_button" type="submit" name="" value="<?php echo _('Show report') ?>" class="button create-report" /></td>
28 </tr>
29 </table>
30 </div>
31 </form>
32 <form action="<?php echo url::base(true) ?>summary/generate" method="post" class="report_form">
33 <div class="custom setup-table">
34 <input type="hidden" name="report_id" value="<?php echo $options['report_id'] ?>" />
35 <?php echo new View('reports/objselector'); ?>
36 <h2><?php echo _('Report Settings'); ?></h2>
37 <hr />
38 <table id="report" class="setup-tbl custom report_block">
39 <tr>
40 <td>
41 <label for="summary_type"><?php echo help::render('summary_type').' '._('Summary type') ?></label>
42 </td>
43 <td></td>
44 <td>
45 <?php echo help::render('summary_items') ?>
46 <label for="summary_items"><?php echo _('Items to show') ?></label>
47 </td>
48 </tr>
49 <tr>
50 <td><?php echo form::dropdown('summary_type', $options->get_alternatives('summary_type'), $options['summary_type']) ?></td>
51 <td style="width: 10px">&nbsp;</td>
52 <td>
53 <?php echo form::input(array('name' => 'summary_items', 'size' => 3, 'maxlength' => 3), $options['summary_items']) ?>
54 </td>
55 </tr>
56 <tr>
57 <td><label for="report_period"><?php echo help::render('reporting_period').' '._('Reporting period') ?></label></td>
58 <td style="width: 10px">&nbsp;</td>
59 <td><label for="rpttimeperiod"><?php echo help::render('report_time_period').' '._('Report time period') ?></label></td>
60 </tr>
61 <tr>
62 <td><?php echo form::dropdown('report_period', $options->get_alternatives('report_period'), $options['report_period']); ?></td>
63 <td style="width: 18px">&nbsp;</td>
64 <td><?php echo form::dropdown(array('name' => 'rpttimeperiod'), $options->get_alternatives('rpttimeperiod'), $options['rpttimeperiod']); ?></td>
65 </tr>
66 <tr id="custom_time" style="display: none; clear: both;">
67 <td><label for="cal_start"><?php echo help::render('start-date', 'reports').' '._('Start date') ?></label> (<em id="start_time_tmp"><?php echo _('Click calendar to select date') ?></em>)<br />
68 <input type="text" id="cal_start" name="cal_start" maxlength="10" autocomplete="off" value="<?php echo $options->get_date('start_time') ?>" class="date-pick datepick-start" title="<?php echo _('Date Start selector') ?>" />
69 <input type="text" maxlength="5" name="time_start" id="time_start" class="time_start" value="<?php echo $options->get_time('start_time') ?>">
70 </td>
71 <td>&nbsp;</td>
72 <td><label for="cal_end"><?php echo help::render('end-date', 'reports').' '._('End date') ?></label> (<em id="end_time_tmp"><?php echo _('Click calendar to select date') ?></em>)<br />
73 <input type="text" id="cal_end" name="cal_end" maxlength="10" autocomplete="off" value="<?php echo $options->get_date('end_time') ?>" class="date-pick datepick-end" title="<?php echo _('Date End selector') ?>" />
74 <input type="text" maxlength="5" name="time_end" id="time_end" class="time_end" value="<?php echo $options->get_time('end_time') ?>">
75 </td>
76 </tr>
78 <tr>
79 <td>
80 <label for="alert_types"><?php echo help::render('alert_types').' '._('Alert types') ?></label><br />
81 <?php echo form::dropdown('alert_types', $options->get_alternatives('alert_types'), $options['alert_types']) ?>
82 </td>
83 <td>&nbsp;</td>
84 <td>
85 <label for="state_types"><?php echo help::render('state_types').' '._('State types') ?></label><br />
86 <?php echo form::dropdown('state_types', $options->get_alternatives('state_types'), $options['state_types']) ?>
87 </td>
88 </tr>
89 <tr>
90 <td>
91 <label for="host_states"><?php echo help::render('host_states').' '._('Host states') ?></label><br />
92 <?php echo form::dropdown('host_states', $options->get_alternatives('host_states'), $options['host_states']) ?>
93 </td>
94 <td>&nbsp;</td>
95 <td>
96 <label for="service_states"><?php echo help::render('service_states').' '._('Service states') ?></label><br />
97 <?php echo form::dropdown('service_states', $options->get_alternatives('service_states'), $options['service_states']) ?>
98 </td>
99 </tr>
100 <tr>
101 <td>
102 <?php echo help::render('include_long_output') ?>
103 <input type="checkbox" name="include_long_output" id="include_long_output" <?php echo $options['include_long_output'] ? 'checked="checked"' : null ?> />
104 <label for="include_long_output"><?php echo _('Include full output') ?></label>
105 </td>
106 <td></td>
107 <td>
108 </td>
109 </tr>
110 <tr>
111 <td>
112 <?php echo help::render('skin') ?>
113 <label for="skin" id="skin_lbl"><?php echo _('Skin') ?></label>
114 </td>
115 <td></td>
116 <td>
117 <?php echo help::render('description') ?>
118 <label for="description" id="descr_lbl"><?php echo _('Description') ?></label>
119 </td>
120 </tr>
121 <tr>
122 <td>
123 <?php echo form::dropdown(array('name' => 'skin'), ninja::get_skins(), $options['skin']); ?>
124 </td>
125 <td></td>
126 <td>
127 <?php echo form::textarea('description', $options['description']); ?>
128 </td>
129 </tr>
130 <tr>
131 <td colspan="3"><input id="reports_submit_button" type="submit" name="" value="<?php echo _('Show report') ?>" class="button create-report" /></td>
132 </tr>
133 </table>
134 </div>
135 </form>