KMP PHP API Reference

BestowalUpdateService
in package
uses LocatorAwareTrait

Applies bestowal edit form updates including link changes and field updates.

Table of Contents

Properties

$actionItemService  : ActionItemService
$courtSlotService  : BestowalCourtSlotService
$gatheringLookupService  : BestowalGatheringLookupService
$linkService  : BestowalRecommendationLinkService
$syncService  : BestowalRecommendationSyncService

Methods

__construct()  : mixed
assignGathering()  : array<string, mixed>
Assign a gathering using the same guarded update path as the edit form.
reopenScheduling()  : ServiceResult
Undo a checklist assignment while the ActionItem service holds the owner mutex.
update()  : array<string, mixed>
Update a bestowal from edit form data.
clearCourtAssignment()  : void
Clear court placement when the owning gathering changes or is removed.
failureResult()  : array<string, mixed>
normalizeIdList()  : array<string|int, int>

Properties

Methods

__construct()

public __construct([BestowalRecommendationSyncService|null $syncService = null ][, BestowalRecommendationLinkService|null $linkService = null ][, BestowalGatheringLookupService|null $gatheringLookupService = null ][, BestowalCourtSlotService|null $courtSlotService = null ][, ActionItemService|null $actionItemService = null ]) : mixed
Parameters
$syncService : BestowalRecommendationSyncService|null = null

Optional sync service.

$linkService : BestowalRecommendationLinkService|null = null

Optional link service.

$gatheringLookupService : BestowalGatheringLookupService|null = null

Optional lookup service.

$courtSlotService : BestowalCourtSlotService|null = null

Optional court slot service.

$actionItemService : ActionItemService|null = null

Optional action item service.

assignGathering()

Assign a gathering using the same guarded update path as the edit form.

public assignGathering(Table $bestowalsTable, int $bestowalId, int $gatheringId, int $actorId[, bool $futureOnly = true ][, bool $autoCompleteTodos = true ]) : array<string, mixed>
Parameters
$bestowalsTable : Table

Bestowals table.

$bestowalId : int

Bestowal ID.

$gatheringId : int

Gathering ID.

$actorId : int

Actor performing the update.

$futureOnly : bool = true

When true, only future gatherings are selectable.

$autoCompleteTodos : bool = true

Whether satisfied required-field to-dos should be system-closed.

Return values
array<string, mixed>

reopenScheduling()

Undo a checklist assignment while the ActionItem service holds the owner mutex.

public reopenScheduling(int $bestowalId, int $actorId, bool $clearGathering) : ServiceResult
Parameters
$bestowalId : int
$actorId : int
$clearGathering : bool
Return values
ServiceResult

update()

Update a bestowal from edit form data.

public update(Table $bestowalsTable, int $bestowalId, array<string, mixed> $data, int $actorId) : array<string, mixed>
Parameters
$bestowalsTable : Table

Bestowals table.

$bestowalId : int

Bestowal ID.

$data : array<string, mixed>

Form data.

$actorId : int

Actor performing the update.

Return values
array<string, mixed>

clearCourtAssignment()

Clear court placement when the owning gathering changes or is removed.

private clearCourtAssignment(Bestowal $bestowal) : void
Parameters
$bestowal : Bestowal

Bestowal being updated.

failureResult()

private failureResult(string $error) : array<string, mixed>
Parameters
$error : string

Error message.

Return values
array<string, mixed>

normalizeIdList()

private normalizeIdList(mixed $value) : array<string|int, int>
Parameters
$value : mixed

Raw ID list from form data.

Return values
array<string|int, int>
On this page

Search results