5 require_once(dirname(__FILE__) .
"/../../../../Services/ActiveRecord/class.ActiveRecord.php");
26 return "prg_usr_assignments";
106 throw new ilException(
"ilStudyProgrammeAssignment::createFor: '$a_usr_id' " 107 .
"is no id of a user.");
113 ->setLastChangeBy($a_assigning_usr_id)
141 $this->root_prg_id = $a_id;
157 $this->usr_id = $a_usr_id;
182 throw new ilException(
"ilStudyProgrammeAssignment::setLastChangeBy: '$a_usr_id' " 183 .
"is no id of a user.");
185 $this->last_change_by = $a_usr_id;
222 throw new ilException(
"ilStudyProgrammeAssignment::setLastChange: Given " 223 .
"timestamp is before current timestamp. That " 224 .
"is logically impossible.");
getUserId()
Get the id of the user who is assigned.
setLastChange(ilDateTime $a_timestamp)
Set the last change timestamp to the given time.
static _before(ilDateTime $start, ilDateTime $end, $a_compare_field='', $a_tz='')
compare two dates and check start is before end This method does not consider tz offsets.
setLastChangeBy($a_usr_id)
Set the id of the user who did the last change on this assignment.
static now()
Return current timestamp in Y-m-d H:i:s format.
getLastChange()
Get the timestamp of the last change on this program or a sub program.
getObjId()
Get the id of the study program.
updateLastChange()
Update the last change timestamp to the current time.
Class ilStudyProgrammeAssignment.
get($a_format, $a_format_str='', $a_tz='')
get formatted date
static _lookupType($a_id, $a_reference=false)
lookup object type
static returnDbTableName()
getLastChangeBy()
Get the id of the user who did the last change on this assignment.
static createFor(ilStudyProgramme $a_prg, $a_usr_id, $a_assigning_usr_id)
Create new assignment object for study program and user.
getRootId()
Get the object id of the program the user was assigned to.
getId()
Get the id of the assignment.