remove old readme
[atutor.git] / themes / default / admin / modules / index.tmpl.php
1
2 <form method="get" action="<?php echo $_SERVER['PHP_SELF']; ?>">
3         <div class="input-form">
4                 <div class="row">
5                         <h3><?php echo _AT('results_found', count($this->keys));?>
6                         </h3>
7                 </div>
8
9                 <div class="row">
10                         <?php echo _AT('type'); ?><br />
11                         <input type="checkbox" name="core" value="1" id="t0" <?php if ($_GET['core']) { echo 'checked="checked"'; } ?> /><label for="t0"><?php echo _AT('core'); ?></label>
12
13                         <input type="checkbox" name="standard" value="1" id="t1" <?php if ($_GET['standard']) { echo 'checked="checked"'; } ?> /><label for="t1"><?php echo _AT('standard'); ?></label> 
14
15                         <input type="checkbox" name="extra" value="1" id="t2" <?php if ($_GET['extra']) { echo 'checked="checked"'; } ?> /><label for="t2"><?php echo _AT('extra'); ?></label> 
16                 </div>
17
18
19                 <div class="row">
20                         <?php echo _AT('status'); ?><br />
21                         <input type="checkbox" name="enabled" value="1" id="s0" <?php if ($_GET['enabled']) { echo 'checked="checked"'; } ?> /><label for="s0"><?php echo _AT('enabled'); ?></label> 
22
23                         <input type="checkbox" name="disabled" value="1" id="s1" <?php if ($_GET['disabled']) { echo 'checked="checked"'; } ?> /><label for="s1"><?php echo _AT('disabled'); ?></label> 
24
25                         <input type="checkbox" name="missing" value="1" id="s2" <?php if ($_GET['missing']) { echo 'checked="checked"'; } ?> /><label for="s2"><?php echo _AT('missing'); ?></label> 
26
27                         <input type="checkbox" name="partially_uninstalled" value="1" id="s3" <?php if ($_GET['partially_uninstalled']) { echo 'checked="checked"'; } ?> /><label for="s3"><?php echo _AT('partially_uninstalled'); ?></label> 
28                 </div>
29
30                 <div class="row buttons">
31                         <input type="submit" name="filter" value="<?php echo _AT('filter'); ?>" />
32                         <input type="submit" name="reset_filter" value="<?php echo _AT('reset_filter'); ?>" />
33                 </div>
34         </div>
35 </form>
36
37 <form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="get" name="form">
38
39 <input type="hidden" name="enabled" value="<?php echo (int) $_GET['enabled']; ?>" />
40 <input type="hidden" name="disabled" value="<?php echo (int) $_GET['disabled']; ?>" />
41 <input type="hidden" name="core" value="<?php echo (int) $_GET['core']; ?>" />
42 <input type="hidden" name="standard" value="<?php echo (int) $_GET['standard']; ?>" />
43 <input type="hidden" name="extra" value="<?php echo (int) $_GET['extra']; ?>" />
44 <input type="hidden" name="missing" value="<?php echo (int) $_GET['missing']; ?>" />
45 <input type="hidden" name="partially_uninstalled" value="<?php echo (int) $_GET['partially_uninstalled']; ?>" />
46
47 <table class="data" summary="List of modules" rules="cols">
48 <colgroup>
49                 <col />
50                 <col class="sort" />
51                 <col span="4" />
52 </colgroup>
53 <thead>
54 <tr>
55         <th scope="col">&nbsp;</th>
56         <th scope="col"><?php echo _AT('module_name'); ?></th>
57         <th scope="col"><?php echo _AT('type'); ?></th>
58         <th scope="col"><?php echo _AT('status'); ?></th>
59         <th scope="col"><?php echo _AT('cron'); ?></th>
60         <th scope="col"><?php echo _AT('directory_name'); ?></th>
61 </tr>
62 </thead>
63 <tfoot>
64 <tr>
65         <td colspan="6">
66                 <input type="submit" name="details" value="<?php echo _AT('details'); ?>" />
67                 <input type="submit" name="enable"  value="<?php echo _AT('enable'); ?>" />
68                 <input type="submit" name="disable" value="<?php echo _AT('disable'); ?>" />
69                 <input type="submit" name="uninstall" value="<?php echo _AT('uninstall'); ?>" />
70                 <input type="submit" name="export" value="<?php echo _AT('export'); ?>" />
71         </td>
72 </tr>
73 </tfoot>
74 <tbody>
75
76
77
78 <?php foreach($this->keys as $dir_name) : $module =& $this->module_list[$dir_name]; $i++; $readme = get_readme(AT_INCLUDE_PATH.'../mods/'.$dir_name);?>
79
80         <tr onkeydown="document.form['t_<?php echo $i; ?>'].checked = true; rowselect(this);" onmousedown="document.form['t_<?php echo $i; ?>'].checked = true; rowselect(this);" id="r_<?php echo $i; ?>">
81                 <td valign="top"><input type="radio" id="t_<?php echo $i; ?>" name="mod_dir" value="<?php echo $dir_name; ?>" /></td>
82                 <td nowrap="nowrap" valign="top"><label for="t_<?php echo $i; ?>"><?php echo $module->getName(); if ($readme <> '') echo '&nbsp;<a href="#" onclick="ATutor.poptastic(\''.AT_BASE_HREF.'mods/'.$dir_name.'/'.$readme.'\');return false;">'._AT('view_readme').'</a>'; ?></label></td>
83                 <td valign="top"><?php
84                         if ($module->isCore()) {
85                                 echo '<strong>'._AT('core').'</strong>';
86                         } else if ($module->isStandard()) {
87                                 echo _AT('standard');
88                         } else {
89                                 echo _AT('extra');
90                         }
91                         ?></td>
92                 <td valign="top"><?php
93                         if ($module->isEnabled()) {
94                                 echo _AT('enabled');
95                         } else if ($module->isMissing()) {
96                                 echo '<strong>'._AT('missing').'</strong>';
97                         } else if ($module->isPartiallyUninstalled()) {
98                                 echo _AT('partially_uninstalled');
99                         } else {
100                                 echo '<strong>'._AT('disabled').'</strong>';
101                         }
102                         ?></td>
103                 <td valign="top" align="center">
104                         <?php if ($module->getCronInterval()): ?>
105                                 <?php echo _AT('minutes', $module->getCronInterval()); ?>
106                         <?php else: ?>
107                                 -
108                         <?php endif; ?>
109                 </td>
110                 <td valign="top"><code><?php echo $dir_name; ?>/</code></td>
111         </tr>
112 <?php endforeach; ?>
113 <?php if (!$this->keys): ?>
114         <tr>
115                 <td colspan="6"><?php echo _AT('none_found'); ?></td>
116         </tr>
117 <?php endif; ?>
118 </tbody>
119 </table>
120 </form>