Skip to content

Commit

Permalink
Provide the option to disable menu items when editing
Browse files Browse the repository at this point in the history
This led to the issue that when editing a disabled menu item, it was automatically enabled.

ref https://www.woltlab.com/community/thread/308911-unexpected-behaviour-when-saving-menu-items/
  • Loading branch information
BurntimeX committed Oct 24, 2024
1 parent 35e8777 commit 7044cd7
Showing 1 changed file with 6 additions and 8 deletions.
14 changes: 6 additions & 8 deletions wcfsetup/install/files/acp/templates/menuItemAdd.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -117,14 +117,12 @@
</dd>
</dl>

{if $action == 'add'}
<dl>
<dt></dt>
<dd>
<label><input type="checkbox" name="isDisabled" id="isDisabled" value="1"{if $isDisabled} checked{/if}> <span>{lang}wcf.acp.menu.item.isDisabled{/lang}</span></label>
</dd>
</dl>
{/if}
<dl>
<dt></dt>
<dd>
<label><input type="checkbox" name="isDisabled" id="isDisabled" value="1"{if $isDisabled} checked{/if}> <span>{lang}wcf.acp.menu.item.isDisabled{/lang}</span></label>
</dd>
</dl>

{event name='dataFields'}
</div>
Expand Down

0 comments on commit 7044cd7

Please sign in to comment.