Stud.IP  4.0
 All Data Structures Namespaces Files Functions Variables Groups
admission.inc.php File Reference

Namespaces

 studip_core
 

Functions

 insert_seminar_user ($seminar_id, $user_id, $status, $copy_studycourse=false, $contingent=false, $log_message=false)
 
 renumber_admission ($seminar_id, $send_message=TRUE)
 
 update_admission ($seminar_id, $send_message=TRUE)
 
 normal_update_admission ($seminar_id, $send_message=TRUE)
 
 admission_seminar_user_insert ($user_id, $seminar_id, $status, $studiengang_id= '', $comment= '')
 
 admission_seminar_user_get_position ($user_id, $seminar_id)
 

Function Documentation

admission_seminar_user_get_position (   $user_id,
  $seminar_id 
)

returns the position for a user on a waiting list

if the user is not found false is returned, return true if the user is found but no position is available

Parameters
stringuser_id
stringseminar_id
Returns
integer position in waiting list or false if not found
admission_seminar_user_insert (   $user_id,
  $seminar_id,
  $status,
  $studiengang_id = '',
  $comment = '' 
)

sets a user on a waiting list for a registration procedure

if applicable ($status == 'awaiting') returns the position

Parameters
stringuser_id
stringseminar_id
stringstatus 'claiming','awaiting','accepted'
stringstudiengang_id
stringcomment
Returns
integer position on waiting list
insert_seminar_user (   $seminar_id,
  $user_id,
  $status,
  $copy_studycourse = false,
  $contingent = false,
  $log_message = false 
)

Insert a user into a seminar with optional log-message and contingent

Parameters
string$seminar_id
string$user_id
string$statusstatus of user in the seminar (user, autor, tutor, dozent)
boolean$copy_studycourseif true, the studycourse is copied from admission_seminar_user to seminar_user. Overrides the $contingent-parameter
string$contingentoptional studiengang_id, if no id is given, no contingent is considered
string$log_messageoptional log-message. if no log-message is given a default one is used
Returns
bool
normal_update_admission (   $seminar_id,
  $send_message = TRUE 
)

This function updates an admission procedure

The function checks, if user could be insert to the seminar. The User gets a message, if he is inserted to the seminar

Parameters
stringseminar_id the seminar_id of the seminar to calculate
booleansend_message should a system-message be send?
renumber_admission (   $seminar_id,
  $send_message = TRUE 
)

This function numbers a waiting list

Use this functions, if a person was moved from the waiting list or there were other changes to the waiting list. The User gets a message, if the parameter is set and the position on the waiting list has changed.

Parameters
stringseminar_id the seminar_id of the seminar to calculate
booleansend_message should a system-message be send?
update_admission (   $seminar_id,
  $send_message = TRUE 
)