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

Last change on this file since 4919 was 4919, checked in by nikrou, 14 years ago

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

  • Property svn:eol-style set to LF
File size: 1.7 KB
RevLine 
[3219]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"}
[2531]4
[3219]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)
[4919]14     .find("input:text").attr('value', (i+1)*10);
[3219]15}
16}
17});
18});
19</script>
20{/literal}
21
[2531]22<div class="titrePage">
[3219]23  <h2>Menubar</h2>
[2531]24</div>
[3219]25<div id="debugArea"></div>
[3215]26<form method="post" action="{$F_ACTION}" class="properties">
[3219]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>
[3526]34        <td>{'Hide'|@translate}</td>
[3219]35      </tr>
36    </thead>
37    <tbody>
38    {foreach from=$blocks item=block name="block_loop"}
[2531]39        <tr class="{if $smarty.foreach.block_loop.index is odd}row1{else}row2{/if}">
[3219]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>
[2531]45        </tr>
[3219]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>
[3185]53</form>
Note: See TracBrowser for help on using the repository browser.