⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 manageactions.smarty

📁 PHP 知识管理系统(基于树结构的知识管理系统), 英文原版的PHP源码。
💻 SMARTY
字号:
{$context->oPage->requireCSSResource('resources/css/workflow-admin.css')}<h2>{i18n}Manage Actions{/i18n}</h2><p class="descriptiveText">{i18n}An important part of workflow is controlling whichactions are available to users at various stages.  For example, it may be necessary to prevent the "Edit Metadata" action from being used when a documentis "published". Doing this is a two step process:  first, you need to specifythat "Edit Metadata" is an action you wish to control within this workflow; second,you need to specify that the action is <strong>not</strong> to be made availablewhen documents are in the "published" state.{/i18n}</p><form action="{$smarty.server.PHP_SELF}" method="POST"><fieldset><legend>{i18n}Specify Controlled Actions{/i18n}</legend><p class="descriptiveText">{i18n}Select the actions you want this workflowto control from the list below.  Actions you do not specify will be available no matter what the state of the document.{/i18n}</p><input type="hidden" name="action" value="setWorkflowActions" /><input type="hidden" name="fWorkflowId" value="{$oWorkflow->getId()}" />{entity_checkboxes name="fActions" entities="$aActions" idmethod="getName" method="getDisplayName" assign="aCheckboxes" selected="$aActionsSelected" separator="<br />"}{foreach from=$aCheckboxes item=sCheckbox}{$sCheckbox}{/foreach}<div class="form_actions">   <input type="submit" name="submit" value="{i18n}Set controlled actions{/i18n}" /></div></fieldset></form><h3>{i18n}Assign Actions to States{/i18n}</h3><p class="descriptiveText">{i18n}The table below lists the actions you have specified as controlled by this workflow, and all the states within the workflow.  From here you can assign those actions to the various states in this workflow.  Checked items are available to users whose permissions would normally allow them when the document isin that state.  Unchecked items are not available to any users.{/i18n}</p>{if (empty($aActionsSelected))}<div class="ktInfoMessage"><span>{i18n}No actions are controlled by this workflow.  All actionswill be available at all states.{/i18n}</span></div>{else}<form action="{$smarty.server.PHP_SELF}" method="POST"><input type="hidden" name="action" value="updateActionAvailability" /><input type="hidden" name="fWorkflowId" value="{$oWorkflow->getId()}" /><table class="kt_collection" style="width: auto;"><thead>  <tr>    <th>&nbsp;</th>    {foreach from=$aActionsSelected item=sAction}    <th>{$workflow_info.actions_by_name.$sAction->getDisplayName()}</th>    {/foreach}  </tr></thead><tbody>{foreach item=oState from=$workflow_info.states}  <tr class='{cycle values="odd,even"}'>    <td>{$oState->getName()}</td>    {foreach item=sAction from=$aActionsSelected}      <td><input type="checkbox" name="fAvailableActions[{$oState->getId()}][{$sAction}]" {if ($context->actionAvailable($sAction, $oState))}checked="true"{/if}/></td>    {/foreach}  </tr>{/foreach}</tbody></table><div class="form_actions">  <input type="submit" value="{i18n}Update Action Availability{/i18n}" /></div></form>{/if}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -