Stud.IP
6.0
|
Public Member Functions | |
getRequiredPropertyNames () | |
__toString () | |
cbValidate () | |
getFullName () | |
getDefaultPictureUrl () | |
getIcon ($role=Icon::ROLE_INFO) | |
checkHierarchy () | |
getActionLink ($action='show', $link_parameters=[]) | |
getActionURL ($action='show', $url_parameters=[]) | |
findRooms () | |
findLocation () | |
addChild (Resource $resource) | |
createSimpleBooking (User $user, DateTime $begin, DateTime $end, $preparation_time=0, $description='', $internal_comment='', $booking_type=ResourceBooking::TYPE_NORMAL) | |
createBookingFromRequest (User $user, ResourceRequest $request, $preparation_time=0, $description='', $internal_comment='', $booking_type=ResourceBooking::TYPE_NORMAL, $prepend_preparation_time=false, $notify_lecturers=false) | |
createBooking (User $user, $range_id=null, $time_ranges=[], $repetition_interval=null, $repetition_amount=0, $repetition_end_date=null, $preparation_time=0, $description='', $internal_comment='', $booking_type=ResourceBooking::TYPE_NORMAL, $force_booking=false, string $weekdays='') | |
createSimpleRequest (User $user, DateTime $begin, DateTime $end, $comment='', $preparation_time=0) | |
createRequest (User $user, $date_range_ids=null, $comment='', $properties=[], $preparation_time=0) | |
createLock (User $user, DateTime $begin, DateTime $end, $internal_comment='') | |
isAssigned (DateTime $begin, DateTime $end, $excluded_booking_ids=[]) | |
isReserved (DateTime $begin, DateTime $end, $excluded_reservation_ids=[]) | |
isLocked (DateTime $begin, DateTime $end, $excluded_lock_ids=[]) | |
isAvailable (DateTime $begin, DateTime $end, $excluded_booking_ids=[]) | |
Public Member Functions inherited from Resource | |
store () | |
delete () | |
cbValidate () | |
__toString () | |
getFolder ($create_if_missing=true) | |
setFolder (ResourceFolder $folder) | |
createFolder () | |
getRequiredPropertyNames () | |
createSimpleBooking (User $user, DateTime $begin, DateTime $end, $preparation_time=0, $description='', $internal_comment='', $booking_type=ResourceBooking::TYPE_NORMAL) | |
createBookingFromRequest (User $user, ResourceRequest $request, $preparation_time=0, $description='', $internal_comment='', $booking_type=ResourceBooking::TYPE_NORMAL, $prepend_preparation_time=false, $notify_lecturers=false) | |
createBooking (User $user, $range_id=null, $time_ranges=[], $repetition_interval=null, $repetition_amount=0, $repetition_end_date=null, $preparation_time=0, $description='', $internal_comment='', $booking_type=ResourceBooking::TYPE_NORMAL, $force_booking=false, string $weekdays='') | |
createSimpleRequest (User $user, DateTime $begin, DateTime $end, $comment='', $preparation_time=0) | |
createRequest (User $user, $date_range_ids=null, $comment='', $properties=[], $preparation_time=0) | |
createLock (User $user, DateTime $begin, DateTime $end, $internal_comment='') | |
getGroupedProperties ($excluded_properties=[]) | |
propertyExists ($name='') | |
getPropertyObject (string $name) | |
getInfolabelProperties () | |
getProperty (string $name) | |
getPropertyRelatedObject (string $name) | |
setProperty (string $name, $state='', $user=null) | |
setPropertiesByName (array $properties, User $user) | |
setPropertiesById (array $properties, User $user=null) | |
isPropertyEditable (string $name, User $user) | |
setPropertyByDefinitionId ($property_definition_id=null, $state=null) | |
setPropertyRelatedObject (string $name, SimpleORMap $object) | |
deleteProperty (string $name, User $user) | |
getPictureUrl () | |
getDefaultPictureUrl () | |
getIcon ($role=Icon::ROLE_INFO) | |
getPropertyArray ($only_requestable_properties=false) | |
isAssigned (DateTime $begin, DateTime $end, $excluded_booking_ids=[]) | |
isReserved (DateTime $begin, DateTime $end, $excluded_reservation_ids=[]) | |
isLocked (DateTime $begin, DateTime $end, $excluded_lock_ids=[]) | |
isAvailable (DateTime $begin, DateTime $end, $excluded_booking_ids=[]) | |
isAvailableForRequest (ResourceRequest $request) | |
getFullName () | |
setUserPermission (User $user, $perm='autor') | |
deleteUserPermission (User $user) | |
deleteAllPermissions () | |
getUserPermission (User $user, $time_range=[], $permanent_only=false) | |
userHasPermission (?User $user, string $permission='user', array $time_range=[]) | |
userMayCreateChild (User $user) | |
userHasRequestRights (User $user) | |
userHasBookingRights (User $user, $begin=null, $end=null) | |
bookingPlanVisibleForUser (?User $user, $time_range=[]) | |
findParentByClassName ($class_name='Resource') | |
findChildrenByClassName ( $class_name='Resource', $depth=0, $convert_objects=true, $order_by_name=true) | |
addChild (Resource $resource) | |
getOpenResourceRequests (DateTime $begin, DateTime $end) | |
getResourceBookings (DateTime $begin, DateTime $end, array $booking_types=[0]) | |
getResourceLocks (DateTime $begin, DateTime $end) | |
hasFiles () | |
getDerivedClassInstance () | |
checkHierarchy () | |
getActionLink ($action='show', $link_parameters=[]) | |
getActionURL ($action='show', $url_parameters=[]) | |
getItemName ($long_format=true) | |
getItemURL () | |
getItemAvatarURL () | |
getLink () | |
Public Member Functions inherited from SimpleORMap | |
__construct ($id=null) | |
__clone () | |
getRelationOptions ($relation) | |
getTableMetadata () | |
hasAutoIncrementColumn () | |
setId ($id) | |
getId () | |
getNewId () | |
toArray ($only_these_fields=null) | |
toRawArray ($only_these_fields=null) | |
toArrayRecursive ($only_these_fields=null) | |
getValue ($field) | |
getRelationValue ($relation, $field) | |
getDefaultValue ($field) | |
setValue ($field, $value) | |
__get ($field) | |
__set ($field, $value) | |
__isset ($field) | |
offsetExists ($offset) | |
offsetGet ($offset) | |
offsetSet ($offset, $value) | |
offsetUnset ($offset) | |
getIterator () | |
count () | |
isField ($field) | |
isRelation ($field) | |
isAdditionalField ($field) | |
isAliasField ($field) | |
isI18nField ($field) | |
setData ($data, $reset=false) | |
isNew () | |
isDeleted () | |
setNew ($is_new) | |
getWhereQuery () | |
restore () | |
store () | |
triggerChdate () | |
delete () | |
isDirty () | |
isFieldDirty ($field) | |
revertValue ($field) | |
getPristineValue ($field) | |
initRelation ($relation) | |
resetRelation ($relation) | |
cleanup () | |
Static Public Member Functions | |
static | findAll () |
static | getTranslatedClassName ($item_count=1) |
static | getRequiredProperties () |
static | findByLocation ($location_id=null) |
static | getLinkForAction ( $action='show', $id=null, $link_parameters=[]) |
static | getURLForAction ( $action='show', $id=null, $url_parameters=[]) |
Static Public Member Functions inherited from Resource | |
static | findChildren ($resource_id) |
static | getTranslatedClassName ($item_count=1) |
static | getRootResources () |
static | getRequiredProperties () |
static | getLinkForAction ( $action='show', $id=null, $link_parameters=[]) |
static | getURLForAction ( $action='show', $id=null, $url_parameters=[]) |
Static Public Member Functions inherited from SimpleORMap | |
static | tableScheme ($db_table) |
static | expireTableScheme () |
static | exists ($id) |
static | countBySql ($sql='1', $params=[]) |
static | create ($data) |
static | build ($data, $is_new=true) |
static | buildExisting ($data) |
static | import ($data) |
static | findBySQL ($sql, $params=[]) |
static | findOneBySQL ($where, $params=[]) |
static | findThru ($foreign_key_value, $options) |
static | findEachBySQL ($callable, $sql, $params=[]) |
static | findMany ($pks=[], $order='', $order_params=[]) |
static | findEachMany ($callable, $pks=[], $order='', $order_params=[]) |
static | findAndMapBySQL ($callable, $where, $params=[]) |
static | findAndMapMany ($callable, $pks=[], $order='', $order_params=[]) |
static | deleteBySQL ($where, $params=[]) |
static | toObject ($id_or_object) |
static | __callStatic (string $name, array $arguments) |
Static Protected Member Functions | |
static | configure ($config=[]) |
static | buildPathForAction ($action='show', $id=null) |
Static Protected Member Functions inherited from Resource | |
static | configure ($config=[]) |
static | buildPathForAction ($action='show', $id=null) |
Static Protected Member Functions inherited from SimpleORMap | |
static | db_table () |
static | db_fields () |
static | pk () |
static | default_values () |
static | serialized_fields () |
static | alias_fields () |
static | i18n_fields () |
static | additional_fields () |
static | has_many () |
static | has_one () |
static | belongs_to () |
static | has_and_belongs_to_many () |
static | registered_callbacks () |
static | known_slots () |
static | notification_map () |
static | getter_setter_map () |
static | configure ($config=[]) |
static | config ($key) |
static | registerCallback ($types, $cb) |
static | unregisterCallback ($types, $cb) |
Static Protected Attributes | |
static | $required_properties |
Static Protected Attributes inherited from Resource | |
static | $permission_cache |
Static Protected Attributes inherited from SimpleORMap | |
static | $config = [] |
static | $reserved_slots = ['value','newid','iterator','tablemetadata', 'relationvalue','wherequery','relationoptions','data','new','id'] |
static | $performs_batch_operation = false |
Additional Inherited Members | |
Data Fields inherited from SimpleORMap | |
const | ID_SEPARATOR = '_' |
Static Public Attributes inherited from SimpleORMap | |
static | $schemes = null |
Protected Member Functions inherited from SimpleORMap | |
_getId ($field) | |
_setId ($field, $value) | |
_getAdditionalValueFromRelation ($field) | |
_setAdditionalValueFromRelation ($field, $value) | |
_getAdditionalValue ($field) | |
_setAdditionalValue ($field, $value) | |
parseRelationOptions ($type, $name, $options) | |
storeRelations ($only_these=null) | |
deleteRelations () | |
initializeContent () | |
applyCallbacks ($type) | |
cbNotificationMapper ($cb_type) | |
cbAfterInitialize ($cb_type) | |
setSerializedValue ($field, $value) | |
setI18nValue ($field, $value) | |
Protected Attributes inherited from SimpleORMap | |
$content = [] | |
$content_db = [] | |
$is_new = true | |
$is_deleted = false | |
$relations = [] | |
$additional_data = [] | |
string | $i18n_class = I18NString::class |
__toString | ( | ) |
Implements StudipItem.
addChild | ( | Resource | $resource | ) |
Adds a child resource to this building. The child resource must not be a resource of the class Building or Location.
Resource | $resource | The resource which shall be added as child. |
InvalidResourceException | If the specified resource belongs to the resource classes Building or Location. |
|
staticprotected |
Returns the part of the URL for getLink and getURL which will be placed inside the calls to URLHelper::getLink and URLHelper::getURL in these methods.
string | $action | The action for the building. |
string | $id | The ID of the building. |
InvalidArgumentException | If $building_id is empty. |
cbValidate | ( | ) |
checkHierarchy | ( | ) |
|
staticprotected |
createBooking | ( | User | $user, |
$range_id = null , |
|||
$time_ranges = [] , |
|||
$repetition_interval = null , |
|||
$repetition_amount = 0 , |
|||
$repetition_end_date = null , |
|||
$preparation_time = 0 , |
|||
$description = '' , |
|||
$internal_comment = '' , |
|||
$booking_type = ResourceBooking::TYPE_NORMAL , |
|||
$force_booking = false , |
|||
string | $weekdays = '' |
||
) |
createBookingFromRequest | ( | User | $user, |
ResourceRequest | $request, | ||
$preparation_time = 0 , |
|||
$description = '' , |
|||
$internal_comment = '' , |
|||
$booking_type = ResourceBooking::TYPE_NORMAL , |
|||
$prepend_preparation_time = false , |
|||
$notify_lecturers = false |
|||
) |
createLock | ( | User | $user, |
DateTime | $begin, | ||
DateTime | $end, | ||
$internal_comment = '' |
|||
) |
createRequest | ( | User | $user, |
$date_range_ids = null , |
|||
$comment = '' , |
|||
$properties = [] , |
|||
$preparation_time = 0 |
|||
) |
createSimpleBooking | ( | User | $user, |
DateTime | $begin, | ||
DateTime | $end, | ||
$preparation_time = 0 , |
|||
$description = '' , |
|||
$internal_comment = '' , |
|||
$booking_type = ResourceBooking::TYPE_NORMAL |
|||
) |
createSimpleRequest | ( | User | $user, |
DateTime | $begin, | ||
DateTime | $end, | ||
$comment = '' , |
|||
$preparation_time = 0 |
|||
) |
|
static |
|
static |
Finds buildings by a location specified by its ID.
string | $location_id | The ID of the location. |
findLocation | ( | ) |
Retrieves the location where this building is assigned to by looking up the parent resources of this building.
findRooms | ( | ) |
getActionLink | ( | $action = 'show' , |
|
$link_parameters = [] |
|||
) |
Returns the link for an action for this building. This is the non-static variant of Building::getLinkForAction.
string | $action | The action which shall be executed. For buildings the actions 'show', 'booking_plan', 'add', 'edit' and 'delete' are defined. |
array | $link_parameters | Optional parameters for the link. |
getActionURL | ( | $action = 'show' , |
|
$url_parameters = [] |
|||
) |
Returns the URL for an action for this building. This is the non-static variant of Building::getURLForAction.
string | $action | The action which shall be executed. For buildings the actions 'show', 'booking_plan', 'add', 'edit' and 'delete' are defined. |
array | $link_parameters | Optional parameters for the URL. |
getDefaultPictureUrl | ( | ) |
Returns the path for the building's image. If the building has no image the path for a general building icon will be returned.
getFullName | ( | ) |
Returns the full (localised) name of the building.
getIcon | ( | $role = Icon::ROLE_INFO | ) |
|
static |
Returns the appropriate link for the building action that shall be executed on a building.
string | $action | The action which shall be executed. For buildings the actions 'show', 'booking_plan', 'add', 'edit' and 'delete' are defined. |
string | $id | The ID of the building on which the specified action shall be executed. |
$link_parameters |
|
static |
getRequiredPropertyNames | ( | ) |
|
static |
|
static |
Returns the appropriate URL for the building action that shall be executed on a building.
string | $action | The action which shall be executed. For buildings the actions 'show', 'booking_plan', 'add', 'edit' and 'delete' are defined. |
string | $id | The ID of the building on which the specified action shall be executed. |
$url_parameters |
isAssigned | ( | DateTime | $begin, |
DateTime | $end, | ||
$excluded_booking_ids = [] |
|||
) |
isAvailable | ( | DateTime | $begin, |
DateTime | $end, | ||
$excluded_booking_ids = [] |
|||
) |
isLocked | ( | DateTime | $begin, |
DateTime | $end, | ||
$excluded_lock_ids = [] |
|||
) |
isReserved | ( | DateTime | $begin, |
DateTime | $end, | ||
$excluded_reservation_ids = [] |
|||
) |
|
staticprotected |