当前位置: 首页>>代码示例>>PHP>>正文


PHP eZWorkflow::fetchLimited方法代码示例

本文整理汇总了PHP中eZWorkflow::fetchLimited方法的典型用法代码示例。如果您正苦于以下问题:PHP eZWorkflow::fetchLimited方法的具体用法?PHP eZWorkflow::fetchLimited怎么用?PHP eZWorkflow::fetchLimited使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在eZWorkflow的用法示例。


在下文中一共展示了eZWorkflow::fetchLimited方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: fetchAllowedWorkflows

 function fetchAllowedWorkflows()
 {
     $connectionType = '*';
     if ($this->attribute('connect_type') == 'b') {
         $connectionType = 'before';
     } else {
         if ($this->attribute('connect_type') == 'a') {
             $connectionType = 'after';
         }
     }
     return eZWorkflow::fetchLimited($this->attribute('module_name'), $this->attribute('function_name'), $connectionType);
 }
开发者ID:CG77,项目名称:ezpublish-legacy,代码行数:12,代码来源:eztrigger.php

示例2: explode

    $explodedOperation = explode('_', $operation);
    $i = 0;
    if (sizeof($explodedOperation) >= 3) {
        if (strcmp($explodedOperation[$i], "before") == 0 || strcmp($explodedOperation[$i], "after") == 0) {
            $moduleParts = array($explodedOperation[$i++]);
        }
    } else {
        $moduleParts = array("before", "after");
    }
    foreach ($moduleParts as $trigger['connect_type']) {
        $trigger['module'] = $explodedOperation[$i];
        // $i is either 0 or 1
        $trigger['operation'] = $explodedOperation[$i + 1];
        $trigger['workflow_id'] = 0;
        $trigger['key'] = $trigger['module'] . '_' . $trigger['operation'] . '_' . $trigger['connect_type'][0];
        $trigger['allowed_workflows'] = eZWorkflow::fetchLimited($trigger['module'], $trigger['operation'], $trigger['connect_type']);
        foreach ($triggers as $existendTrigger) {
            if ($existendTrigger->attribute('module_name') == $trigger['module'] && $existendTrigger->attribute('function_name') == $trigger['operation'] && $existendTrigger->attribute('connect_type') == $trigger['connect_type'][0]) {
                $trigger['workflow_id'] = $existendTrigger->attribute('workflow_id');
            }
        }
        $possibleTriggers[] = $trigger;
    }
}
if ($http->hasPostVariable('StoreButton')) {
    $db = eZDB::instance();
    $db->begin();
    foreach ($possibleTriggers as $trigger) {
        if ($http->hasPostVariable('WorkflowID_' . $trigger['key'])) {
            $workflowID = $http->postVariable('WorkflowID_' . $trigger['key']);
            if ($workflowID != -1) {
开发者ID:nfrp,项目名称:ezpublish,代码行数:31,代码来源:list.php


注:本文中的eZWorkflow::fetchLimited方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。