- Timestamp:
- Mar 16, 2009, 10:31:37 AM (15 years ago)
- Location:
- trunk/admin/template/goto
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/admin/template/goto/element_set_ranks.tpl
r3185 r3201 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.ui.sortable" src=$ROOT_URL|@cat:"template-common/lib/ui/packed/ui.sortable.packed.js" } 4 5 {literal} 6 <script type="text/javascript"> 7 $(function() { 8 $('ul.thumbnails') 9 .sortable( 10 { revert: true, 11 opacity: 0.7, 12 handle: $('.rank-of-image').add('.rank-of-image img'), 13 update: function() { 14 $(this).find('li').each(function(i) { 15 $(this).find("input[@name~='rank_of_image']") 16 .each(function() { $(this).attr('value', (i+1)*10)}); 17 }); 18 } 19 }); 20 }); 21 22 </script> 23 {/literal} 24 1 25 <h2>{'Manage image ranks'|@translate}</h2> 2 26 … … 4 28 5 29 {if !empty($thumbnails)} 6 7 30 <form action="{$F_ACTION}" method="post"> 31 <p><input class="submit" type="submit" value="{'Submit'|@translate}" name="submit" {$TAG_INPUT_ENABLED}></p> 8 32 <fieldset> 9 10 33 <legend>{'Edit ranks'|@translate}</legend> 11 12 {if !empty($thumbnails)} 34 {if !empty($thumbnails)} 13 35 <ul class="thumbnails"> 14 36 {foreach from=$thumbnails item=thumbnail} 15 <li><span class="wrap1"> 16 <label> 17 <span class="wrap2"> 18 {if $thumbnail.LEVEL > 0} 19 <em class="levelIndicatorB">{$thumbnail.LEVEL}</em> 20 <em class="levelIndicatorF" title="{$pwg->l10n($pwg->sprintf('Level %d',$thumbnail.LEVEL))}">{$thumbnail.LEVEL}</em> 21 {/if} 22 <span> 23 <img src="{$thumbnail.TN_SRC}" class="thumbnail"> 24 </span></span> 25 <input style="height:12px; width:50px;" type="text" name="rank_of_image[{$thumbnail.ID}]" value="{$thumbnail.RANK}"> 26 </label> 27 </span> 37 <li class="rank-of-image"> 38 <img src="{$thumbnail.TN_SRC}" class="thumbnail" alt=""> 39 <input type="text" name="rank_of_image[{$thumbnail.ID}]" value="{$thumbnail.RANK}"> 28 40 </li> 29 41 {/foreach} 30 42 </ul> 31 {/if} 32 33 <p><input class="submit" type="submit" value="{'Submit'|@translate}" name="submit" {$TAG_INPUT_ENABLED}></p> 34 43 {/if} 35 44 </fieldset> 36 37 45 <p><input class="submit" type="submit" value="{'Submit'|@translate}" name="submit" {$TAG_INPUT_ENABLED}></p> 46 </form> 38 47 39 48 {else} 40 49 <div class="infos"><p>{'No element in this category'|@translate}</p></div> 41 50 {/if} -
trunk/admin/template/goto/thumbnails.css
r2526 r3201 1 /* $Id $ */1 /* $Id: thumbnails.css 2526 2008-09-14 00:33:53Z vdigital $ */ 2 2 .content UL.thumbnails { 3 3 margin: 0; padding: 0; list-style: none; … … 5 5 } 6 6 .content UL.thumbnails LI { display: inline } 7 .content ul.thumbnails li.rank-of-image { 8 float: left; 9 background-color: #111; 10 border: 1px solid #666; 11 color: #666; 12 -moz-border-radius: 4px; 13 display: block; 14 width: 104px; 15 height: 128px; 16 cursor: move; 17 margin: 10px; 18 } 19 .content ul.thumbnails li.rank-of-image img { 20 width: 96px; 21 height: 96px; 22 margin: 4px; 23 float: left; 24 } 25 .content ul.thumbnails li.rank-of-image input { 26 height: 12px; 27 width: 50px; 28 position: relative; 29 top: 0; 30 } 7 31 .content UL.thumbnails SPAN.wrap1 { 8 32 margin: 0 5px 5px 5px;
Note: See TracChangeset
for help on using the changeset viewer.