ILIAS  release_8 Revision v8.19
All Data Structures Namespaces Files Functions Variables Modules Pages
ilSurveyLP Class Reference

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

+ Inheritance diagram for ilSurveyLP:
+ Collaboration diagram for ilSurveyLP:

Public Member Functions

 getDefaultMode ()
 
 getValidModes ()
 
 isAnonymized ()
 
- Public Member Functions inherited from ilObjectLP
 resetCaches ()
 
 isAnonymized ()
 
 getDefaultMode ()
 
 getValidModes ()
 
 getCurrentMode ()
 
 isActive ()
 
 getModeText (int $mode)
 
 getModeInfoText (int $mode)
 
 getSettingsInfo ()
 
 getCollectionInstance ()
 
 getMembers (bool $search=true)
 
 resetLPDataForCompleteObject (bool $recursive=true)
 
 resetLPDataForUserIds (array $user_ids, bool $recursive=true)
 
 handleToTrash ()
 
 handleDelete ()
 
 getMailTemplateId ()
 
 hasIndividualModeOptions ()
 
 initInvidualModeOptions (ilRadioGroupInputGUI $modeRadio)
 
 shouldFetchIndividualModeFromFormSubmission ()
 
 fetchIndividualModeFromFormSubmission (ilPropertyFormGUI $form)
 
 appendModeConfiguration (int $mode, ilRadioOption $modeElement)
 
 saveModeConfiguration (ilPropertyFormGUI $form, bool &$modeChanged)
 

Static Public Member Functions

static getDefaultModes (bool $lp_active)
 
- Static Public Member Functions inherited from ilObjectLP
static getInstance (int $obj_id)
 
static getTypeClass (string $type)
 
static getSupportedObjectTypes ()
 
static isSupportedObjectType (string $type)
 
static handleMove (int $source_ref_id)
 
static getLPMemberships (int $usr_id, array $obj_ids, ?int $parent_ref_id=null, bool $mapped_ref_ids=false)
 Get all objects where given user is member (from LP POV) More...
 
static supportsSpentSeconds (string $obj_type)
 
static supportsMark (string $obj_type)
 
static supportsMatrixView (string $obj_type)
 
static getDefaultModes (bool $lp_active)
 Get available type-specific default modes (no administration needed) More...
 
static saveTypeDefaults (array $data)
 
static getTypeDefault (string $type)
 

Static Protected Member Functions

static isLPMember (array &$res, int $usr_id, array $obj_ids)
 
- Static Protected Member Functions inherited from ilObjectLP
static isLPMember (array &$res, int $usr_id, array $obj_ids)
 Find (lp-relevant) members for given object ids. More...
 
static findMembershipsByPath (array &$res, int $usr_id, int $parent_ref_id, array $obj_ids, bool $mapped_ref_ids=false)
 Find (lp-relevant) memberships by path. More...
 
static getTypeDefaultFromDB (string $type)
 

Additional Inherited Members

- Protected Member Functions inherited from ilObjectLP
 __construct (int $obj_id)
 
 resetCustomLPDataForUserIds (array $user_ids, bool $recursive=true)
 
 gatherLPUsers ()
 
 updateParentCollections ()
 
- Protected Attributes inherited from ilObjectLP
ilTree $tree
 
ilDBInterface $db
 
ilObjectDefinition $objectDefinition
 
int $obj_id
 
ilLPCollection $collection_instance = null
 
int $mode = null
 
- Static Protected Attributes inherited from ilObjectLP
static array $type_defaults = null
 

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 Survey to lp connector

Author
Jörg Lützenkirchen luetz.nosp@m.enki.nosp@m.rchen.nosp@m.@lei.nosp@m.fos.c.nosp@m.om

Definition at line 24 of file class.ilSurveyLP.php.

Member Function Documentation

◆ getDefaultMode()

ilSurveyLP::getDefaultMode ( )

Definition at line 34 of file class.ilSurveyLP.php.

References ilLPObjSettings\LP_MODE_DEACTIVATED.

34  : int
35  {
36  return ilLPObjSettings::LP_MODE_DEACTIVATED; // :TODO:
37  }

◆ getDefaultModes()

static ilSurveyLP::getDefaultModes ( bool  $lp_active)
static

◆ getValidModes()

ilSurveyLP::getValidModes ( )

◆ isAnonymized()

ilSurveyLP::isAnonymized ( )

Definition at line 47 of file class.ilSurveyLP.php.

References ilObjSurveyAccess\_lookupAnonymize().

47  : bool
48  {
49  return ilObjSurveyAccess::_lookupAnonymize($this->obj_id);
50  }
static _lookupAnonymize(int $a_obj_id)
+ Here is the call graph for this function:

◆ isLPMember()

static ilSurveyLP::isLPMember ( array &  $res,
int  $usr_id,
array  $obj_ids 
)
staticprotected

Definition at line 52 of file class.ilSurveyLP.php.

References $DIC, $ilDB, ilDBConstants\FETCHMODE_OBJECT, ILIAS\Repository\int(), and ilDBConstants\T_INTEGER.

52  : bool
53  {
54  global $DIC;
55 
56  $ilDB = $DIC->database();
57 
58  // if active id
59  $set = $ilDB->query("SELECT ss.obj_fi" .
60  " FROM svy_finished sf" .
61  " JOIN svy_svy ss ON (ss.survey_id = sf.survey_fi)" .
62  " WHERE " . $ilDB->in("ss.obj_fi", $obj_ids, "", "integer") .
63  " AND sf.user_fi = " . $ilDB->quote($usr_id, "integer"));
64  while ($row = $ilDB->fetchAssoc($set)) {
65  $res[(int) $row["obj_fi"]] = true;
66  }
67  $set = $ilDB->query(
68  $q = 'select obj_fi from svy_invitation si ' .
69  'join svy_svy ss on ss.survey_id = si.survey_id ' .
70  'where ' . $ilDB->in('ss.obj_fi', $obj_ids, false, ilDBConstants::T_INTEGER) .
71  'and user_id = ' . $ilDB->quote($usr_id, ilDBConstants::T_INTEGER)
72  );
73  while ($row = $set->fetchRow(ilDBConstants::FETCHMODE_OBJECT)) {
74  $res[(int) $row->obj_fi] = true;
75  }
76  return true;
77  }
$res
Definition: ltiservices.php:69
global $DIC
Definition: feed.php:28
+ Here is the call graph for this function:

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