|
Stud.IP
trunk Revision
|


Static Public Member Functions | |
| static | getDescription () |
| static | getName () |
Static Public Member Functions inherited from AdmissionRule | |
| static | getAvailableAdmissionRules ($activeOnly=true) |
| static | getInputFrame () |
| static | getDescription () |
| static | getName () |
Data Fields | |
| $conditions = [] | |
| $conditiongroups = [] | |
| $ungrouped_conditions = [] | |
| $quota = [] | |
| $conditiongroups_allowed = null | |
| $siblings = [] | |
Data Fields inherited from AdmissionRule | |
| $endTime = 0 | |
| $id = '' | |
| $message = '' | |
| $default_message = '' | |
| $startTime = 0 | |
| $courseSetId = '' | |
| $siblings = [] | |
| $siblings_override = false | |
| __construct | ( | $ruleId = '', |
|
$courseSetId = '' |
|||
| ) |
Standard constructor.
| String | ruleId If this rule has been saved previously, it will be loaded from database. |
Reimplemented from AdmissionRule.

| __clone | ( | ) |
Reimplemented from AdmissionRule.
| addCondition | ( | $condition, | |
$group = '', |
|||
$quota = 0 |
|||
| ) |
Adds a new UserFilter to this rule.
| UserFilter | condition |
| String | group |
| Int | quota |

| conditiongroupsAllowed | ( | ) |
Checks if condition groups are allowed.

| delete | ( | ) |
Deletes the admission rule and all associated data.
Reimplemented from AdmissionRule.

| getAffectedUsers | ( | ) |
Gets all users that are matched by thÃs rule.
Reimplemented from AdmissionRule.
| getConditionGroups | ( | ) |
Gets all grouped conditiongroups.
| getConditions | ( | ) |
Gets all defined conditions.
|
static |
Gets some text that describes what this AdmissionRule (or respective subclass) does.
Reimplemented from AdmissionRule.
| getMessage | ( | $condition = null | ) |
|
static |
Return this rule's name.
Reimplemented from AdmissionRule.
| getQuota | ( | $group_id | ) |
Gets quota for given conditiongroup.
| getTemplate | ( | ) |
Gets the template that provides a configuration GUI for this rule.
Reimplemented from AdmissionRule.
| getUngroupedConditions | ( | ) |
Gets all grouped conditiongroups.
| load | ( | ) |
Helper function for loading data from DB. Generic AdmissionRule data is loaded with the parent load() method.
Reimplemented from AdmissionRule.


| removeCondition | ( | $conditionId | ) |
Removes the condition with the given ID from the rule.
| String | conditionId |
| removeConditionGroups | ( | ) |
Removes condition groups and sets all conditions as ungrouped.
| ruleApplies | ( | $userId, | |
| $courseId | |||
| ) |
Checks whether the given user fulfills the configured admission conditions. Only one of the conditions needs to be fulfilled (logical operator OR). The fields in a condition are in conjunction (logical operator AND).
| String | $userId | |
| String | $courseId |
Reimplemented from AdmissionRule.

| setAllData | ( | $data | ) |
Uses the given data to fill the object values. This can be used as a generic function for storing data if the concrete rule type isn't known in advance.
| Array | $data |
Reimplemented from AdmissionRule.

| setSiblings | ( | $siblings = [] | ) |
set sibling rules
Reimplemented from AdmissionRule.
| store | ( | ) |
Helper function for storing data to DB.
Reimplemented from AdmissionRule.

| toString | ( | ) |
| validate | ( | $data | ) |
Validates if the given request data is sufficient to configure this rule (e.g. if required values are present).
| Array | Request data |
Reimplemented from AdmissionRule.
| $conditiongroups = [] |
Grouped conditions that must be fulfilled for successful admission.
| $conditiongroups_allowed = null |
Are condition groups allowed?
| $conditions = [] |
All conditions that must be fulfilled for successful admission.
| $quota = [] |
Quota for grouped conditions
| $siblings = [] |
courseset siblings of this rule
| $ungrouped_conditions = [] |
Conditions that must be fulfilled for successful admission.