103 |
- |
1 |
<?php
|
|
|
2 |
echo showSectionHead($spTextPanel['Schedule Reports']);
|
|
|
3 |
|
|
|
4 |
// if saved successfully
|
|
|
5 |
if (!empty($success)) {
|
|
|
6 |
showSuccessMsg($spTextReport['sheduledsuccessfully'], false);
|
|
|
7 |
}
|
|
|
8 |
|
|
|
9 |
?>
|
|
|
10 |
<form id="schedule_form">
|
|
|
11 |
<input type="hidden" name="sec" value="schedule"/>
|
|
|
12 |
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="list">
|
|
|
13 |
<tr class="listHead">
|
|
|
14 |
<td class="left" width='30%'><?php echo $spTextPanel['Schedule Reports']?></td>
|
|
|
15 |
<td class="right"> </td>
|
|
|
16 |
</tr>
|
|
|
17 |
<?php if(isAdmin()){ ?>
|
|
|
18 |
<tr class="blue_row">
|
|
|
19 |
<td class="td_left_col"><?php echo $spText['common']['User']?>:</td>
|
|
|
20 |
<td class="td_right_col">
|
|
|
21 |
<select id="user_id" name="user_id" style="width:150px;" onchange="doLoad('user_id', 'reports.php?sec=schedule', 'content')">
|
|
|
22 |
<?php foreach($userList as $userInfo){?>
|
|
|
23 |
<?php if($userInfo['id'] == $repSetInfo['user_id']){?>
|
|
|
24 |
<option value="<?php echo $userInfo['id']?>" selected><?php echo $userInfo['username']?></option>
|
|
|
25 |
<?php }else{?>
|
|
|
26 |
<option value="<?php echo $userInfo['id']?>"><?php echo $userInfo['username']?></option>
|
|
|
27 |
<?php }?>
|
|
|
28 |
<?php }?>
|
|
|
29 |
</select>
|
|
|
30 |
</td>
|
|
|
31 |
</tr>
|
|
|
32 |
<?php }?>
|
|
|
33 |
<tr class="white_row">
|
|
|
34 |
<td class="td_left_col"><?php echo $spTextReport['Next report generation time']?>:</td>
|
|
|
35 |
<td class="td_right_col"><?php echo $nextReportTime?></td>
|
|
|
36 |
</tr>
|
|
|
37 |
<tr class="blue_row">
|
|
|
38 |
<td class="td_left_col"><?php echo $spTextReport['Reports generation interval']?>: </td>
|
|
|
39 |
<td class="td_right_col">
|
|
|
40 |
<select name="report_interval">
|
|
|
41 |
<?php foreach ($scheduleList as $key => $val) {
|
|
|
42 |
if ($key < SP_SYSTEM_REPORT_INTERVAL) continue;
|
|
|
43 |
$selected = ($key == $reportInterval) ? "selected" : "";
|
|
|
44 |
?>
|
|
|
45 |
<option value="<?php echo $key?>" <?php echo $selected?> ><?php echo $val?></option>
|
|
|
46 |
<?php
|
|
|
47 |
}?>
|
|
|
48 |
</select>
|
|
|
49 |
</td>
|
|
|
50 |
</tr>
|
|
|
51 |
<?php if (SP_REPORT_EMAIL_NOTIFICATION) {?>
|
|
|
52 |
<tr class="white_row">
|
|
|
53 |
<td class="td_left_col"><?php echo $spTextReport['Email notification']?>:</td>
|
|
|
54 |
<td class="td_right_col">
|
|
|
55 |
<?php
|
|
|
56 |
$selected = $repSetInfo['email_notification'] ? 'selected' : '';
|
|
|
57 |
?>
|
|
|
58 |
<select name="email_notification">
|
|
|
59 |
<option value="0"><?php echo $spText['common']['No']?></option>
|
|
|
60 |
<option value="1" <?php echo $selected?>><?php echo $spText['common']['Yes']?></option>
|
|
|
61 |
</select>
|
|
|
62 |
</td>
|
|
|
63 |
</tr>
|
|
|
64 |
<?php }?>
|
|
|
65 |
<tr class="blue_row">
|
|
|
66 |
<td class="tab_left_bot_noborder"></td>
|
|
|
67 |
<td class="tab_right_bot"></td>
|
|
|
68 |
</tr>
|
|
|
69 |
<tr class="listBot">
|
|
|
70 |
<td class="left" colspan="1"></td>
|
|
|
71 |
<td class="right"></td>
|
|
|
72 |
</tr>
|
|
|
73 |
</table>
|
|
|
74 |
<table width="100%" cellspacing="0" cellpadding="0" border="0" class="actionSec">
|
|
|
75 |
<tr>
|
|
|
76 |
<td style="padding-top: 6px;text-align:right;">
|
|
|
77 |
<a onclick="scriptDoLoad('reports.php?sec=schedule', 'content')" href="javascript:void(0);" class="actionbut">
|
|
|
78 |
<?php echo $spText['button']['Cancel']?>
|
|
|
79 |
</a>
|
|
|
80 |
<?php $actFun = SP_DEMO ? "alertDemoMsg()" : "confirmSubmit('reports.php', 'schedule_form', 'content')"; ?>
|
|
|
81 |
<a onclick="<?php echo $actFun?>" href="javascript:void(0);" class="actionbut">
|
|
|
82 |
<?php echo $spText['button']['Proceed']?>
|
|
|
83 |
</a>
|
|
|
84 |
</td>
|
|
|
85 |
</tr>
|
|
|
86 |
</table>
|
|
|
87 |
</form>
|