Hide isDisabled checkbox for landing page menu item
authorTim Düsterhus <duesterhus@woltlab.com>
Sat, 19 Jul 2014 13:46:05 +0000 (15:46 +0200)
committerTim Düsterhus <duesterhus@woltlab.com>
Sat, 19 Jul 2014 13:46:05 +0000 (15:46 +0200)
In most cases it is misleading, as it is not respected when
showOrder is not changed as well. In case the admin really wants to
disable the current landing page's menu item he can do so with few
extra clicks.

wcfsetup/install/files/acp/templates/pageMenuItemAdd.tpl

index 2b427ee997be572043f24f2dbd33a20d59710eb6..ef79d7bfb7f134853a56ee99da4f14a99b634d84 100644 (file)
                                </dd>
                        </dl>
                        
-                       <dl>
-                               <dt></dt>
-                               <dd>
-                                       <label><input type="checkbox" name="isDisabled" id="isDisabled" value="1"{if $isDisabled} checked="checked"{/if} /> <span>{lang}wcf.acp.pageMenu.isDisabled{/lang}</span></label>
-                               </dd>
-                       </dl>
+                       {if $action == 'add' || !$menuItem->isLandingPage}
+                               <dl>
+                                       <dt></dt>
+                                       <dd>
+                                               <label><input type="checkbox" name="isDisabled" id="isDisabled" value="1"{if $isDisabled} checked="checked"{/if} /> <span>{lang}wcf.acp.pageMenu.isDisabled{/lang}</span></label>
+                                       </dd>
+                               </dl>
+                       {/if}
                        
                        {event name='advancedFields'}
                </fieldset>