AwardGatheringActivitiesTable
extends Table
in package
AwardGatheringActivities Model
Join table for many-to-many relationship between Awards and GatheringActivities. This table manages which gathering activities an award can be given out during.
Table of Contents
Properties
- $Awards : AwardsTable|BelongsTo
- $GatheringActivities : GatheringActivitiesTable|BelongsTo
Methods
- buildRules() : RulesChecker
- Configure application integrity rules for award-gathering activity associations.
- findOrCreate() : AwardGatheringActivity
- get() : AwardGatheringActivity
- initialize() : void
- Configure table metadata, behaviors, and associations for the AwardGatheringActivities table.
- newEmptyEntity() : AwardGatheringActivity
- newEntities() : array<string|int, AwardGatheringActivity>
- newEntity() : AwardGatheringActivity
- patchEntities() : array<string|int, AwardGatheringActivity>
- patchEntity() : AwardGatheringActivity
- save() : AwardGatheringActivity|false
- saveOrFail() : AwardGatheringActivity
- validationDefault() : Validator
- Configure validation rules ensuring `award_id` and `gathering_activity_id` are present, are integers greater than or equal to zero, and are not empty when creating a record.
Properties
$Awards
public
AwardsTable|BelongsTo
$Awards
$GatheringActivities
public
GatheringActivitiesTable|BelongsTo
$GatheringActivities
Methods
buildRules()
Configure application integrity rules for award-gathering activity associations.
public
buildRules(RulesChecker $rules) : RulesChecker
Adds rules that require the referenced Award and GatheringActivity records to exist and enforces that each (award_id, gathering_activity_id) pair is unique.
Parameters
- $rules : RulesChecker
-
The rules object to be modified.
Return values
RulesChecker —The configured RulesChecker.
findOrCreate()
public
findOrCreate(mixed $search[, callable|null $callback = = 'null' ][, array<string|int, mixed> $options = = '[]' ]) : AwardGatheringActivity
Parameters
- $search : mixed
- $callback : callable|null = = 'null'
- $options : array<string|int, mixed> = = '[]'
Return values
AwardGatheringActivityget()
public
get(mixed $primaryKey[, array<string|int, mixed>|string $finder = = '\'all\'' ][, CacheInterface|string|null $cache = = 'null' ][, Closure|string|null $cacheKey = = 'null' ], mixed ...$args) : AwardGatheringActivity
Parameters
- $primaryKey : mixed
- $finder : array<string|int, mixed>|string = = '\'all\''
- $cache : CacheInterface|string|null = = 'null'
- $cacheKey : Closure|string|null = = 'null'
- $args : mixed
Return values
AwardGatheringActivityinitialize()
Configure table metadata, behaviors, and associations for the AwardGatheringActivities table.
public
initialize(array<string, mixed> $config) : void
Sets table name, display field and primary key, attaches Timestamp and Footprint behaviors, and defines BelongsTo associations to Awards and GatheringActivities.
Parameters
- $config : array<string, mixed>
-
Table configuration.
newEmptyEntity()
public
newEmptyEntity() : AwardGatheringActivity
Return values
AwardGatheringActivitynewEntities()
public
newEntities(array<string|int, mixed> $data[, array<string|int, mixed> $options = = '[]' ]) : array<string|int, AwardGatheringActivity>
Parameters
- $data : array<string|int, mixed>
- $options : array<string|int, mixed> = = '[]'
Return values
array<string|int, AwardGatheringActivity>newEntity()
public
newEntity(array<string|int, mixed> $data[, array<string|int, mixed> $options = = '[]' ]) : AwardGatheringActivity
Parameters
- $data : array<string|int, mixed>
- $options : array<string|int, mixed> = = '[]'
Return values
AwardGatheringActivitypatchEntities()
public
patchEntities(iterable<string|int, mixed> $entities, array<string|int, mixed> $data[, array<string|int, mixed> $options = = '[]' ]) : array<string|int, AwardGatheringActivity>
Parameters
- $entities : iterable<string|int, mixed>
- $data : array<string|int, mixed>
- $options : array<string|int, mixed> = = '[]'
Return values
array<string|int, AwardGatheringActivity>patchEntity()
public
patchEntity(EntityInterface $entity, array<string|int, mixed> $data[, array<string|int, mixed> $options = = '[]' ]) : AwardGatheringActivity
Parameters
- $entity : EntityInterface
- $data : array<string|int, mixed>
- $options : array<string|int, mixed> = = '[]'
Return values
AwardGatheringActivitysave()
public
save(EntityInterface $entity[, array<string|int, mixed> $options = = '[]' ]) : AwardGatheringActivity|false
Parameters
- $entity : EntityInterface
- $options : array<string|int, mixed> = = '[]'
Return values
AwardGatheringActivity|falsesaveOrFail()
public
saveOrFail(EntityInterface $entity[, array<string|int, mixed> $options = = '[]' ]) : AwardGatheringActivity
Parameters
- $entity : EntityInterface
- $options : array<string|int, mixed> = = '[]'
Return values
AwardGatheringActivityvalidationDefault()
Configure validation rules ensuring `award_id` and `gathering_activity_id` are present, are integers greater than or equal to zero, and are not empty when creating a record.
public
validationDefault(Validator $validator) : Validator
Parameters
- $validator : Validator
-
Validator instance to modify.
Return values
Validator —The configured validator.