ILIAS  release_8 Revision v8.24
ilOrgUnitOperationQueries Class Reference

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V. More...

+ Collaboration diagram for ilOrgUnitOperationQueries:

Static Public Member Functions

static registerNewOperationForMultipleContexts (string $operation_name, string $description, array $contexts)
 
static getOperationsForContextName (string $context_name)
 
static getOperationsForContextId (string $context_id)
 
static findById (int $operation_id)
 
static findByOperationString (string $operation_string, string $context_name)
 

Detailed Description

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V.

ILIAS is licensed with the GPL-3.0, see https://www.gnu.org/licenses/gpl-3.0.en.html You should have received a copy of said license along with the source code, too.

If this is not the case or you just want to try ILIAS, you'll find us at: https://www.ilias.de https://github.com/ILIAS-eLearning Class ilOrgUnitOperationQueries

Author
Fabian Schmid fs@st.nosp@m.uder.nosp@m.-raim.nosp@m.ann..nosp@m.ch

Definition at line 23 of file class.ilOrgUnitOperationQueries.php.

Member Function Documentation

◆ findById()

static ilOrgUnitOperationQueries::findById ( int  $operation_id)
static
Exceptions
arException

Definition at line 101 of file class.ilOrgUnitOperationQueries.php.

101 : ActiveRecord /* ilOrgUnitOperation|ActiveRecord */
102 {
103 return ilOrgUnitOperation::findOrFail($operation_id);
104 }
Class ActiveRecord.
static findOrFail($primary_key, array $add_constructor_args=array())
Tries to find the object and throws an Exception if object is not found, instead of returning null.

References ActiveRecord\findOrFail().

Referenced by ilPermissionGUI\savePositionsPermissions(), and ilOrgUnitPermission\wakeUp().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ findByOperationString()

static ilOrgUnitOperationQueries::findByOperationString ( string  $operation_string,
string  $context_name 
)
static

Definition at line 106 of file class.ilOrgUnitOperationQueries.php.

109 : ?ActiveRecord /*ilOrgUnitOperation|ActiveRecord*/ {
111
112 return ilOrgUnitOperation::where(['operation_string' => $operation_string,
113 'context_id' => $context->getId()
114 ])->first();
115 }
static where($where, $operator=null)
$context
Definition: webdav.php:29

References $context, ilOrgUnitOperationContextQueries\findByName(), and ActiveRecord\where().

Referenced by ilOrgUnitPositionAccess\checkPositionAccess().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getOperationsForContextId()

static ilOrgUnitOperationQueries::getOperationsForContextId ( string  $context_id)
static
Returns
ilOrgUnitOperation[]

Definition at line 91 of file class.ilOrgUnitOperationQueries.php.

91 : array
92 {
94 return ilOrgUnitOperation::where(array('context_id' => $context->getPopulatedContextIds()))
95 ->get();
96 }

References $context, ilOrgUnitOperationContextQueries\findById(), and ActiveRecord\where().

Referenced by ilOrgUnitPermission\afterObjectLoad().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getOperationsForContextName()

static ilOrgUnitOperationQueries::getOperationsForContextName ( string  $context_name)
static
Returns
ilOrgUnitOperation[]

Definition at line 81 of file class.ilOrgUnitOperationQueries.php.

81 : array
82 {
84 return ilOrgUnitOperation::where(array('context_id' => $context->getPopulatedContextIds()))
85 ->get();
86 }

References $context, ilOrgUnitOperationContextQueries\findByName(), and ActiveRecord\where().

Referenced by ilOrgUnitPermissionTableGUI\collectData().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ registerNewOperationForMultipleContexts()

static ilOrgUnitOperationQueries::registerNewOperationForMultipleContexts ( string  $operation_name,
string  $description,
array  $contexts 
)
static
Parameters
array$contexts
Exceptions
ilException
See also
registerNewOperation

Definition at line 68 of file class.ilOrgUnitOperationQueries.php.

72 : void {
73 foreach ($contexts as $context) {
74 self::registerNewOperation($operation_name, $description, $context);
75 }
76 }

References $context.


The documentation for this class was generated from the following file: