source: trunk/admin/template/goto/menubar.tpl @ 4919

Revision 4919, 1.7 KB checked in by nikrou, 10 years ago (diff)

Feature 1442 : fix problem with type selector : :text instead of @type='text'

  • Property svn:eol-style set to LF
Line 
1{known_script id="jquery" src=$ROOT_URL|@cat:"template-common/lib/jquery.packed.js"}
2{known_script id="jquery.ui" src=$ROOT_URL|@cat:"template-common/lib/ui/packed/ui.core.packed.js" }
3{known_script id="jquery-tablednd" src=$ROOT_URL|@cat:"template-common/lib/jquery.tablednd.js"}
4
5{literal}
6<script type="text/javascript">
7$(function() {
8$('table.table2').tableDnD({
9onDrop:function(table,row) {
10var rows = table.tBodies[0].rows;
11for (var i=0; i<rows.length; i++) {
12  $(rows[i])
13     .attr('class', 'row'+i%2)
14     .find("input:text").attr('value', (i+1)*10);
15}
16}
17});
18});
19</script>
20{/literal}
21
22<div class="titrePage">
23  <h2>Menubar</h2>
24</div>
25<div id="debugArea"></div>
26<form method="post" action="{$F_ACTION}" class="properties">
27  <table class="table2" style="width:99%">
28    <thead>
29      <tr class="throw">
30        <td>Id</td>
31        <td>{'Author'|@translate}</td>
32        <td>{'Name'|@translate}</td>
33        <td>{'Position'|@translate}</td>
34        <td>{'Hide'|@translate}</td>
35      </tr>
36    </thead>
37    <tbody>
38    {foreach from=$blocks item=block name="block_loop"}
39        <tr class="{if $smarty.foreach.block_loop.index is odd}row1{else}row2{/if}">
40          <td>{$block.reg->get_id()}</td>
41          <td>{$block.reg->get_owner()}</td>
42          <td>{$block.reg->get_name()|@translate}</td>
43          <td><input type="text" name="pos_{$block.reg->get_id()}" value={math equation="abs(pos)" pos=$block.pos} size="2"></td>
44          <td><input type="checkbox" name="hide_{$block.reg->get_id()}" {if $block.pos<0}checked="checked"{/if}></td>
45        </tr>
46     {/foreach}
47     </tbody>
48  </table>
49  <p>
50    <input type="submit" name="submit" value="{'Submit'|@translate}" {$TAG_INPUT_ENABLED}>
51    <input type="submit" name="reset" value="{'Reset'|@translate}" {$TAG_INPUT_ENABLED}>
52  </p>
53</form>
Note: See TracBrowser for help on using the repository browser.