]> git.sur5r.net Git - bacula/bacula/blob - gui/bweb/tpl/ach_add.tpl
Spelling updates
[bacula/bacula] / gui / bweb / tpl / ach_add.tpl
1 <br/>
2 <div class='titlediv'>
3   <h1 class='newstitle'><TMPL_UNLESS name>New</TMPL_UNLESS> Autochanger </h1>
4 </div>
5 <div class='bodydiv'>
6    You have to create a Location which will have the same name.<br/><br/>
7
8    <form name='form1' action="?" method='get'>
9     <table>
10      <tr><td>Name :</td>     
11          <td>
12           <select name='ach' class='formulaire' id='ach'>
13 <TMPL_LOOP devices><option value='<TMPL_VAR name>'><TMPL_VAR name></option></TMPL_LOOP>
14           </select>
15          </td>
16      </tr>
17      <tr><td>Pre-command :</td> 
18          <td> <input class="formulaire" type='text' id='precmd' value='sudo'
19            title='can be "sudo" or "ssh storage@storagehost"...' name='precmd'>
20          </td>
21      </tr>
22      <tr><td>mtx command :</td> 
23          <td> <input class="formulaire" type='text' name='mtxcmd' size='32'
24                value='/usr/sbin/mtx' id='mtxcmd'>
25          </td>
26      </tr>
27      <tr><td>Device :</td> 
28          <td> <input class="formulaire" type='text' name='device' 
29                value='/dev/changer' id='device'>
30          </td>
31      </tr>
32     <tr><td><b>Drives</b></td><td/></tr>
33     <TMPL_LOOP devices>
34     <tr>
35      <td><input class='formulaire' type='checkbox' id='drive_<TMPL_VAR name>'
36                 name='drives' value='<TMPL_VAR name>'><TMPL_VAR name>
37      </td>
38      <td>index <input type='text' title='drive index' class='formulaire'
39                 id='index_<TMPL_VAR name>' value='' 
40                 name='index_<TMPL_VAR name>' size='3'>
41      </td>
42     </tr>
43     </TMPL_LOOP>
44     </table>
45     <input type="image" name='action' value='ach_add' src='/bweb/save.png'>
46    </form>
47 </div>
48
49 <script type="text/javascript" language="JavaScript">
50   <TMPL_IF name>
51   for (var i=0; i < document.form1.ach.length; ++i) {
52      if (document.form1.ach[i].value == '<TMPL_VAR name>') {
53         document.form1.ach[i].selected = true;
54      }
55   }
56   </TMPL_IF>
57   <TMPL_IF mtxcmd>
58      document.getElementById('mtxcmd').value='<TMPL_VAR mtxcmd>';
59   </TMPL_IF>
60   <TMPL_IF precmd>
61      document.getElementById('precmd').value='<TMPL_VAR precmd>';
62   </TMPL_IF>
63   <TMPL_IF device>
64      document.getElementById('device').value='<TMPL_VAR device>';
65   </TMPL_IF>
66   <TMPL_IF drives>
67    <TMPL_LOOP drives>
68      document.getElementById('drive_<TMPL_VAR name>').checked=true;
69      document.getElementById('index_<TMPL_VAR name>').value=<TMPL_VAR index>;
70    </TMPL_LOOP>
71   </TMPL_IF>
72 </script>