|
ILIAS
release_5-1 Revision 5.0.0-5477-g43f3e3fab5f
|
Class ilObjStudyProgramme. More...
Inheritance diagram for ilObjStudyProgramme:
Collaboration diagram for ilObjStudyProgramme:Public Member Functions | |
| __construct ($a_id=0, $a_call_by_reference=true) | |
| ATTENTION: After using the constructor the object won't be in the cache. More... | |
| read () | |
| read More... | |
| create () | |
| Create. More... | |
| update () | |
| Update. More... | |
| delete () | |
| Delete Study Programme and all related data. More... | |
| getLastChange () | |
| Get the timestamp of the last change on this program or sub program. More... | |
| getPoints () | |
| Get the amount of points. More... | |
| setPoints ($a_points) | |
| Set the amount of points. More... | |
| getLPMode () | |
| Get the lp mode. More... | |
| adjustLPMode () | |
| Adjust the lp mode to match current state of tree: More... | |
| getStatus () | |
| Get the status. More... | |
| setStatus ($a_status) | |
| Set the status of the node. More... | |
| isActive () | |
| Check whether this programme is active. More... | |
| getSubtypeId () | |
| Gets the meta-data subtype id (allows to add additional meta-data based on a type) More... | |
| setSubtypeId ($a_subtype_id) | |
| Sets the meta-data subtype id. More... | |
| getSubType () | |
| Gets the SubType Object. More... | |
| getChildren () | |
| Get all ilObjStudyProgrammes that are direct children of this object. More... | |
| getParent () | |
| Get the parent ilObjStudyProgramme of this object. More... | |
| getParents () | |
| Get all parents of the node, where the root of the program comes first. More... | |
| hasChildren () | |
| Does this StudyProgramme have other ilObjStudyProgrammes as children? More... | |
| getAmountOfChildren () | |
| Get the amount of other StudyProgrammes this StudyProgramme has as children. More... | |
| getDepth () | |
| Get the depth of this StudyProgramme in the tree starting at the topmost StudyProgramme (not root node of the repo tree!). More... | |
| getRoot () | |
| Get the ilObjStudyProgramme that is the root node of the tree this programme is in. More... | |
| getLPChildren () | |
| Get the leafs the study programme contains. More... | |
| getLPChildrenIds () | |
| Get the ids of the leafs the program contains. More... | |
| getAmountOfLPChildren () | |
| Get the amount of leafs, the study programme contains. More... | |
| hasLPChildren () | |
| Does this StudyProgramme has leafs? More... | |
| applyToSubTreeNodes (Closure $fun) | |
| Apply the given Closure to every node in the subtree starting at this object. More... | |
| getCompletedCourses ($a_user_id) | |
| Get courses in this program that the given user already completed. More... | |
| addNode (ilObjStudyProgramme $a_prg) | |
| Inserts another ilObjStudyProgramme in this object. More... | |
| putInTree ($a_parent_ref) | |
| Overwritten from ilObject. More... | |
| removeNode (ilObjStudyProgramme $a_prg) | |
| Remove a node from this object. More... | |
| canBeRemoved () | |
| Check weather a node can be removed. More... | |
| addLeaf ( $a_leaf) | |
| Insert a leaf in this object. More... | |
| removeLeaf ( $a_leaf) | |
| Remove a leaf from this object. More... | |
| moveTo (ilObjStudyProgramme $a_new_parent) | |
| Move this tree node to a new parent. More... | |
| assignUser ($a_usr_id, $a_assigning_usr_id=null) | |
| Assign a user to this node at the study program. More... | |
| removeAssignment (ilStudyProgrammeUserAssignment $a_assignment) | |
| Remove an assignment from this program. More... | |
| hasAssignmentOf ($a_user_id) | |
| Check whether user is assigned to this program or any node above. More... | |
| getAmountOfAssignmentsOf ($a_user_id) | |
| Get the amount of assignments a user has on this program node or any node above. More... | |
| getAssignmentsOf ($a_user_id) | |
| Get the assignments of user at this program or any node above. More... | |
| getAssignments () | |
| Get all assignments to this program or any node above. More... | |
| hasAssignments () | |
| Are there any assignments on this node or any node above? More... | |
| updateAllAssignments () | |
| Update all assignments to this program node. More... | |
| createProgressForAssignment (ilStudyProgrammeAssignment $ass) | |
| Create a progress on this programme for the given assignment. More... | |
| getProgressesOf ($a_user_id) | |
| Get the progresses the user has on this node. More... | |
| getProgressForAssignment ($a_assignment_id) | |
| Get the progress for an assignment on this node. More... | |
| addMissingProgresses () | |
| Add missing progress records for all assignments of this programm. More... | |
| getProgresses () | |
| Get all progresses on this node. More... | |
| hasProgresses () | |
| Are there any users that have a progress on this programme? More... | |
| hasRelevantProgresses () | |
| Are there any users that have a relevant progress on this programme? More... | |
| getIdsOfUsersWithRelevantProgress () | |
| Get the ids of all users that have a relevant progress at this programme. More... | |
| getIdsOfUsersWithCompletedProgress () | |
| Get the ids of all users that have completed this programme. More... | |
| getIdsOfUsersWithNotCompletedAndRelevantProgress () | |
| Get the ids of all users that have not completed this programme but have a relevant progress on it. More... | |
| getRawSettings () | |
| Get the underlying model of this program. More... | |
| updateCustomIcon () | |
| updates the selected custom icon in container folder by type More... | |
| saveIcons ($a_custom_icon) | |
| save container icons More... | |
Public Member Functions inherited from ilContainer | |
| ilContainer ($a_id=0, $a_call_by_reference=true) | |
| Constructor @access public. More... | |
| createContainerDirectory () | |
| Create directory for the container. More... | |
| getContainerDirectory () | |
| Get the container directory. More... | |
| _getContainerDirectory ($a_id) | |
| Get the container directory. More... | |
| getBigIconPath () | |
| Get path for big icon. More... | |
| getSmallIconPath () | |
| Get path for small icon. More... | |
| getTinyIconPath () | |
| Get path for tiny icon. More... | |
| getCustomIconPath () | |
| Get path for custom icon. More... | |
| setHiddenFilesFound ($a_hiddenfilesfound) | |
| Set Found hidden files (set by getSubItems). More... | |
| getHiddenFilesFound () | |
| Get Found hidden files (set by getSubItems). More... | |
| getStyleSheetId () | |
| get ID of assigned style sheet object More... | |
| setStyleSheetId ($a_style_id) | |
| set ID of assigned style sheet object More... | |
| _lookupContainerSetting ($a_id, $a_keyword, $a_default_value=NULL) | |
| Lookup a container setting. More... | |
| _writeContainerSetting ($a_id, $a_keyword, $a_value) | |
| _lookupIconPath ($a_id, $a_size="big") | |
| lookup icon path More... | |
| saveIcons ($a_custom_icon) | |
| save container icons More... | |
| removeCustomIcon () | |
| remove small icon More... | |
| cloneObject ($a_target_id, $a_copy_id=0) | |
| Clone container settings. More... | |
| cloneDependencies ($a_target_id, $a_copy_id) | |
| Clone object dependencies (container sorting) More... | |
| cloneAllObject ($session_id, $client_id, $new_type, $ref_id, $clone_source, $options, $soap_call=false, $a_submode=1) | |
| clone all objects according to this container More... | |
| getViewMode () | |
| Get container view mode. More... | |
| getOrderType () | |
| Get order type default implementation. More... | |
| setOrderType ($a_value) | |
| getSubItems ($a_admin_panel_enabled=false, $a_include_side_block=false, $a_get_single=0) | |
| Get subitems of container. More... | |
| gotItems () | |
| Check whether we got any items. More... | |
| addAdditionalSubItemInformation (&$object) | |
| Add additional information to sub item, e.g. More... | |
| getGroupedObjTypes () | |
| Get grouped repository object types. More... | |
| enablePageEditing () | |
| Check whether page editing is allowed for container. More... | |
| create () | |
| Create. More... | |
| update () | |
| Update. More... | |
| read () | |
| read More... | |
Public Member Functions inherited from ilObject | |
| ilObject ($a_id=0, $a_reference=true) | |
| Constructor @access public. More... | |
| withReferences () | |
| determines wehter objects are referenced or not (got ref ids or not) More... | |
| read ($a_force_db=false) | |
| read object data from db into object More... | |
| getId () | |
| get object id @access public More... | |
| setId ($a_id) | |
| set object id @access public More... | |
| setRefId ($a_id) | |
| set reference id @access public More... | |
| getRefId () | |
| get reference id @access public More... | |
| getType () | |
| get object type @access public More... | |
| setType ($a_type) | |
| set object type @access public More... | |
| getPresentationTitle () | |
| get presentation title Normally same as title Overwritten for sessions More... | |
| getTitle () | |
| get object title @access public More... | |
| getUntranslatedTitle () | |
| get untranslated object title @access public More... | |
| setTitle ($a_title) | |
| set object title More... | |
| getDescription () | |
| get object description More... | |
| setDescription ($a_desc) | |
| set object description More... | |
| getLongDescription () | |
| get object long description (stored in object_description) More... | |
| getImportId () | |
| get import id More... | |
| setImportId ($a_import_id) | |
| set import id More... | |
| getOwner () | |
| get object owner More... | |
| getOwnerName () | |
| _lookupOwnerName ($a_owner_id) | |
| lookup owner name for owner id More... | |
| setOwner ($a_owner) | |
| set object owner More... | |
| getCreateDate () | |
| get create date @access public More... | |
| getLastUpdateDate () | |
| get last update date @access public More... | |
| getDiskUsage () | |
| setObjDataRecord ($a_record) | |
| set object_data record (note: this method should only be called from the ilObjectFactory class) More... | |
| create () | |
| create More... | |
| update () | |
| update object in db More... | |
| MDUpdateListener ($a_element) | |
| Meta data update listener. More... | |
| createMetaData () | |
| create meta data entry More... | |
| updateMetaData () | |
| update meta data entry More... | |
| deleteMetaData () | |
| delete meta data entry More... | |
| updateOwner () | |
| update owner of object in db More... | |
| _getIdForImportId ($a_import_id) | |
| get current object id for import id (static) More... | |
| _lookupOwner ($a_id) | |
| lookup object owner More... | |
| _lookupLastUpdate ($a_id, $a_as_string=false) | |
| lookup last update More... | |
| _getLastUpdateOfObjects ($a_objs) | |
| Get last update for a set of media objects. More... | |
| _setDeletedDate ($a_ref_id) | |
| only called in ilTree::saveSubTree More... | |
| _resetDeletedDate ($a_ref_id) | |
| only called in ilObjectGUI::insertSavedNodes More... | |
| _lookupDeletedDate ($a_ref_id) | |
| only called in ilObjectGUI::insertSavedNodes More... | |
| _writeTitle ($a_obj_id, $a_title) | |
| write title to db (static) More... | |
| _writeDescription ($a_obj_id, $a_desc) | |
| write description to db (static) More... | |
| _writeImportId ($a_obj_id, $a_import_id) | |
| write import id to db (static) More... | |
| _isInTrash ($a_ref_id) | |
| checks wether object is in trash More... | |
| _hasUntrashedReference ($a_obj_id) | |
| checks wether an object has at least one reference that is not in trash More... | |
| _getObjectsDataForType ($a_type, $a_omit_trash=false) | |
| get all objects of a certain type More... | |
| putInTree ($a_parent_ref) | |
| maybe this method should be in tree object!? More... | |
| setPermissions ($a_parent_ref) | |
| set permissions of object More... | |
| setParentRolePermissions ($a_parent_ref) | |
| Initialize the permissions of parent roles (local roles of categories, global roles...) This method is overwritten in e.g courses, groups for building permission intersections with non_member templates. More... | |
| createReference () | |
| creates reference for object More... | |
| countReferences () | |
| count references of object More... | |
| delete () | |
| delete object or referenced object (in the case of a referenced object, object data is only deleted if last reference is deleted) This function removes an object entirely from system!! More... | |
| initDefaultRoles () | |
| init default roles settings Purpose of this function is to create a local role folder and local roles, that are needed depending on the object type If you want to setup default local roles you MUST overwrite this method in derived object classes (see ilObjForum for an example) @access public More... | |
| applyDidacticTemplate ($a_tpl_id) | |
| Apply template. More... | |
| notify ($a_event, $a_ref_id, $a_parent_non_rbac_id, $a_node_id, $a_params=0) | |
| notifys an object about an event occured Based on the event passed, each object may decide how it reacts. More... | |
| setRegisterMode ($a_bool) | |
| isUserRegistered ($a_user_id=0) | |
| requireRegistration () | |
| getXMLZip () | |
| getHTMLDirectory () | |
| cloneObject ($a_target_id, $a_copy_id=0, $a_omit_tree=false) | |
| Clone object permissions, put in tree ... More... | |
| appendCopyInfo ($a_target_id, $a_copy_id) | |
| Prepend Copy info if object with same name exists in that container. More... | |
| cloneDependencies ($a_target_id, $a_copy_id) | |
| Clone object dependencies. More... | |
| cloneMetaData ($target_obj) | |
| Copy meta data. More... | |
| _lookupCreationDate ($a_id) | |
| Lookup creation date. More... | |
| getPossibleSubObjects ($a_filter=true) | |
| get all possible subobjects of this type the object can decide which types of subobjects are possible jut in time overwrite if the decision distinguish from standard model More... | |
Static Public Member Functions | |
| static | initStudyProgrammeCache () |
| static | getInstanceByRefId ($a_ref_id) |
| Get an instance of ilObjStudyProgramme, use cache. More... | |
| static | createInstance () |
| Create an instance of ilObjStudyProgramme, put in cache. More... | |
| static | getAllChildren ($a_ref_id) |
| Get a list of all ilObjStudyProgrammes in the subtree starting at $a_ref_id. More... | |
| static | setProgressesCompletedFor ($a_obj_id, $a_user_id) |
| Set all progresses to completed where the object with given id is a leaf and that belong to the user. More... | |
| static | getCreatableSubObjects ($a_subobjects, $a_ref_id) |
| Filter the list of possible subobjects for the objects that actually could be created on a concrete node. More... | |
Static Public Member Functions inherited from ilContainer | |
| static | _getContainerSettings ($a_id) |
| static | _deleteContainerSettings ($a_id, $a_keyword=null, $a_keyword_like=false) |
| static | _exportContainerSettings (ilXmlWriter $a_xml, $a_obj_id) |
| static | getCompleteDescriptions (array $objects) |
| overwrites description fields to long or short description in an assoc array keys needed (obj_id and description) More... | |
Static Public Member Functions inherited from ilObject | |
| static | _lookupObjIdByImportId ($a_import_id) |
| static | _lookupImportId ($a_obj_id) |
| static | _getAllReferences ($a_id) |
| get all reference ids of object More... | |
| static | _lookupTitle ($a_id) |
| lookup object title More... | |
| static | _getIdsForTitle ($title, $type='', $partialmatch=false) |
| static | _lookupDescription ($a_id) |
| lookup object description More... | |
| static | _lookupObjId ($a_id) |
| static | setDeletedDates ($a_ref_ids) |
| Set deleted date @global type $ilDB. More... | |
| static | _lookupType ($a_id, $a_reference=false) |
| lookup object type More... | |
| static | _lookupObjectId ($a_ref_id) |
| lookup object id More... | |
| static | _exists ($a_id, $a_reference=false, $a_type=null) |
| checks if an object exists in object_data@access public More... | |
| static | _getObjectsByType ($a_obj_type="", $a_owner="") |
| Get objects by type. More... | |
| static | _prepareCloneSelection ($a_ref_ids, $new_type, $show_path=true) |
| Prepare copy wizard object selection. More... | |
| static | _getIcon ($a_obj_id="", $a_size="big", $a_type="", $a_offline=false) |
| Get icon for repository item. More... | |
| static | collectDeletionDependencies (&$deps, $a_ref_id, $a_obj_id, $a_type, $a_depth=0) |
| Collect deletion dependencies. More... | |
| static | getDeletionDependencies ($a_obj_id) |
| Get deletion dependencies. More... | |
| static | getLongDescriptions (array $a_obj_ids) |
| Get long description data. More... | |
| static | getAllOwnedRepositoryObjects ($a_user_id) |
| Get all ids of objects user owns. More... | |
| static | fixMissingTitles ($a_type, array &$a_obj_title_map) |
| Try to fix missing object titles. More... | |
| static | hasAutoRating ($a_type, $a_ref_id) |
| Check if auto rating is active for parent group/course. More... | |
Static Public Attributes | |
| static | $study_programme_cache = null |
Static Public Attributes inherited from ilContainer | |
| static | $data_preloaded = false |
Protected Member Functions | |
| clearParentCache () | |
| Clear the cached parent to query it again at the tree. More... | |
| clearChildrenCache () | |
| Clear the cached children. More... | |
| clearLPChildrenCache () | |
| Clear the cached lp children. More... | |
| readSettings () | |
| Load Settings from DB. More... | |
| createSettings () | |
| Create new settings object. More... | |
| updateSettings () | |
| Update settings in DB. More... | |
| deleteSettings () | |
| Delete settings from DB. More... | |
| deleteAssignments () | |
| Delete all assignments from the DB. More... | |
| throwIfNotInTree () | |
| Helper function to check, weather object is in tree. More... | |
| nodeInserted (ilObjStudyProgramme $a_prg) | |
| Clears child chache and adds progress for new node. More... | |
| updateLastChange () | |
| Update last change timestamp on this node and its parents. More... | |
| getIdsFromNodesOnPathFromRootToHere () | |
| Get the ids from the nodes in the path leading from the root node of this program to this node, including the id of this node. More... | |
| getAssignmentsRaw () | |
| Get model objects for the assignments on this programm. More... | |
Static Protected Member Functions | |
| static | setProgressesCompletedIfParentIsProgrammeInLPCompletedMode ($a_ref_id, $a_obj_id, $a_user_id) |
| static | getParentId (ilObject $a_object) |
| Get the obj id of the parent object for the given object. More... | |
Protected Attributes | |
| $settings | |
| $parent | |
| $children | |
| $lp_children | |
Protected Attributes inherited from ilContainer | |
| $order_type = 0 | |
| $hiddenfilesfound = false | |
Class ilObjStudyProgramme.
Definition at line 18 of file class.ilObjStudyProgramme.php.
| ilObjStudyProgramme::__construct | ( | $a_id = 0, |
|
$a_call_by_reference = true |
|||
| ) |
ATTENTION: After using the constructor the object won't be in the cache.
This could lead to unexpected behaviour when using the tree navigation.
| int | $a_id | |
| bool | $a_call_by_reference |
Definition at line 40 of file class.ilObjStudyProgramme.php.
References $ilUser, $tree, clearChildrenCache(), clearLPChildrenCache(), clearParentCache(), ilContainer\ilContainer(), initStudyProgrammeCache(), and ilObjectFactoryWrapper\singleton().
Here is the call graph for this function:| ilObjStudyProgramme::addLeaf | ( | $a_leaf | ) |
Insert a leaf in this object.
Throws when object already contain ilObjStudyProgrammes as children. Throws when this object is not in tree.
| ilStudyProgrammeTreeException |
Definition at line 759 of file class.ilObjStudyProgramme.php.
References clearLPChildrenCache(), ilObject\getRefId(), hasChildren(), ilStudyProgramme\MODE_LP_COMPLETED, throwIfNotInTree(), and update().
Here is the call graph for this function:| ilObjStudyProgramme::addMissingProgresses | ( | ) |
Add missing progress records for all assignments of this programm.
Use this after the structure of the programme was modified.
Definition at line 1034 of file class.ilObjStudyProgramme.php.
References getAssignments().
Referenced by nodeInserted().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::addNode | ( | ilObjStudyProgramme | $a_prg | ) |
Inserts another ilObjStudyProgramme in this object.
Throws when object already contains non ilObjStudyProgrammes as children. Throws when $a_prg already is in the tree. Throws when this object is not in tree.
| ilStudyProgrammeTreeException |
Definition at line 653 of file class.ilObjStudyProgramme.php.
References ilObject\createReference(), getLPMode(), ilObject\getRefId(), ilStudyProgramme\MODE_LP_COMPLETED, putInTree(), and throwIfNotInTree().
Here is the call graph for this function:| ilObjStudyProgramme::adjustLPMode | ( | ) |
Adjust the lp mode to match current state of tree:
If there are any non programme children, the mode is MODE_LP_COMPLETED, otherwise its MODE_POINTS.
| ilException | when programme is not in draft mode. |
Definition at line 279 of file class.ilObjStudyProgramme.php.
References getAmountOfChildren(), getAmountOfLPChildren(), ilStudyProgramme\MODE_LP_COMPLETED, ilStudyProgramme\MODE_POINTS, and ilStudyProgramme\MODE_UNDEFINED.
Here is the call graph for this function:| ilObjStudyProgramme::applyToSubTreeNodes | ( | Closure | $fun | ) |
Apply the given Closure to every node in the subtree starting at this object.
When the closure returns false, the underlying nodes won't be visited.
Throws when this object is not in tree.
| Closure | $fun | - An anonymus function taking an ilObjStudyProgramme as parameter. |
Definition at line 600 of file class.ilObjStudyProgramme.php.
References getChildren(), and throwIfNotInTree().
Referenced by assignUser().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::assignUser | ( | $a_usr_id, | |
$a_assigning_usr_id = null |
|||
| ) |
Assign a user to this node at the study program.
Throws when node is in DRAFT or OUTDATED status. Throws when there are no settings for the program.
TODO: Should it be allowed to assign inactive users?
| ilException |
| int | $a_usr_id | |
| int | null | $a_assigning_usr_id | - defaults to global ilUser |
Definition at line 853 of file class.ilObjStudyProgramme.php.
References applyToSubTreeNodes(), ilStudyProgrammeAssignment\createFor(), createProgressForAssignment(), ilObject\getId(), getStatus(), ilStudyProgramme\STATUS_ACTIVE, and ilStudyProgrammeEvents\userAssigned().
Here is the call graph for this function:| ilObjStudyProgramme::canBeRemoved | ( | ) |
Check weather a node can be removed.
This is allowed when all progresses on the node are marked as not relevant programmatically.
Definition at line 738 of file class.ilObjStudyProgramme.php.
References getProgresses(), and ilStudyProgrammeProgress\STATUS_NOT_RELEVANT.
Referenced by removeNode().
Here is the call graph for this function:
Here is the caller graph for this function:
|
protected |
Clear the cached children.
Definition at line 74 of file class.ilObjStudyProgramme.php.
Referenced by __construct(), moveTo(), nodeInserted(), and removeNode().
Here is the caller graph for this function:
|
protected |
Clear the cached lp children.
Definition at line 81 of file class.ilObjStudyProgramme.php.
Referenced by __construct(), addLeaf(), moveTo(), and removeLeaf().
Here is the caller graph for this function:
|
protected |
Clear the cached parent to query it again at the tree.
Definition at line 66 of file class.ilObjStudyProgramme.php.
Referenced by __construct(), moveTo(), and removeNode().
Here is the caller graph for this function:| ilObjStudyProgramme::create | ( | ) |
Create.
Reimplemented from ilContainer.
Definition at line 184 of file class.ilObjStudyProgramme.php.
References ilObject\$id, and createSettings().
Here is the call graph for this function:
|
static |
Create an instance of ilObjStudyProgramme, put in cache.
Definition at line 103 of file class.ilObjStudyProgramme.php.
Referenced by ilObjStudyProgrammeTest\createSmallTree(), ilObjStudyProgrammeTest\setUp(), ilStudyProgrammeEventsTest\setUp(), ilStudyProgrammeLPTest\setUp(), ilStudyProgrammeProgressCalculationTest\setUp(), ilStudyProgrammeUserAssignmentTest\setUp(), ilStudyProgrammeUserProgressTest\setUp(), ilStudyProgrammeProgressCalculationTest\setUpNodes(), ilStudyProgrammeUserProgressTest\testCanBeCompleted3(), ilStudyProgrammeUserProgressTest\testCompletionOnDeeplyNestedProgresses(), ilStudyProgrammeLPTest\testNewNodesAreNotRelevant(), ilStudyProgrammeUserProgressTest\testNewNodesAreNotRelevant(), and ilObjStudyProgrammeTest\testTreeGetParents().
Here is the caller graph for this function:| ilObjStudyProgramme::createProgressForAssignment | ( | ilStudyProgrammeAssignment | $ass | ) |
Create a progress on this programme for the given assignment.
| ilStudyProgrammeAssignment |
Definition at line 998 of file class.ilObjStudyProgramme.php.
References ilStudyProgrammeProgress\createFor().
Referenced by assignUser().
Here is the call graph for this function:
Here is the caller graph for this function:
|
protected |
Create new settings object.
Throws when settings are already loaded or id is null.
Definition at line 135 of file class.ilObjStudyProgramme.php.
References ilObject\$id, ilStudyProgramme\createForObject(), and ilObject\getId().
Referenced by create().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::delete | ( | ) |
Delete Study Programme and all related data.
Reimplemented from ilObject.
Definition at line 211 of file class.ilObjStudyProgramme.php.
References deleteAssignments(), and deleteSettings().
Here is the call graph for this function:
|
protected |
Delete all assignments from the DB.
Definition at line 172 of file class.ilObjStudyProgramme.php.
References getAssignments().
Referenced by delete().
Here is the call graph for this function:
Here is the caller graph for this function:
|
protected |
Delete settings from DB.
Throws when settings are not loaded.
Definition at line 162 of file class.ilObjStudyProgramme.php.
Referenced by delete().
Here is the caller graph for this function:
|
static |
Get a list of all ilObjStudyProgrammes in the subtree starting at $a_ref_id.
Throws when object is not in tree.
| int | $a_ref_id |
Definition at line 375 of file class.ilObjStudyProgramme.php.
References $ret, and getInstanceByRefId().
Referenced by ilObjStudyProgrammeTreeGUI\confirmedDelete(), ilObjStudyProgrammeTest\testMoveTo(), and ilObjStudyProgrammeTest\testTreeGetChildren().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::getAmountOfAssignmentsOf | ( | $a_user_id | ) |
Get the amount of assignments a user has on this program node or any node above.
| int | $a_user_id |
Definition at line 929 of file class.ilObjStudyProgramme.php.
References getAssignmentsOf().
Referenced by hasAssignmentOf().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::getAmountOfChildren | ( | ) |
Get the amount of other StudyProgrammes this StudyProgramme has as children.
Throws when this object is not in tree.
Definition at line 474 of file class.ilObjStudyProgramme.php.
References getChildren().
Referenced by adjustLPMode(), and hasChildren().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::getAmountOfLPChildren | ( | ) |
Get the amount of leafs, the study programme contains.
Throws when this object is not in tree.
Definition at line 561 of file class.ilObjStudyProgramme.php.
References getLPChildren().
Referenced by adjustLPMode(), and hasLPChildren().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::getAssignments | ( | ) |
Get all assignments to this program or any node above.
Definition at line 960 of file class.ilObjStudyProgramme.php.
References getAssignmentsRaw().
Referenced by addMissingProgresses(), deleteAssignments(), and hasAssignments().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::getAssignmentsOf | ( | $a_user_id | ) |
Get the assignments of user at this program or any node above.
The assignments are ordered by last_change, where the most recently changed assignments is the first one.
| int | $a_user_id |
Definition at line 941 of file class.ilObjStudyProgramme.php.
References getIdsFromNodesOnPathFromRootToHere(), and ActiveRecord\where().
Referenced by getAmountOfAssignmentsOf().
Here is the call graph for this function:
Here is the caller graph for this function:
|
protected |
Get model objects for the assignments on this programm.
Definition at line 1149 of file class.ilObjStudyProgramme.php.
References getIdsFromNodesOnPathFromRootToHere(), and ActiveRecord\where().
Referenced by getAssignments().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::getChildren | ( | ) |
Get all ilObjStudyProgrammes that are direct children of this object.
Throws when this object is not in tree.
Definition at line 397 of file class.ilObjStudyProgramme.php.
References $children, ilContainerSorting\_getInstance(), ilObject\getId(), getInstanceByRefId(), ilObject\getRefId(), and throwIfNotInTree().
Referenced by applyToSubTreeNodes(), and getAmountOfChildren().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::getCompletedCourses | ( | $a_user_id | ) |
Get courses in this program that the given user already completed.
| int | $a_user_id |
Definition at line 616 of file class.ilObjStudyProgramme.php.
References ilLPStatus\_hasUserCompleted(), ilContainerReference\_lookupTargetId(), ilContainerReference\_lookupTargetTitle(), and ilObject\getRefId().
Here is the call graph for this function:
|
static |
Filter the list of possible subobjects for the objects that actually could be created on a concrete node.
Will be called by ilObjDefinition::getCreatableSubObjects.
| array | $a_subobjects | |
| int | $a_ref_id |
Definition at line 1256 of file class.ilObjStudyProgramme.php.
References $parent, ilObject\_lookupType(), getInstanceByRefId(), ilStudyProgramme\MODE_LP_COMPLETED, ilStudyProgramme\MODE_POINTS, and ilStudyProgramme\MODE_UNDEFINED.
Referenced by ilObjectDefinition\getCreatableSubObjects(), ilObjStudyProgrammeTest\testCreatableSubObjectsRaisesOnNonProgramRef(), ilObjStudyProgrammeTest\testCreatableSubObjectsWithoutRef(), and ilObjStudyProgrammeTest\testCreateableSubObjects().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::getDepth | ( | ) |
Get the depth of this StudyProgramme in the tree starting at the topmost StudyProgramme (not root node of the repo tree!).
Root node has depth = 0.
Throws when this object is not in tree.
Definition at line 486 of file class.ilObjStudyProgramme.php.
|
protected |
Get the ids from the nodes in the path leading from the root node of this program to this node, including the id of this node.
Definition at line 1138 of file class.ilObjStudyProgramme.php.
References ilObject\getId(), and getParents().
Referenced by getAssignmentsOf(), and getAssignmentsRaw().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::getIdsOfUsersWithCompletedProgress | ( | ) |
Get the ids of all users that have completed this programme.
Definition at line 1093 of file class.ilObjStudyProgramme.php.
References getProgresses().
Here is the call graph for this function:| ilObjStudyProgramme::getIdsOfUsersWithNotCompletedAndRelevantProgress | ( | ) |
Get the ids of all users that have not completed this programme but have a relevant progress on it.
Definition at line 1109 of file class.ilObjStudyProgramme.php.
References getProgresses().
Here is the call graph for this function:| ilObjStudyProgramme::getIdsOfUsersWithRelevantProgress | ( | ) |
Get the ids of all users that have a relevant progress at this programme.
Definition at line 1078 of file class.ilObjStudyProgramme.php.
References getProgresses().
Here is the call graph for this function:
|
static |
Get an instance of ilObjStudyProgramme, use cache.
| int | $a_ref_id |
Definition at line 92 of file class.ilObjStudyProgramme.php.
References initStudyProgrammeCache().
Referenced by ilObjStudyProgrammeAccess\_checkAccess(), getAllChildren(), getChildren(), getCreatableSubObjects(), ilObjStudyProgrammeSettingsGUI\getObject(), getParent(), ilObjStudyProgrammeTreeExplorerGUI\getRootNode(), ilStudyProgrammeAppEventListener\getStudyProgramme(), ilObjStudyProgrammeMembersGUI\getStudyProgramme(), ilStudyProgrammeUserAssignment\getStudyProgramme(), ilStudyProgrammeUserProgress\getStudyProgramme(), putInTree(), setProgressesCompletedIfParentIsProgrammeInLPCompletedMode(), ilObjStudyProgrammeTest\testDelete(), ilObjStudyProgrammeTest\testGetInstanceByRefId(), ilObjStudyProgrammeTest\testLoadByObjId(), and ilObjStudyProgrammeTest\testSettings().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::getLastChange | ( | ) |
Get the timestamp of the last change on this program or sub program.
Definition at line 236 of file class.ilObjStudyProgramme.php.
| ilObjStudyProgramme::getLPChildren | ( | ) |
Get the leafs the study programme contains.
Throws when this object is not in tree.
Definition at line 515 of file class.ilObjStudyProgramme.php.
References $lp_children, ilContainerSorting\_getInstance(), ilObject\getId(), ilObject\getRefId(), and throwIfNotInTree().
Referenced by getAmountOfLPChildren(), and getLPChildrenIds().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::getLPChildrenIds | ( | ) |
Get the ids of the leafs the program contains.
Throws when object is not in tree.
Definition at line 550 of file class.ilObjStudyProgramme.php.
References getLPChildren().
Here is the call graph for this function:| ilObjStudyProgramme::getLPMode | ( | ) |
Get the lp mode.
Definition at line 267 of file class.ilObjStudyProgramme.php.
Referenced by addNode(), and nodeInserted().
Here is the caller graph for this function:| ilObjStudyProgramme::getParent | ( | ) |
Get the parent ilObjStudyProgramme of this object.
Returns null if parent is no StudyProgramme.
Throws when this object is not in tree.
Definition at line 424 of file class.ilObjStudyProgramme.php.
References $parent, getInstanceByRefId(), ilObject\getRefId(), and throwIfNotInTree().
Referenced by moveTo(), removeNode(), and updateLastChange().
Here is the call graph for this function:
Here is the caller graph for this function:
|
staticprotected |
Get the obj id of the parent object for the given object.
Returns null if object is not in the tree currently.
Definition at line 1202 of file class.ilObjStudyProgramme.php.
References $nd, $tree, and ilObject\getRefId().
Here is the call graph for this function:| ilObjStudyProgramme::getParents | ( | ) |
Get all parents of the node, where the root of the program comes first.
Definition at line 443 of file class.ilObjStudyProgramme.php.
Referenced by getIdsFromNodesOnPathFromRootToHere(), and getRoot().
Here is the caller graph for this function:| ilObjStudyProgramme::getPoints | ( | ) |
Get the amount of points.
Definition at line 245 of file class.ilObjStudyProgramme.php.
| ilObjStudyProgramme::getProgresses | ( | ) |
Get all progresses on this node.
Definition at line 1045 of file class.ilObjStudyProgramme.php.
References ilObject\getId(), and ilStudyProgrammeUserProgress\getInstancesForProgram().
Referenced by canBeRemoved(), getIdsOfUsersWithCompletedProgress(), getIdsOfUsersWithNotCompletedAndRelevantProgress(), getIdsOfUsersWithRelevantProgress(), hasProgresses(), and hasRelevantProgresses().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::getProgressesOf | ( | $a_user_id | ) |
Get the progresses the user has on this node.
| int | $a_user_id |
Definition at line 1008 of file class.ilObjStudyProgramme.php.
References ilObject\getId(), and ilStudyProgrammeUserProgress\getInstancesForUser().
Here is the call graph for this function:| ilObjStudyProgramme::getProgressForAssignment | ( | $a_assignment_id | ) |
Get the progress for an assignment on this node.
Throws when assignment does not belong to this program.
| ilException |
| int | $a_assignment_id |
Definition at line 1022 of file class.ilObjStudyProgramme.php.
References ilObject\getId(), and ilStudyProgrammeUserProgress\getInstanceForAssignment().
Here is the call graph for this function:| ilObjStudyProgramme::getRawSettings | ( | ) |
Get the underlying model of this program.
ATTENTION: Only use the model object if you know what you are doing.
Definition at line 1219 of file class.ilObjStudyProgramme.php.
References $settings.
| ilObjStudyProgramme::getRoot | ( | ) |
Get the ilObjStudyProgramme that is the root node of the tree this programme is in.
Throws when this object is not in tree.
Definition at line 503 of file class.ilObjStudyProgramme.php.
References getParents().
Here is the call graph for this function:| ilObjStudyProgramme::getStatus | ( | ) |
Get the status.
Definition at line 301 of file class.ilObjStudyProgramme.php.
Referenced by assignUser(), and isActive().
Here is the caller graph for this function:| ilObjStudyProgramme::getSubType | ( | ) |
Gets the SubType Object.
Definition at line 353 of file class.ilObjStudyProgramme.php.
References getSubtypeId().
Referenced by update(), and updateCustomIcon().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::getSubtypeId | ( | ) |
Gets the meta-data subtype id (allows to add additional meta-data based on a type)
Definition at line 331 of file class.ilObjStudyProgramme.php.
Referenced by getSubType().
Here is the caller graph for this function:| ilObjStudyProgramme::hasAssignmentOf | ( | $a_user_id | ) |
Check whether user is assigned to this program or any node above.
| int | $a_user_id |
Definition at line 918 of file class.ilObjStudyProgramme.php.
References getAmountOfAssignmentsOf().
Here is the call graph for this function:| ilObjStudyProgramme::hasAssignments | ( | ) |
Are there any assignments on this node or any node above?
Definition at line 971 of file class.ilObjStudyProgramme.php.
References getAssignments().
Here is the call graph for this function:| ilObjStudyProgramme::hasChildren | ( | ) |
Does this StudyProgramme have other ilObjStudyProgrammes as children?
Throws when this object is not in tree.
Definition at line 462 of file class.ilObjStudyProgramme.php.
References getAmountOfChildren().
Referenced by addLeaf().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::hasLPChildren | ( | ) |
Does this StudyProgramme has leafs?
Throws when this object is not in tree.
Definition at line 572 of file class.ilObjStudyProgramme.php.
References getAmountOfLPChildren().
Here is the call graph for this function:| ilObjStudyProgramme::hasProgresses | ( | ) |
Are there any users that have a progress on this programme?
Definition at line 1055 of file class.ilObjStudyProgramme.php.
References getProgresses().
Here is the call graph for this function:| ilObjStudyProgramme::hasRelevantProgresses | ( | ) |
Are there any users that have a relevant progress on this programme?
Definition at line 1064 of file class.ilObjStudyProgramme.php.
References getProgresses().
Here is the call graph for this function:
|
static |
Definition at line 57 of file class.ilObjStudyProgramme.php.
References ilObjStudyProgrammeCache\singleton().
Referenced by __construct(), getInstanceByRefId(), and setProgressesCompletedIfParentIsProgrammeInLPCompletedMode().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::isActive | ( | ) |
Check whether this programme is active.
Definition at line 322 of file class.ilObjStudyProgramme.php.
References getStatus(), and ilStudyProgramme\STATUS_ACTIVE.
Here is the call graph for this function:| ilObjStudyProgramme::moveTo | ( | ilObjStudyProgramme | $a_new_parent | ) |
Move this tree node to a new parent.
Throws, when manipulation of tree is not allowed due to invariants that need to hold on the tree.
| ilStudyProgrammeTreeException |
| int | $a_new_parent_ref_id |
Definition at line 810 of file class.ilObjStudyProgramme.php.
References $parent, clearChildrenCache(), clearLPChildrenCache(), clearParentCache(), getParent(), and ilObject\getRefId().
Here is the call graph for this function:
|
protected |
Clears child chache and adds progress for new node.
Definition at line 674 of file class.ilObjStudyProgramme.php.
References addMissingProgresses(), clearChildrenCache(), getLPMode(), ilStudyProgramme\MODE_LP_COMPLETED, and ilStudyProgramme\MODE_POINTS.
Here is the call graph for this function:| ilObjStudyProgramme::putInTree | ( | $a_parent_ref | ) |
Overwritten from ilObject.
Calls nodeInserted on parent object if parent object is another program.
Reimplemented from ilObject.
Definition at line 693 of file class.ilObjStudyProgramme.php.
References $res, ilObject\_lookupType(), and getInstanceByRefId().
Referenced by addNode().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::read | ( | ) |
read
@access public
return
Reimplemented from ilContainer.
Definition at line 178 of file class.ilObjStudyProgramme.php.
References readSettings().
Here is the call graph for this function:
|
protected |
Load Settings from DB.
Throws when settings are already loaded or id is null.
Definition at line 120 of file class.ilObjStudyProgramme.php.
References ilObject\$id, and ilObject\getId().
Referenced by read().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::removeAssignment | ( | ilStudyProgrammeUserAssignment | $a_assignment | ) |
Remove an assignment from this program.
Throws when assignment doesn't have this program as root node.
| ilException |
Definition at line 896 of file class.ilObjStudyProgramme.php.
References ilStudyProgrammeUserAssignment\delete(), ilStudyProgrammeUserAssignment\getId(), ilStudyProgrammeUserAssignment\getStudyProgramme(), and ilStudyProgrammeEvents\userDeassigned().
Here is the call graph for this function:| ilObjStudyProgramme::removeLeaf | ( | $a_leaf | ) |
Remove a leaf from this object.
Throws when leaf is not a child of this object. Throws, when manipulation of tree is not allowed due to invariants that need to hold on the tree.
| ilException | |
| ilStudyProgrammeTreeException |
Definition at line 788 of file class.ilObjStudyProgramme.php.
References clearLPChildrenCache(), and ilObject\getId().
Here is the call graph for this function:| ilObjStudyProgramme::removeNode | ( | ilObjStudyProgramme | $a_prg | ) |
Remove a node from this object.
Throws when node is no child of the object. Throws, when manipulation of tree is not allowed due to invariants that need to hold on the tree.
| ilException | |
| ilStudyProgrammTreeException |
Definition at line 714 of file class.ilObjStudyProgramme.php.
References canBeRemoved(), clearChildrenCache(), clearParentCache(), getParent(), and ilObject\getRefId().
Here is the call graph for this function:| ilObjStudyProgramme::saveIcons | ( | $a_custom_icon | ) |
save container icons
Reimplemented from ilContainer.
Definition at line 1289 of file class.ilObjStudyProgramme.php.
References $ilDB, ilContainer\_writeContainerSetting(), ilContainer\createContainerDirectory(), ilContainer\getContainerDirectory(), ilObject\getId(), and ilUtil\moveUploadedFile().
Referenced by updateCustomIcon().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::setPoints | ( | $a_points | ) |
Set the amount of points.
| integer | $a_points | - larger than zero |
| ilException |
Definition at line 256 of file class.ilObjStudyProgramme.php.
References updateLastChange().
Here is the call graph for this function:
|
static |
Set all progresses to completed where the object with given id is a leaf and that belong to the user.
Definition at line 1161 of file class.ilObjStudyProgramme.php.
References ilObject\$ref_id, ilObject\$type, ilObject\_getAllReferences(), ilContainerReference\_lookupSourceIds(), ilObject\_lookupType(), and setProgressesCompletedIfParentIsProgrammeInLPCompletedMode().
Referenced by ilStudyProgrammeAppEventListener\onServiceTrackingUpdateStatus().
Here is the call graph for this function:
Here is the caller graph for this function:
|
staticprotected |
Definition at line 1180 of file class.ilObjStudyProgramme.php.
References $tree, getInstanceByRefId(), initStudyProgrammeCache(), and ilStudyProgramme\MODE_LP_COMPLETED.
Referenced by setProgressesCompletedFor().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::setStatus | ( | $a_status | ) |
Set the status of the node.
| integer | $a_status | - one of ilStudyProgramme::$STATUS |
Definition at line 311 of file class.ilObjStudyProgramme.php.
References updateLastChange().
Here is the call graph for this function:| ilObjStudyProgramme::setSubtypeId | ( | $a_subtype_id | ) |
Sets the meta-data subtype id.
| $a_subtype_id |
Definition at line 343 of file class.ilObjStudyProgramme.php.
|
protected |
Helper function to check, weather object is in tree.
Throws ilStudyProgrammeTreeException if object is not in tree.
Definition at line 580 of file class.ilObjStudyProgramme.php.
Referenced by addLeaf(), addNode(), applyToSubTreeNodes(), getChildren(), getLPChildren(), and getParent().
Here is the caller graph for this function:| ilObjStudyProgramme::update | ( | ) |
Update.
Reimplemented from ilContainer.
Definition at line 192 of file class.ilObjStudyProgramme.php.
References ilObject\getId(), getSubType(), ilAdvancedMDRecord\saveObjRecSelection(), and updateSettings().
Referenced by addLeaf(), and updateLastChange().
Here is the call graph for this function:
Here is the caller graph for this function:| ilObjStudyProgramme::updateAllAssignments | ( | ) |
Update all assignments to this program node.
Definition at line 980 of file class.ilObjStudyProgramme.php.
References ilObject\getId(), and ilStudyProgrammeUserAssignment\getInstancesForProgram().
Here is the call graph for this function:| ilObjStudyProgramme::updateCustomIcon | ( | ) |
updates the selected custom icon in container folder by type
Definition at line 1227 of file class.ilObjStudyProgramme.php.
References getSubType(), ilContainer\removeCustomIcon(), and saveIcons().
Here is the call graph for this function:
|
protected |
Update last change timestamp on this node and its parents.
Definition at line 1126 of file class.ilObjStudyProgramme.php.
References $parent, getParent(), and update().
Referenced by setPoints(), and setStatus().
Here is the call graph for this function:
Here is the caller graph for this function:
|
protected |
Update settings in DB.
Throws when settings are not loaded.
Definition at line 151 of file class.ilObjStudyProgramme.php.
Referenced by update().
Here is the caller graph for this function:
|
protected |
Definition at line 21 of file class.ilObjStudyProgramme.php.
Referenced by getChildren().
| ilObjStudyProgramme::$ilUser |
Definition at line 26 of file class.ilObjStudyProgramme.php.
Referenced by __construct().
|
protected |
Definition at line 22 of file class.ilObjStudyProgramme.php.
Referenced by getLPChildren().
| ilObjStudyProgramme::$object_factory |
Definition at line 29 of file class.ilObjStudyProgramme.php.
|
protected |
Definition at line 20 of file class.ilObjStudyProgramme.php.
Referenced by getCreatableSubObjects(), getParent(), moveTo(), and updateLastChange().
|
protected |
Definition at line 19 of file class.ilObjStudyProgramme.php.
Referenced by getRawSettings().
|
static |
Definition at line 31 of file class.ilObjStudyProgramme.php.
| ilObjStudyProgramme::$tree |
Definition at line 25 of file class.ilObjStudyProgramme.php.
Referenced by __construct(), getParentId(), and setProgressesCompletedIfParentIsProgrammeInLPCompletedMode().