Stud.IP  5.4
BasicDataWizardStep Class Reference
Inheritance diagram for BasicDataWizardStep:
CourseWizardStep AdvancedBasicDataWizardStep

Public Member Functions

 getStepTemplate ($values, $stepnumber, $temp_id)
 
 alterValues ($values)
 
 validate ($values)
 
 storeValues ($course, $values)
 
 isRequired ($values)
 
 copy ($course, $values)
 
 getDefaultDeputies ($user_id)
 
 getSearch ($course_type, $institute_ids, $exclude_lecturers=[], $exclude_tutors=[])
 

Static Public Member Functions

static tsearchHelper ($psearch, $context)
 
static lsearchHelper ($psearch, $context)
 

Protected Member Functions

 setupTemplateAttributes ($tpl, $values, $stepnumber, $temp_id)
 
 makeI18N ($values, $indices)
 

Member Function Documentation

◆ alterValues()

alterValues (   $values)

The function only needs to handle person adding and removing as other actions are handled by normal request processing.

Parameters
Array$valuescurrently set values for the wizard.
Returns
bool

Implements CourseWizardStep.

◆ copy()

copy (   $course,
  $values 
)

Copy values for basic data wizard step from given course.

Parameters
Course$course
Array$values

Implements CourseWizardStep.

◆ getDefaultDeputies()

getDefaultDeputies (   $user_id)

Fetches the default deputies for a given person if the necessary config options are set.

Parameters
$user_iduser whose default deputies to get
Returns
Array Default deputy user_ids.

◆ getSearch()

getSearch (   $course_type,
  $institute_ids,
  $exclude_lecturers = [],
  $exclude_tutors = [] 
)

◆ getStepTemplate()

getStepTemplate (   $values,
  $stepnumber,
  $temp_id 
)

Returns the Flexi template for entering the necessary values for this step.

Parameters
Array$valuesPre-set values
int$stepnumberwhich number has the current step in the wizard?
String$temp_idtemporary ID for wizard workflow
Returns
String a Flexi template for getting needed data.

Implements CourseWizardStep.

◆ isRequired()

isRequired (   $values)

Checks if the current step needs to be executed according to already given values. A good example are study areas which are only needed for certain sem_classes.

Parameters
Array$valuesvalues specified from previous steps
Returns
bool Is the current step required for a new course?

Implements CourseWizardStep.

◆ lsearchHelper()

static lsearchHelper (   $psearch,
  $context 
)
static

◆ makeI18N()

makeI18N (   $values,
  $indices 
)
protected

Creates I18N strings from the given values at the given indices.

Parameters
array$valuesthis step's set values
array$indicesthe values to convert to I18NStrings
Returns
array modified values

Create array for configured content languages

◆ setupTemplateAttributes()

setupTemplateAttributes (   $tpl,
  $values,
  $stepnumber,
  $temp_id 
)
protected

◆ storeValues()

storeValues (   $course,
  $values 
)

Stores the given values to the given course.

Parameters
Course$coursethe course to store values for
Array$valuesvalues to set
Returns
Course The course object with updated values.

Implements CourseWizardStep.

◆ tsearchHelper()

static tsearchHelper (   $psearch,
  $context 
)
static

◆ validate()

validate (   $values)

Validates if given values are sufficient for completing the current course wizard step and switch to another one. If not, all errors are collected and shown via PageLayout::postMessage.

Parameters
mixed$valuesArray of stored values
Returns
bool Everything ok?

Implements CourseWizardStep.


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