ILIAS
release_7 Revision v7.30-3-g800a261c036
|
Public Member Functions | |
__construct (ilDBInterface $db) | |
createFor (ilStudyProgrammeSettings $prg, ilStudyProgrammeAssignment $ass, int $acting_user=null) | |
get (int $id) | |
Load progress belonging to a id.Will throw if the record does not exist yet. More... | |
getByIds (int $prg_id, int $assignment_id) | |
Load progress belonging to a prg id and assignment.Will throw if the record does not exist yet. More... | |
getByPrgIdAndAssignmentId (int $prg_id, int $assignment_id) | |
Load progress belonging to a prg id and assignment.Will throw if the record does not exist yet. More... | |
getRootProgressOf (ilStudyProgrammeAssignment $assignment) | |
getByPrgIdAndUserId (int $prg_id, int $usr_id) | |
Load progress objects belonging to a prg id and a user id. More... | |
getByPrgId (int $prg_id) | |
Load progress objects belonging to a prg id. More... | |
getFirstByPrgId (int $prg_id) | |
getByAssignmentId (int $assignment_id) | |
Load progress objects belonging to an assignment id.Will throw if the record does not exist yet. More... | |
getExpiredSuccessfull () | |
Load all progress objects which are successfull and whose validity is expired. More... | |
getPassedDeadline () | |
getRiskyToFailInstances () | |
update (ilStudyProgrammeProgress $progress) | |
Update record corresponding to progress.Will throw if the record does not exist yet. More... | |
delete (ilStudyProgrammeProgress $progress) | |
Delete record corresponding to progress.Will throw if the record does not exist yet. More... | |
deleteForAssignmentId (int $assignment_id) | |
sentRiskyToFailFor (int $progress_id) | |
sentExpiryInfoFor (int $progress_id) | |
getRiskyToFail (array $programmes_and_due) | |
getAboutToExpire (array $programmes_and_due, bool $discard_formerly_notified=true) | |
deleteAllOrphanedProgresses (string $assignment_table, string $assignment_id_field) | |
deleteProgressesFor (int $prg_obj_id) | |
![]() | |
createFor (ilStudyProgrammeSettings $prg, ilStudyProgrammeAssignment $ass) | |
Create a record corresponding to a progress and return corresponding object. More... | |
Data Fields | |
const | TABLE = 'prg_usr_progress' |
const | FIELD_ID = 'id' |
const | FIELD_ASSIGNMENT_ID = 'assignment_id' |
const | FIELD_PRG_ID = 'prg_id' |
const | FIELD_USR_ID = 'usr_id' |
const | FIELD_POINTS = 'points' |
const | FIELD_POINTS_CUR = 'points_cur' |
const | FIELD_STATUS = 'status' |
const | FIELD_COMPLETION_BY = 'completion_by' |
const | FIELD_ASSIGNMENT_DATE = 'assignment_date' |
const | FIELD_LAST_CHANGE = 'last_change' |
const | FIELD_LAST_CHANGE_BY = 'last_change_by' |
const | FIELD_COMPLETION_DATE = 'completion_date' |
const | FIELD_DEADLINE = 'deadline' |
const | FIELD_VQ_DATE = 'vq_date' |
const | FIELD_INVALIDATED = 'invalidated' |
const | FIELD_MAIL_SENT_RISKYTOFAIL = 'sent_mail_risky_to_fail' |
const | FIELD_MAIL_SENT_WILLEXPIRE = 'sent_mail_expires' |
const | FIELD_IS_INDIVIDUAL = 'individual' |
Protected Member Functions | |
insertRowDB (array $row) | |
updateRowDB (array $data) | |
buildByRow (array $row) | |
loadByFilter (array $filter) | |
loadExpiredSuccessful () | |
loadPassedDeadline () | |
loadRiskyToFailInstance () | |
getSQLHeader () | |
nextId () | |
Protected Attributes | |
$db | |
Static Protected Attributes | |
static | $cache = [] |
Definition at line 5 of file class.ilStudyProgrammeProgressDBRepository.php.
ilStudyProgrammeProgressDBRepository::__construct | ( | ilDBInterface | $db | ) |
|
protected |
ilException |
Definition at line 427 of file class.ilStudyProgrammeProgressDBRepository.php.
References ilStudyProgrammeProgress\DATE_FORMAT, ilStudyProgrammeProgress\DATE_TIME_FORMAT, and ilStudyProgrammeProgress\invalidate().
Referenced by createFor(), get(), getAboutToExpire(), getByAssignmentId(), getByPrgId(), getByPrgIdAndAssignmentId(), getByPrgIdAndUserId(), getExpiredSuccessfull(), getFirstByPrgId(), getPassedDeadline(), getRiskyToFail(), getRiskyToFailInstances(), and getRootProgressOf().
ilStudyProgrammeProgressDBRepository::createFor | ( | ilStudyProgrammeSettings | $prg, |
ilStudyProgrammeAssignment | $ass, | ||
int | $acting_user = null |
||
) |
ilException |
Definition at line 41 of file class.ilStudyProgrammeProgressDBRepository.php.
References buildByRow(), ilStudyProgrammeSettings\getAssessmentSettings(), ilStudyProgrammeAssignment\getId(), ilStudyProgrammeSettings\getObjId(), ilStudyProgrammeAssignment\getUserId(), insertRowDB(), nextId(), ilUtil\now(), and ilStudyProgrammeProgress\STATUS_IN_PROGRESS.
ilStudyProgrammeProgressDBRepository::delete | ( | ilStudyProgrammeProgress | $progress | ) |
Delete record corresponding to progress.Will throw if the record does not exist yet.
Implements ilStudyProgrammeProgressRepository.
Definition at line 258 of file class.ilStudyProgrammeProgressDBRepository.php.
ilStudyProgrammeProgressDBRepository::deleteAllOrphanedProgresses | ( | string | $assignment_table, |
string | $assignment_id_field | ||
) |
ilStudyProgrammeProgressDBRepository::deleteForAssignmentId | ( | int | $assignment_id | ) |
Definition at line 291 of file class.ilStudyProgrammeProgressDBRepository.php.
References $query, and getByAssignmentId().
ilStudyProgrammeProgressDBRepository::deleteProgressesFor | ( | int | $prg_obj_id | ) |
ilStudyProgrammeProgressDBRepository::get | ( | int | $id | ) |
Load progress belonging to a id.Will throw if the record does not exist yet.
ilException |
Implements ilStudyProgrammeProgressRepository.
Definition at line 74 of file class.ilStudyProgrammeProgressDBRepository.php.
References buildByRow(), and loadByFilter().
ilStudyProgrammeProgressDBRepository::getAboutToExpire | ( | array | $programmes_and_due, |
bool | $discard_formerly_notified = true |
||
) |
array | <int, DateTimeImmutable> $programmes_and_due |
Definition at line 616 of file class.ilStudyProgrammeProgressDBRepository.php.
References $query, $res, $ret, buildByRow(), ilStudyProgrammeProgress\DATE_FORMAT_ENDOFDAY, and getSQLHeader().
ilStudyProgrammeProgressDBRepository::getByAssignmentId | ( | int | $assignment_id | ) |
Load progress objects belonging to an assignment id.Will throw if the record does not exist yet.
ilException |
Implements ilStudyProgrammeProgressRepository.
Definition at line 175 of file class.ilStudyProgrammeProgressDBRepository.php.
References buildByRow(), and loadByFilter().
Referenced by deleteForAssignmentId().
ilStudyProgrammeProgressDBRepository::getByIds | ( | int | $prg_id, |
int | $assignment_id | ||
) |
Load progress belonging to a prg id and assignment.Will throw if the record does not exist yet.
ilException |
Implements ilStudyProgrammeProgressRepository.
Definition at line 88 of file class.ilStudyProgrammeProgressDBRepository.php.
References getByPrgIdAndAssignmentId().
ilStudyProgrammeProgressDBRepository::getByPrgId | ( | int | $prg_id | ) |
Load progress objects belonging to a prg id.
ilException |
Implements ilStudyProgrammeProgressRepository.
Definition at line 150 of file class.ilStudyProgrammeProgressDBRepository.php.
References buildByRow(), and loadByFilter().
ilStudyProgrammeProgressDBRepository::getByPrgIdAndAssignmentId | ( | int | $prg_id, |
int | $assignment_id | ||
) |
Load progress belonging to a prg id and assignment.Will throw if the record does not exist yet.
ilException |
Implements ilStudyProgrammeProgressRepository.
Definition at line 102 of file class.ilStudyProgrammeProgressDBRepository.php.
References $rows, buildByRow(), and loadByFilter().
Referenced by getByIds().
ilStudyProgrammeProgressDBRepository::getByPrgIdAndUserId | ( | int | $prg_id, |
int | $usr_id | ||
) |
Load progress objects belonging to a prg id and a user id.
ilException |
Implements ilStudyProgrammeProgressRepository.
Definition at line 136 of file class.ilStudyProgrammeProgressDBRepository.php.
References buildByRow(), and loadByFilter().
ilStudyProgrammeProgressDBRepository::getExpiredSuccessfull | ( | ) |
Load all progress objects which are successfull and whose validity is expired.
ilException |
Implements ilStudyProgrammeProgressRepository.
Definition at line 189 of file class.ilStudyProgrammeProgressDBRepository.php.
References buildByRow(), and loadExpiredSuccessful().
ilStudyProgrammeProgressDBRepository::getFirstByPrgId | ( | int | $prg_id | ) |
ilException |
Implements ilStudyProgrammeProgressRepository.
Definition at line 163 of file class.ilStudyProgrammeProgressDBRepository.php.
References buildByRow(), and loadByFilter().
ilStudyProgrammeProgressDBRepository::getPassedDeadline | ( | ) |
ilException |
Implements ilStudyProgrammeProgressRepository.
Definition at line 203 of file class.ilStudyProgrammeProgressDBRepository.php.
References buildByRow(), and loadPassedDeadline().
ilStudyProgrammeProgressDBRepository::getRiskyToFail | ( | array | $programmes_and_due | ) |
array | <int, DateTimeImmutable> $programmes_and_due |
Definition at line 587 of file class.ilStudyProgrammeProgressDBRepository.php.
References $query, $res, $ret, buildByRow(), ilStudyProgrammeProgress\DATE_FORMAT, and getSQLHeader().
ilStudyProgrammeProgressDBRepository::getRiskyToFailInstances | ( | ) |
ilException |
Implements ilStudyProgrammeProgressRepository.
Definition at line 217 of file class.ilStudyProgrammeProgressDBRepository.php.
References buildByRow(), and loadRiskyToFailInstance().
ilStudyProgrammeProgressDBRepository::getRootProgressOf | ( | ilStudyProgrammeAssignment | $assignment | ) |
Definition at line 116 of file class.ilStudyProgrammeProgressDBRepository.php.
References $rows, buildByRow(), ilStudyProgrammeAssignment\getId(), ilStudyProgrammeAssignment\getRootId(), ilStudyProgrammeAssignment\getUserId(), and loadByFilter().
|
protected |
Definition at line 562 of file class.ilStudyProgrammeProgressDBRepository.php.
Referenced by getAboutToExpire(), getRiskyToFail(), loadByFilter(), loadExpiredSuccessful(), loadPassedDeadline(), and loadRiskyToFailInstance().
|
protected |
Definition at line 263 of file class.ilStudyProgrammeProgressDBRepository.php.
Referenced by createFor().
|
protected |
Definition at line 472 of file class.ilStudyProgrammeProgressDBRepository.php.
References $res, and getSQLHeader().
Referenced by get(), getByAssignmentId(), getByPrgId(), getByPrgIdAndAssignmentId(), getByPrgIdAndUserId(), getFirstByPrgId(), and getRootProgressOf().
|
protected |
Definition at line 485 of file class.ilStudyProgrammeProgressDBRepository.php.
References $res, ilStudyProgrammeProgress\DATE_FORMAT, getSQLHeader(), ilStudyProgrammeProgress\STATUS_ACCREDITED, and ilStudyProgrammeProgress\STATUS_COMPLETED.
Referenced by getExpiredSuccessfull().
|
protected |
Definition at line 511 of file class.ilStudyProgrammeProgressDBRepository.php.
References $res, ilStudyProgrammeProgress\DATE_FORMAT, getSQLHeader(), ilStudyProgrammeProgress\STATUS_ACCREDITED, and ilStudyProgrammeProgress\STATUS_IN_PROGRESS.
Referenced by getPassedDeadline().
|
protected |
Definition at line 536 of file class.ilStudyProgrammeProgressDBRepository.php.
References $res, ilStudyProgrammeProgress\DATE_FORMAT, getSQLHeader(), ilStudyProgrammeProgress\STATUS_ACCREDITED, and ilStudyProgrammeProgress\STATUS_COMPLETED.
Referenced by getRiskyToFailInstances().
|
protected |
Definition at line 648 of file class.ilStudyProgrammeProgressDBRepository.php.
Referenced by createFor().
ilStudyProgrammeProgressDBRepository::sentExpiryInfoFor | ( | int | $progress_id | ) |
Definition at line 328 of file class.ilStudyProgrammeProgressDBRepository.php.
ilStudyProgrammeProgressDBRepository::sentRiskyToFailFor | ( | int | $progress_id | ) |
Definition at line 309 of file class.ilStudyProgrammeProgressDBRepository.php.
ilStudyProgrammeProgressDBRepository::update | ( | ilStudyProgrammeProgress | $progress | ) |
Update record corresponding to progress.Will throw if the record does not exist yet.
Implements ilStudyProgrammeProgressRepository.
Definition at line 229 of file class.ilStudyProgrammeProgressDBRepository.php.
References ilStudyProgrammeProgress\DATE_FORMAT, ilStudyProgrammeProgress\DATE_TIME_FORMAT, ilStudyProgrammeProgress\getAmountOfPoints(), ilStudyProgrammeProgress\getAssignmentDate(), ilStudyProgrammeProgress\getAssignmentId(), ilStudyProgrammeProgress\getCompletionBy(), ilStudyProgrammeProgress\getCompletionDate(), ilStudyProgrammeProgress\getCurrentAmountOfPoints(), ilStudyProgrammeProgress\getDeadline(), ilStudyProgrammeProgress\getId(), ilStudyProgrammeProgress\getLastChange(), ilStudyProgrammeProgress\getLastChangeBy(), ilStudyProgrammeProgress\getNodeId(), ilStudyProgrammeProgress\getStatus(), ilStudyProgrammeProgress\getUserId(), ilStudyProgrammeProgress\getValidityOfQualification(), ilStudyProgrammeProgress\hasIndividualModifications(), ilStudyProgrammeProgress\isInvalidated(), and updateRowDB().
|
protected |
Definition at line 349 of file class.ilStudyProgrammeProgressDBRepository.php.
Referenced by update().
|
staticprotected |
Definition at line 7 of file class.ilStudyProgrammeProgressDBRepository.php.
|
protected |
Definition at line 8 of file class.ilStudyProgrammeProgressDBRepository.php.
Referenced by __construct().
const ilStudyProgrammeProgressDBRepository::FIELD_ASSIGNMENT_DATE = 'assignment_date' |
Definition at line 20 of file class.ilStudyProgrammeProgressDBRepository.php.
const ilStudyProgrammeProgressDBRepository::FIELD_ASSIGNMENT_ID = 'assignment_id' |
Definition at line 13 of file class.ilStudyProgrammeProgressDBRepository.php.
const ilStudyProgrammeProgressDBRepository::FIELD_COMPLETION_BY = 'completion_by' |
Definition at line 19 of file class.ilStudyProgrammeProgressDBRepository.php.
const ilStudyProgrammeProgressDBRepository::FIELD_COMPLETION_DATE = 'completion_date' |
Definition at line 23 of file class.ilStudyProgrammeProgressDBRepository.php.
const ilStudyProgrammeProgressDBRepository::FIELD_DEADLINE = 'deadline' |
Definition at line 24 of file class.ilStudyProgrammeProgressDBRepository.php.
const ilStudyProgrammeProgressDBRepository::FIELD_ID = 'id' |
Definition at line 12 of file class.ilStudyProgrammeProgressDBRepository.php.
Referenced by ilStudyProgrammeProgressRepositoryTest\tearDownAfterClass().
const ilStudyProgrammeProgressDBRepository::FIELD_INVALIDATED = 'invalidated' |
Definition at line 26 of file class.ilStudyProgrammeProgressDBRepository.php.
const ilStudyProgrammeProgressDBRepository::FIELD_IS_INDIVIDUAL = 'individual' |
Definition at line 29 of file class.ilStudyProgrammeProgressDBRepository.php.
const ilStudyProgrammeProgressDBRepository::FIELD_LAST_CHANGE = 'last_change' |
Definition at line 21 of file class.ilStudyProgrammeProgressDBRepository.php.
const ilStudyProgrammeProgressDBRepository::FIELD_LAST_CHANGE_BY = 'last_change_by' |
Definition at line 22 of file class.ilStudyProgrammeProgressDBRepository.php.
const ilStudyProgrammeProgressDBRepository::FIELD_MAIL_SENT_RISKYTOFAIL = 'sent_mail_risky_to_fail' |
Definition at line 27 of file class.ilStudyProgrammeProgressDBRepository.php.
const ilStudyProgrammeProgressDBRepository::FIELD_MAIL_SENT_WILLEXPIRE = 'sent_mail_expires' |
Definition at line 28 of file class.ilStudyProgrammeProgressDBRepository.php.
const ilStudyProgrammeProgressDBRepository::FIELD_POINTS = 'points' |
Definition at line 16 of file class.ilStudyProgrammeProgressDBRepository.php.
const ilStudyProgrammeProgressDBRepository::FIELD_POINTS_CUR = 'points_cur' |
Definition at line 17 of file class.ilStudyProgrammeProgressDBRepository.php.
const ilStudyProgrammeProgressDBRepository::FIELD_PRG_ID = 'prg_id' |
Definition at line 14 of file class.ilStudyProgrammeProgressDBRepository.php.
const ilStudyProgrammeProgressDBRepository::FIELD_STATUS = 'status' |
Definition at line 18 of file class.ilStudyProgrammeProgressDBRepository.php.
const ilStudyProgrammeProgressDBRepository::FIELD_USR_ID = 'usr_id' |
Definition at line 15 of file class.ilStudyProgrammeProgressDBRepository.php.
const ilStudyProgrammeProgressDBRepository::FIELD_VQ_DATE = 'vq_date' |
Definition at line 25 of file class.ilStudyProgrammeProgressDBRepository.php.
const ilStudyProgrammeProgressDBRepository::TABLE = 'prg_usr_progress' |
Definition at line 10 of file class.ilStudyProgrammeProgressDBRepository.php.
Referenced by ilStudyProgrammeMembersTableGUI\getFrom(), and ilStudyProgrammeProgressRepositoryTest\tearDownAfterClass().