new WCF.Action.NestedDelete('wcf\\data\\category\\CategoryAction', '.jsCategory');
{/if}
{if $objectType->getProcessor()->canEditCategory()}
- new WCF.Action.Toggle('wcf\\data\\category\\CategoryAction', '.jsCategory', '> .sortableNodeLabel > .buttons > .jsToggleButton');
-
var sortableNodes = $('.sortableNode');
sortableNodes.each(function(index, node) {
$(node).wcfIdentify();
{hascontent}
<div id="categoryList" class="section{if $objectType->getProcessor()->canEditCategory()} sortableListContainer{/if}">
- <ol class="categoryList sortableList" data-object-id="0">
+ <ol class="categoryList sortableList jsObjectActionContainer" data-object-action-class-name="wcf\data\category\CategoryAction" data-object-id="0">
{content}
{assign var=oldDepth value=0}
{foreach from=$categoryNodeList item='category'}
{section name=i loop=$oldDepth-$categoryNodeList->getDepth()}</ol></li>{/section}
- <li class="{if $objectType->getProcessor()->canEditCategory()}sortableNode {if $categoryNodeList->getDepth() == $objectType->getProcessor()->getMaximumNestingLevel()}sortableNoNesting {/if}{/if}jsCategory" data-object-id="{@$category->categoryID}"{if $collapsedCategoryIDs|is_array} data-is-open="{if $collapsedCategoryIDs[$category->categoryID]|isset}0{else}1{/if}"{/if}>
+ <li class="{if $objectType->getProcessor()->canEditCategory()}sortableNode {if $categoryNodeList->getDepth() == $objectType->getProcessor()->getMaximumNestingLevel()}sortableNoNesting {/if}{/if}jsCategory jsObjectActionObject" data-object-id="{@$category->getObjectID()}"{if $collapsedCategoryIDs|is_array} data-is-open="{if $collapsedCategoryIDs[$category->categoryID]|isset}0{else}1{/if}"{/if}>
<span class="sortableNodeLabel">
<span class="title">
{event name='beforeTitle'}
<span class="icon icon16 fa-arrows sortableNodeHandle"></span>
{if $objectType->getProcessor()->canEditCategory()}
- <span class="icon icon16 fa-{if !$category->isDisabled}check-{/if}square-o jsToggleButton jsTooltip pointer" title="{lang}wcf.global.button.{if !$category->isDisabled}disable{else}enable{/if}{/lang}" data-object-id="{@$category->categoryID}"></span>
+ {objectAction action="toggle" isDisabled=$category->isDisabled}
<a href="{link controller=$editController application=$objectType->getProcessor()->getApplication() id=$category->categoryID title=$category->getTitle()}{/link}" title="{lang}wcf.global.button.edit{/lang}" class="jsTooltip"><span class="icon icon16 fa-pencil"></span></a>
{/if}
{include file='header' pageTitle='wcf.acp.paidSubscription.list'}
-<script data-relocate="true">
- $(function() {
- new WCF.Action.Delete('wcf\\data\\paid\\subscription\\PaidSubscriptionAction', '.jsPaidSubscriptionRow');
- new WCF.Action.Toggle('wcf\\data\\paid\\subscription\\PaidSubscriptionAction', '.jsPaidSubscriptionRow');
- });
-</script>
-
<header class="contentHeader">
<div class="contentHeaderTitle">
<h1 class="contentTitle">{lang}wcf.acp.paidSubscription.list{/lang}{if $items} <span class="badge badgeInverse">{#$items}</span>{/if}</h1>
offset: {@$startIndex}
});
});
-
- $(function() {
- new WCF.Action.Toggle('wcf\\data\\reaction\\type\\ReactionTypeAction', '.reactionTypeRow');
- });
</script>
{/if}
<span class="statusDisplay sortableButtonContainer">
<span class="icon icon16 fa-arrows sortableNodeHandle"></span>
- <span class="jsOnly icon icon16 fa-{if $reactionType->isAssignable}check-{/if}square-o jsToggleButton jsTooltip pointer" title="{lang}wcf.acp.reactionType.is{if !$reactionType->isAssignable}Not{/if}Assignable{/lang}" data-disable-title="{lang}wcf.acp.reactionType.isAssignable{/lang}" data-enable-title="{lang}wcf.acp.reactionType.isNotAssignable{/lang}" data-object-id="{@$reactionType->reactionTypeID}"></span>
+ {assign var='reactionTypeIsDisabled' value=true}
+ {if $reactionType->isAssignable}
+ {assign var='reactionTypeIsDisabled' value=false}
+ {/if}
+ {objectAction action="toggle" isDisabled=$reactionTypeIsDisabled disableTitle='wcf.acp.reactionType.isAssignable' enableTitle='wcf.acp.reactionType.isNotAssignable'}
<a href="{link controller='ReactionTypeEdit' id=$reactionType->reactionTypeID}{/link}"><span title="{lang}wcf.global.button.edit{/lang}" class="jsTooltip icon icon16 fa-pencil"></span></a>
{objectAction action="delete" objectTitle=$reactionType->getTitle()}
<script data-relocate="true" src="{@$__wcf->getPath()}acp/js/WCF.ACP.Style.js?v={@LAST_UPDATE_TIME}"></script>
<script data-relocate="true">
$(function() {
- new WCF.Action.Toggle('wcf\\data\\style\\StyleAction', '.buttonList');
new WCF.ACP.Style.List();
});
</script>
{/hascontent}
<div class="section sectionContainerList">
- <ol class="containerList styleList">
+ <ol class="containerList styleList jsObjectActionContainer" data-object-action-class-name="wcf\data\style\StyleAction">
{foreach from=$objects item=style}
- <li>
+ <li class="jsObjectActionObject" data-object-id="{@$style->getObjectID()}">
<div class="box64">
<span>
<img src="{@$style->getPreviewImage()}" srcset="{@$style->getPreviewImage2x()} 2x" height="64" alt="">
<li><a href="{link controller='StyleExport' id=$style->styleID}{/link}" title="{lang}wcf.acp.style.exportStyle{/lang}" class="jsTooltip"><span class="icon icon16 fa-download"></span> <span class="invisible">{lang}wcf.acp.style.exportStyle{/lang}</span></a></li>
{if !$style->isDefault}
- <li><a href="#" title="{lang}wcf.global.button.{if $style->isDisabled}enable{else}disable{/if}{/lang}" class="jsTooltip"><span class="icon icon16 fa-{if !$style->isDisabled}check-{/if}square-o jsToggleButton" data-object-id="{@$style->styleID}"></span> <span class="invisible">{lang}wcf.global.button.{if $style->isDisabled}enable{else}disable{/if}{/lang}</span></a></li>
+ <li><a href="#" title="{lang}wcf.global.button.{if $style->isDisabled}enable{else}disable{/if}{/lang}" class="jsTooltip"><span class="icon icon16 fa-{if !$style->isDisabled}check-{/if}square-o jsObjectAction" data-object-action="toggle"></span> <span class="invisible">{lang}wcf.global.button.{if $style->isDisabled}enable{else}disable{/if}{/lang}</span></a></li>
<li><a href="#" title="{lang}wcf.acp.style.button.setAsDefault{/lang}" class="jsSetAsDefault jsTooltip"><span class="icon icon16 fa-check-circle"></span> <span class="invisible">{lang}wcf.acp.style.button.setAsDefault{/lang}</span></a></li>
<li><a href="#" title="{lang}wcf.global.button.delete{/lang}" class="jsDelete jsTooltip" data-confirm-message-html="{lang __encode=true}wcf.acp.style.delete.confirmMessage{/lang}"><span class="icon icon16 fa-times"></span> <span class="invisible">{lang}wcf.global.button.delete{/lang}</span></a></li>
{/if}