ILIAS
release_7 Revision v7.30-3-g800a261c036
|
Public Member Functions | |
__construct (ilDBInterface $db) | |
createFor (int $obj_id) | |
Create a record corresponding to a SP-Object and return representing settings.Will throw if a record allready exists. More... | |
get (int $obj_id) | |
Load settings belonging to a SP-Object.Will throw if the record does not exist yet. More... | |
update (ilStudyProgrammeSettings $settings) | |
Update settings belonging to a SP-Object.Will throw if the record does not exist yet. More... | |
delete (ilStudyProgrammeSettings $settings) | |
Delete record corresponding to settings.Will throw if the record does not exist yet. More... | |
loadByType (int $type_id) | |
Load SP settings by assigned type. More... | |
loadIdsByType (int $type_id) | |
Load SP setting-ids by assigned type. More... | |
getProgrammeIdsWithRiskyToFailSettings () | |
Programme must be active and have a setting to send mails if the user is at risk to fail completing the progress due to a deadline. More... | |
getProgrammeIdsWithMailsForExpiringValidity () | |
Programme must be active and have a setting to send mails for qualifications about to expire. More... | |
getProgrammeIdsWithReassignmentForExpiringValidity () | |
Programme must be active and have a setting to reassign users when validity expires. More... | |
Static Public Member Functions | |
static | clearCache () |
Data Fields | |
const | TABLE = 'prg_settings' |
const | FIELD_OBJ_ID = 'obj_id' |
const | FIELD_SUBTYPE_ID = 'subtype_id' |
const | FIELD_STATUS = 'status' |
const | FIELD_LP_MODE = 'lp_mode' |
const | FIELD_POINTS = 'points' |
const | FIELD_LAST_CHANGED = 'last_change' |
const | FIELD_DEADLINE_PERIOD = 'deadline_period' |
const | FIELD_DEADLINE_DATE = 'deadline_date' |
const | FIELD_VALIDITY_QUALIFICATION_DATE = 'vq_date' |
const | FIELD_VALIDITY_QUALIFICATION_PERIOD = 'vq_period' |
const | FIELD_VQ_RESTART_PERIOD = 'vq_restart_period' |
const | FIELD_RM_NOT_RESTARTED_BY_USER_DAY = 'rm_nr_by_usr_days' |
const | FIELD_PROC_ENDS_NOT_SUCCESSFUL = 'proc_end_no_success' |
const | FIELD_SEND_RE_ASSIGNED_MAIL = "send_re_assigned_mail" |
const | FIELD_SEND_INFO_TO_RE_ASSIGN_MAIL = "send_info_to_re_assign_mail" |
const | FIELD_SEND_RISKY_TO_FAIL_MAIL = "send_risky_to_fail_mail" |
Protected Member Functions | |
insertDB (int $obj_id, int $subtype_id, int $status, int $lp_mode, int $points, string $last_change, int $deadline_period, int $vq_period, int $vq_restart_period, string $deadline_date=null, string $vq_date=null, int $rm_nr_by_usr_days=null, int $proc_end_no_success=null, bool $send_re_assigned_mail=false, bool $send_info_to_re_assign_mail=false, bool $send_risky_to_fail_mail=false) | |
loadDB (int $obj_id) | |
createByRow (array $row) | |
deleteDB (int $obj_id) | |
updateDB (int $obj_id, int $subtype_id, int $status, int $lp_mode, int $points, string $last_change, int $deadline_period, int $vq_period, int $vq_restart_period, string $deadline_date=null, string $vq_date=null, int $rm_nr_by_usr_days=null, int $proc_end_no_success=null, bool $send_re_assigned_mail=false, bool $send_info_to_re_assign_mail=false, bool $send_risky_to_fail_mail=false) | |
LogicException More... | |
checkExists (int $obj_id) | |
Protected Attributes | |
$db | |
Static Protected Attributes | |
static | $cache = [] |
Definition at line 8 of file class.ilStudyProgrammeSettingsDBRepository.php.
ilStudyProgrammeSettingsDBRepository::__construct | ( | ilDBInterface | $db | ) |
|
protected |
Definition at line 486 of file class.ilStudyProgrammeSettingsDBRepository.php.
Referenced by deleteDB(), and updateDB().
|
static |
Definition at line 501 of file class.ilStudyProgrammeSettingsDBRepository.php.
Referenced by ilStudyProgrammeSettingsRepositoryTest\test_edit_and_update().
|
protected |
ilException |
Definition at line 279 of file class.ilStudyProgrammeSettingsDBRepository.php.
References $type, ilStudyProgrammeSettings\DATE_TIME_FORMAT, ilStudyProgrammeSettings\DEFAULT_POINTS, ilStudyProgrammeSettings\DEFAULT_SUBTYPE, and ilStudyProgrammeSettings\STATUS_DRAFT.
Referenced by loadByType(), and loadDB().
ilStudyProgrammeSettingsDBRepository::createFor | ( | int | $obj_id | ) |
Create a record corresponding to a SP-Object and return representing settings.Will throw if a record allready exists.
ilException |
Implements ilStudyProgrammeSettingsRepository.
Definition at line 48 of file class.ilStudyProgrammeSettingsDBRepository.php.
References ilStudyProgrammeSettings\DATE_TIME_FORMAT, ilStudyProgrammeSettings\DEFAULT_POINTS, ilStudyProgrammeSettings\DEFAULT_SUBTYPE, insertDB(), ilStudyProgrammeSettings\MODE_UNDEFINED, ilStudyProgrammeSettings\NO_RESTART, ilStudyProgrammeSettings\NO_VALIDITY_OF_QUALIFICATION_PERIOD, and ilStudyProgrammeSettings\STATUS_DRAFT.
ilStudyProgrammeSettingsDBRepository::delete | ( | ilStudyProgrammeSettings | $settings | ) |
Delete record corresponding to settings.Will throw if the record does not exist yet.
Implements ilStudyProgrammeSettingsRepository.
Definition at line 159 of file class.ilStudyProgrammeSettingsDBRepository.php.
References deleteDB().
|
protected |
LogicException |
Definition at line 378 of file class.ilStudyProgrammeSettingsDBRepository.php.
References checkExists().
Referenced by delete().
ilStudyProgrammeSettingsDBRepository::get | ( | int | $obj_id | ) |
Load settings belonging to a SP-Object.Will throw if the record does not exist yet.
ilException |
Implements ilStudyProgrammeSettingsRepository.
Definition at line 97 of file class.ilStudyProgrammeSettingsDBRepository.php.
References loadDB().
ilStudyProgrammeSettingsDBRepository::getProgrammeIdsWithMailsForExpiringValidity | ( | ) |
Programme must be active and have a setting to send mails for qualifications about to expire.
Definition at line 534 of file class.ilStudyProgrammeSettingsDBRepository.php.
References $query, $res, and ilStudyProgrammeSettings\STATUS_ACTIVE.
ilStudyProgrammeSettingsDBRepository::getProgrammeIdsWithReassignmentForExpiringValidity | ( | ) |
Programme must be active and have a setting to reassign users when validity expires.
Definition at line 556 of file class.ilStudyProgrammeSettingsDBRepository.php.
References $query, $res, and ilStudyProgrammeSettings\STATUS_ACTIVE.
ilStudyProgrammeSettingsDBRepository::getProgrammeIdsWithRiskyToFailSettings | ( | ) |
Programme must be active and have a setting to send mails if the user is at risk to fail completing the progress due to a deadline.
Definition at line 512 of file class.ilStudyProgrammeSettingsDBRepository.php.
References $query, $res, and ilStudyProgrammeSettings\STATUS_ACTIVE.
|
protected |
Definition at line 201 of file class.ilStudyProgrammeSettingsDBRepository.php.
Referenced by createFor().
ilStudyProgrammeSettingsDBRepository::loadByType | ( | int | $type_id | ) |
Load SP settings by assigned type.
ilException |
Implements ilStudyProgrammeSettingsRepository.
Definition at line 169 of file class.ilStudyProgrammeSettingsDBRepository.php.
References $res, and createByRow().
|
protected |
ilException | LogicException |
Definition at line 246 of file class.ilStudyProgrammeSettingsDBRepository.php.
References createByRow().
Referenced by get().
ilStudyProgrammeSettingsDBRepository::loadIdsByType | ( | int | $type_id | ) |
Load SP setting-ids by assigned type.
Implements ilStudyProgrammeSettingsRepository.
Definition at line 196 of file class.ilStudyProgrammeSettingsDBRepository.php.
ilStudyProgrammeSettingsDBRepository::update | ( | ilStudyProgrammeSettings | $settings | ) |
Update settings belonging to a SP-Object.Will throw if the record does not exist yet.
Implements ilStudyProgrammeSettingsRepository.
Definition at line 108 of file class.ilStudyProgrammeSettingsDBRepository.php.
References ilStudyProgrammeSettings\DATE_TIME_FORMAT, ilStudyProgrammeSettings\getAssessmentSettings(), ilStudyProgrammeSettings\getAutoMailSettings(), ilStudyProgrammeSettings\getDeadlineSettings(), ilStudyProgrammeSettings\getLastChange(), ilStudyProgrammeSettings\getLPMode(), ilStudyProgrammeSettings\getObjId(), ilStudyProgrammeSettings\getTypeSettings(), ilStudyProgrammeSettings\getValidityOfQualificationSettings(), and updateDB().
|
protected |
LogicException
Definition at line 392 of file class.ilStudyProgrammeSettingsDBRepository.php.
References checkExists().
Referenced by update().
|
staticprotected |
Definition at line 13 of file class.ilStudyProgrammeSettingsDBRepository.php.
|
protected |
Definition at line 18 of file class.ilStudyProgrammeSettingsDBRepository.php.
Referenced by __construct().
const ilStudyProgrammeSettingsDBRepository::FIELD_DEADLINE_DATE = 'deadline_date' |
Definition at line 29 of file class.ilStudyProgrammeSettingsDBRepository.php.
const ilStudyProgrammeSettingsDBRepository::FIELD_DEADLINE_PERIOD = 'deadline_period' |
Definition at line 28 of file class.ilStudyProgrammeSettingsDBRepository.php.
const ilStudyProgrammeSettingsDBRepository::FIELD_LAST_CHANGED = 'last_change' |
Definition at line 27 of file class.ilStudyProgrammeSettingsDBRepository.php.
const ilStudyProgrammeSettingsDBRepository::FIELD_LP_MODE = 'lp_mode' |
Definition at line 25 of file class.ilStudyProgrammeSettingsDBRepository.php.
const ilStudyProgrammeSettingsDBRepository::FIELD_OBJ_ID = 'obj_id' |
Definition at line 22 of file class.ilStudyProgrammeSettingsDBRepository.php.
const ilStudyProgrammeSettingsDBRepository::FIELD_POINTS = 'points' |
Definition at line 26 of file class.ilStudyProgrammeSettingsDBRepository.php.
const ilStudyProgrammeSettingsDBRepository::FIELD_PROC_ENDS_NOT_SUCCESSFUL = 'proc_end_no_success' |
Definition at line 34 of file class.ilStudyProgrammeSettingsDBRepository.php.
const ilStudyProgrammeSettingsDBRepository::FIELD_RM_NOT_RESTARTED_BY_USER_DAY = 'rm_nr_by_usr_days' |
Definition at line 33 of file class.ilStudyProgrammeSettingsDBRepository.php.
const ilStudyProgrammeSettingsDBRepository::FIELD_SEND_INFO_TO_RE_ASSIGN_MAIL = "send_info_to_re_assign_mail" |
Definition at line 36 of file class.ilStudyProgrammeSettingsDBRepository.php.
const ilStudyProgrammeSettingsDBRepository::FIELD_SEND_RE_ASSIGNED_MAIL = "send_re_assigned_mail" |
Definition at line 35 of file class.ilStudyProgrammeSettingsDBRepository.php.
const ilStudyProgrammeSettingsDBRepository::FIELD_SEND_RISKY_TO_FAIL_MAIL = "send_risky_to_fail_mail" |
Definition at line 37 of file class.ilStudyProgrammeSettingsDBRepository.php.
const ilStudyProgrammeSettingsDBRepository::FIELD_STATUS = 'status' |
Definition at line 24 of file class.ilStudyProgrammeSettingsDBRepository.php.
const ilStudyProgrammeSettingsDBRepository::FIELD_SUBTYPE_ID = 'subtype_id' |
Definition at line 23 of file class.ilStudyProgrammeSettingsDBRepository.php.
const ilStudyProgrammeSettingsDBRepository::FIELD_VALIDITY_QUALIFICATION_DATE = 'vq_date' |
Definition at line 30 of file class.ilStudyProgrammeSettingsDBRepository.php.
const ilStudyProgrammeSettingsDBRepository::FIELD_VALIDITY_QUALIFICATION_PERIOD = 'vq_period' |
Definition at line 31 of file class.ilStudyProgrammeSettingsDBRepository.php.
const ilStudyProgrammeSettingsDBRepository::FIELD_VQ_RESTART_PERIOD = 'vq_restart_period' |
Definition at line 32 of file class.ilStudyProgrammeSettingsDBRepository.php.
const ilStudyProgrammeSettingsDBRepository::TABLE = 'prg_settings' |
Definition at line 20 of file class.ilStudyProgrammeSettingsDBRepository.php.
Referenced by ilObjStudyProgrammeTest\testDeleteRemovesEntriesInPrgSettings().