[ Index ] |
|
Code source de eZ Publish 3.9.0 |
1 {* DO NOT EDIT THIS FILE! Use an override template instead. *} 2 {* Placement code for content/edit *} 3 4 {* Example code of how to do limitation placement 5 {let name=Choice 6 list_node1=first_set($:assigned_remote_map[2].parent_node,0) 7 list_node2=first_set($:assigned_remote_map[3].parent_node,31)} 8 9 <input type="hidden" name="MainNodeID" value="26" /> 10 11 <input type="hidden" name="SetPlacementNodeIDArray[1]" value="26" /> 12 <input type="hidden" name="SetRemoteIDOrderMap[1]" value="1" /> 13 <input type="hidden" name="SetRemoteIDFieldMap[1]" value="9" /> 14 15 <select name="SetPlacementNodeIDArray[2]"> 16 {section loop=hash(0,"None",28,"Feature",29,"Some place",30,"Another place")} 17 <option value="{$:key}" {section show=eq($:list_node1,$:key)}selected="selected"{/section}>{$:item}</option> 18 {/section} 19 </select> 20 <input type="hidden" name="SetRemoteIDOrderMap[2]" value="0" /> 21 <input type="hidden" name="SetRemoteIDFieldMap[2]" value="1" /> 22 23 <select name="SetPlacementNodeIDArray[3]"> 24 {section loop=hash(0,"None",31,"1",32,"2")} 25 <option value="{$:key}" {section show=eq($:list_node2,$:key)}selected="selected"{/section}>{$:item}</option> 26 {/section} 27 </select> 28 <input type="hidden" name="SetRemoteIDOrderMap[3]" value="1" /> 29 <input type="hidden" name="SetRemoteIDFieldMap[3]" value="4" /> 30 31 {/let} 32 33 *} 34 35 36 {default exclude_remote_assignments=false()} 37 {let name=Node exclude_remote_assignments=$:exclude_remote_assignments 38 sort_fields=hash(2,"Published"|i18n("design/standard/content/edit"),3,"Modified"|i18n("design/standard/content/edit"),4,"Section"|i18n("design/standard/content/edit"),5,"Depth"|i18n("design/standard/content/edit"),9,"Name"|i18n("design/standard/content/edit"),6,"Class Identifier"|i18n("design/standard/content/edit"),7,"Class Name"|i18n("design/standard/content/edit"),8,"Priority"|i18n("design/standard/content/edit")) 39 has_top_levels=false()} 40 {section show=is_set( $assigned_node_array )} 41 {section loop=$assigned_node_array} 42 {section show=$Node:item.parent_node|le( 1 )} 43 {set has_top_levels=true()} 44 {/section} 45 {/section} 46 {/section} 47 48 <table class="list" width="100%" border="0" cellspacing="0" cellpadding="0"> 49 <tr> 50 <th width="60%">{"Location"|i18n("design/standard/content/edit")}</th> 51 <th colspan="1">{"Sort by"|i18n("design/standard/content/edit")}</th> 52 <th colspan="2">{"Ordering"|i18n("design/standard/content/edit")}</th> 53 {section show=$:has_top_levels|not} 54 <th colspan="1">{"Main"|i18n("design/standard/content/edit")}</th> 55 <th colspan="1">{"Move"|i18n("design/standard/content/edit")}</th> 56 <th colspan="1">{"Remove"|i18n("design/standard/content/edit")}</th> 57 {/section} 58 </tr> 59 {let existingParentNodes=$object.parent_nodes} 60 {section show=is_set( $assigned_node_array )} 61 {section loop=$assigned_node_array sequence=array(bglight,bgdark)} 62 {section-exclude match=$:item.parent_node|le(0)} 63 {section-exclude match=and($:exclude_remote_assignments,$:item.remote_id|gt(0))} 64 {let parent_node=$Node:item.parent_node_obj} 65 <tr> 66 <td class="{$Node:sequence}"> 67 {switch match=$Node:parent_node.node_id} 68 {case match=1} 69 Top node 70 {/case} 71 {case} 72 {section name=Path loop=$Node:parent_node.path} 73 {$Node:Path:item.name|wash} / 74 {/section} 75 {$Node:parent_node.name|wash} 76 {/case} 77 {/switch} / {$object.name|wash} 78 </td> 79 <td class="{$Node:sequence}"> 80 <select name="SortFieldMap[{$Node:item.id}]"> 81 {section name=Sort loop=$Node:sort_fields} 82 <option value="{$Node:Sort:key}" {section show=eq($Node:Sort:key,$Node:item.sort_field)}selected="selected"{/section}>{$Node:Sort:item}</option> 83 {/section} 84 </select> 85 </td> 86 <td class="{$Node:sequence}" width="25"> 87 <nobr><img src={"asc-transp.gif"|ezimage} alt="Ascending" /><input type="radio" name="SortOrderMap[{$Node:item.id}]" value="1" {section show=eq($Node:item.sort_order,1)}checked="checked"{/section} /></nobr> 88 </td> 89 <td class="{$Node:sequence}" width="25"> 90 <nobr><img src={"desc-transp.gif"|ezimage} alt="Descending" /><input type="radio" name="SortOrderMap[{$Node:item.id}]" value="0" {section show=eq($Node:item.sort_order,0)}checked="checked"{/section} /></nobr> 91 </td> 92 93 {section show=$:has_top_levels|not} 94 <td class="{$Node:sequence}" align="right"> 95 <input type="radio" name="MainNodeID" {section show=eq($main_node_id,$Node:item.parent_node)}checked="checked"{/section} value="{$Node:item.parent_node}" /> 96 </td> 97 {/section} 98 99 {section show=$:has_top_levels|not} 100 <td class="{$Node:sequence}" align="right"> 101 {switch match=$Node:item.parent_node} 102 {case in=$Node:existingParentNodes} 103 <input type="image" name="{concat('MoveNodeID_',$Node:item.parent_node)}" src={"move.gif"|ezimage} value="{$Node:item.parent_node}" /> 104 {/case} 105 {case} 106 {section show=$Node:item.from_node_id|gt(0)} 107 <input type="image" name="{concat('MoveNodeID_',$Node:item.parent_node)}" src={"move.gif"|ezimage} value="{$Node:item.parent_node}" /> 108 {section-else} 109 {/section} 110 {/case} 111 {/switch} 112 </td> 113 <td class="{$Node:sequence}" align="right"> 114 {* {section show=eq($Node:item.parent_node,$main_node_id)|not}*} 115 <input type="image" name="{concat('RemoveNodeID_',$Node:item.parent_node)}" src={"trash.png"|ezimage} value="{$Node:item.parent_node}" /> 116 {* {/section}*} 117 </td> 118 {/section} 119 120 </tr> 121 {/let} 122 {/section} 123 {/section} 124 {/let} 125 </table> 126 {section show=$:has_top_levels} 127 <input type="hidden" name="MainNodeID" value="{$main_node_id}" /> 128 {/section} 129 {section show=$:has_top_levels|not} 130 <div align="left" class="buttonblock"> 131 <input class="button" type="submit" name="BrowseNodeButton" value="{'Add locations'|i18n('design/standard/content/edit')}" /> 132 </div> 133 {/section} 134 135 {/let} 136 {/default}
titre
Description
Corps
titre
Description
Corps
titre
Description
Corps
titre
Corps
Généré le : Sat Feb 24 10:30:04 2007 | par Balluche grâce à PHPXref 0.7 |