GatheringWaiversTable
extends Table
in package
GatheringWaivers Model
Table of Contents
Properties
- $AuditNotes : NotesTable|HasMany
- $CreatedByMembers : MembersTable|BelongsTo
- $Documents : DocumentsTable|BelongsTo
- $Gatherings : GatheringsTable|BelongsTo
- $WaiverTypes : WaiverTypesTable|BelongsTo
Methods
- buildRules() : RulesChecker
- Returns a rules checker object that will be used for validating application integrity.
- countGatheringsNeedingWaivers() : int
- Count gatherings needing waivers for a specific user
- deleteMany() : iterable<string|int, GatheringWaiver>|ResultSetInterface<string|int, GatheringWaiver>|false
- deleteManyOrFail() : iterable<string|int, GatheringWaiver>|ResultSetInterface<string|int, GatheringWaiver>
- findByGathering() : SelectQuery
- Find waivers for a specific gathering
- findByStatus() : SelectQuery
- Find waivers by status
- findExpired() : SelectQuery
- Find expired waivers
- findOrCreate() : GatheringWaiver
- findValidByGathering() : SelectQuery
- Find valid (non-declined) waivers for a specific gathering
- get() : GatheringWaiver
- initialize() : void
- Initialize method
- newEmptyEntity() : GatheringWaiver
- newEntities() : array<string|int, GatheringWaiver>
- newEntity() : GatheringWaiver
- patchEntities() : array<string|int, GatheringWaiver>
- patchEntity() : GatheringWaiver
- save() : GatheringWaiver|false
- saveMany() : iterable<string|int, GatheringWaiver>|ResultSetInterface<string|int, GatheringWaiver>|false
- saveManyOrFail() : iterable<string|int, GatheringWaiver>|ResultSetInterface<string|int, GatheringWaiver>
- saveOrFail() : GatheringWaiver
- validationDefault() : Validator
- Default validation rules.
Properties
$AuditNotes
public
NotesTable|HasMany
$AuditNotes
$CreatedByMembers
public
MembersTable|BelongsTo
$CreatedByMembers
$Documents
public
DocumentsTable|BelongsTo
$Documents
$Gatherings
public
GatheringsTable|BelongsTo
$Gatherings
$WaiverTypes
public
WaiverTypesTable|BelongsTo
$WaiverTypes
Methods
buildRules()
Returns a rules checker object that will be used for validating application integrity.
public
buildRules(RulesChecker $rules) : RulesChecker
Parameters
- $rules : RulesChecker
-
The rules object to be modified.
Return values
RulesCheckercountGatheringsNeedingWaivers()
Count gatherings needing waivers for a specific user
public
static countGatheringsNeedingWaivers(int $memberId) : int
Returns the count of gatherings where:
- End date is today or in the future
- Have required waivers configured
- Missing at least one required waiver upload
- User has permission to upload waivers for the gathering's branch OR is a steward
Parameters
- $memberId : int
-
The member ID to check permissions for
Return values
int —Count of gatherings needing waivers
deleteMany()
public
deleteMany(iterable<string|int, mixed> $entities[, array<string|int, mixed> $options = = '[]' ]) : iterable<string|int, GatheringWaiver>|ResultSetInterface<string|int, GatheringWaiver>|false
Parameters
- $entities : iterable<string|int, mixed>
- $options : array<string|int, mixed> = = '[]'
Return values
iterable<string|int, GatheringWaiver>|ResultSetInterface<string|int, GatheringWaiver>|falsedeleteManyOrFail()
public
deleteManyOrFail(iterable<string|int, mixed> $entities[, array<string|int, mixed> $options = = '[]' ]) : iterable<string|int, GatheringWaiver>|ResultSetInterface<string|int, GatheringWaiver>
Parameters
- $entities : iterable<string|int, mixed>
- $options : array<string|int, mixed> = = '[]'
Return values
iterable<string|int, GatheringWaiver>|ResultSetInterface<string|int, GatheringWaiver>findByGathering()
Find waivers for a specific gathering
public
findByGathering(SelectQuery $query, int $gatheringId) : SelectQuery
Parameters
- $query : SelectQuery
-
The query object
- $gatheringId : int
-
The gathering ID
Return values
SelectQueryfindByStatus()
Find waivers by status
public
findByStatus(SelectQuery $query, string $status) : SelectQuery
Parameters
- $query : SelectQuery
-
The query object
- $status : string
-
The status to filter by
Return values
SelectQueryfindExpired()
Find expired waivers
public
findExpired(SelectQuery $query) : SelectQuery
Parameters
- $query : SelectQuery
-
The query object
Return values
SelectQueryfindOrCreate()
public
findOrCreate(mixed $search[, callable|null $callback = = 'null' ][, array<string|int, mixed> $options = = '[]' ]) : GatheringWaiver
Parameters
- $search : mixed
- $callback : callable|null = = 'null'
- $options : array<string|int, mixed> = = '[]'
Return values
GatheringWaiverfindValidByGathering()
Find valid (non-declined) waivers for a specific gathering
public
findValidByGathering(SelectQuery $query, int $gatheringId) : SelectQuery
Returns waivers that have not been declined and are not soft-deleted. This is useful for determining actual waiver coverage and compliance.
Parameters
- $query : SelectQuery
-
The query object
- $gatheringId : int
-
The gathering ID
Return values
SelectQueryget()
public
get(mixed $primaryKey[, array<string|int, mixed>|string $finder = = '\'all\'' ][, CacheInterface|string|null $cache = = 'null' ][, Closure|string|null $cacheKey = = 'null' ], mixed ...$args) : GatheringWaiver
Parameters
- $primaryKey : mixed
- $finder : array<string|int, mixed>|string = = '\'all\''
- $cache : CacheInterface|string|null = = 'null'
- $cacheKey : Closure|string|null = = 'null'
- $args : mixed
Return values
GatheringWaiverinitialize()
Initialize method
public
initialize(array<string, mixed> $config) : void
Parameters
- $config : array<string, mixed>
-
The configuration for the Table.
newEmptyEntity()
public
newEmptyEntity() : GatheringWaiver
Return values
GatheringWaivernewEntities()
public
newEntities(array<string|int, mixed> $data[, array<string|int, mixed> $options = = '[]' ]) : array<string|int, GatheringWaiver>
Parameters
- $data : array<string|int, mixed>
- $options : array<string|int, mixed> = = '[]'
Return values
array<string|int, GatheringWaiver>newEntity()
public
newEntity(array<string|int, mixed> $data[, array<string|int, mixed> $options = = '[]' ]) : GatheringWaiver
Parameters
- $data : array<string|int, mixed>
- $options : array<string|int, mixed> = = '[]'
Return values
GatheringWaiverpatchEntities()
public
patchEntities(iterable<string|int, mixed> $entities, array<string|int, mixed> $data[, array<string|int, mixed> $options = = '[]' ]) : array<string|int, GatheringWaiver>
Parameters
- $entities : iterable<string|int, mixed>
- $data : array<string|int, mixed>
- $options : array<string|int, mixed> = = '[]'
Return values
array<string|int, GatheringWaiver>patchEntity()
public
patchEntity(EntityInterface $entity, array<string|int, mixed> $data[, array<string|int, mixed> $options = = '[]' ]) : GatheringWaiver
Parameters
- $entity : EntityInterface
- $data : array<string|int, mixed>
- $options : array<string|int, mixed> = = '[]'
Return values
GatheringWaiversave()
public
save(EntityInterface $entity[, array<string|int, mixed> $options = = '[]' ]) : GatheringWaiver|false
Parameters
- $entity : EntityInterface
- $options : array<string|int, mixed> = = '[]'
Return values
GatheringWaiver|falsesaveMany()
public
saveMany(iterable<string|int, mixed> $entities[, array<string|int, mixed> $options = = '[]' ]) : iterable<string|int, GatheringWaiver>|ResultSetInterface<string|int, GatheringWaiver>|false
Parameters
- $entities : iterable<string|int, mixed>
- $options : array<string|int, mixed> = = '[]'
Return values
iterable<string|int, GatheringWaiver>|ResultSetInterface<string|int, GatheringWaiver>|falsesaveManyOrFail()
public
saveManyOrFail(iterable<string|int, mixed> $entities[, array<string|int, mixed> $options = = '[]' ]) : iterable<string|int, GatheringWaiver>|ResultSetInterface<string|int, GatheringWaiver>
Parameters
- $entities : iterable<string|int, mixed>
- $options : array<string|int, mixed> = = '[]'
Return values
iterable<string|int, GatheringWaiver>|ResultSetInterface<string|int, GatheringWaiver>saveOrFail()
public
saveOrFail(EntityInterface $entity[, array<string|int, mixed> $options = = '[]' ]) : GatheringWaiver
Parameters
- $entity : EntityInterface
- $options : array<string|int, mixed> = = '[]'
Return values
GatheringWaivervalidationDefault()
Default validation rules.
public
validationDefault(Validator $validator) : Validator
Parameters
- $validator : Validator
-
Validator instance.