TaskItem implements RestEntity, PopupDataAggregatable uses ContextCustomer
Table of Contents
Interfaces
- RestEntity
- PopupDataAggregatable
- An interface for classes that have entities within them that should be taken to the top level of a REST response.
Methods
- getById() : self|null
- getColor() : string
- getContext() : Context
- Returns the local or global context for the action.
- getCreatorId() : int
- getDeadline() : DateTime|null
- getId() : int|null
- Returns the id of the entity
- getMembersIds() : array<string|int, int>
- getPopupData() : PopupData
- Returns the data to be raised to the top of the REST response. Works on the principle of the composite pattern.
- getResponsibleId() : int
- getRestEntityName() : string
- Returns the name of the entity that will be used in the rest response
- getState() : string
- getStatus() : int
- getStatusTitle() : string
- getTaskId() : int
- getTitle() : string
- getUrl() : string
- initByRow() : self
- initByTaskObject() : self
- setColor() : TaskItem
- setContext() : self
- Sets new context for operations.
- setContextUser() : self
- setCreatorId() : TaskItem
- setDeadline() : TaskItem
- setMembersIds() : self
- setResponsibleId() : TaskItem
- setState() : TaskItem
- setStatus() : TaskItem
- setStatusTitle() : TaskItem
- setTaskId() : TaskItem
- setTitle() : TaskItem
- toRestFormat() : array<string|int, mixed>|null
- Returns an array in JSON like format to return the entity as a rest response.
- withContext() : static
- Provides local context for the action.
- withContextUser() : static
- Provides local context for the action.
Methods
getById()
public
static getById(int $id[, Context|null $context = null ]) : self|null
Parameters
- $id : int
- $context : Context|null = null
Return values
self|nullgetColor()
public
getColor() : string
Return values
stringgetContext()
Returns the local or global context for the action.
public
getContext() : Context
Return values
ContextgetCreatorId()
public
getCreatorId() : int
Return values
intgetDeadline()
public
getDeadline() : DateTime|null
Return values
DateTime|nullgetId()
Returns the id of the entity
public
getId() : int|null
Return values
int|nullgetMembersIds()
public
getMembersIds() : array<string|int, int>
Return values
array<string|int, int>getPopupData()
Returns the data to be raised to the top of the REST response. Works on the principle of the composite pattern.
public
getPopupData([array<string|int, mixed> $excludedList = [] ]) : PopupData
Parameters
- $excludedList : array<string|int, mixed> = []
Return values
PopupDatagetResponsibleId()
public
getResponsibleId() : int
Return values
intgetRestEntityName()
Returns the name of the entity that will be used in the rest response
public
static getRestEntityName() : string
Return values
stringgetState()
public
getState() : string
Return values
stringgetStatus()
public
getStatus() : int
Return values
intgetStatusTitle()
public
getStatusTitle() : string
Return values
stringgetTaskId()
public
getTaskId() : int
Return values
intgetTitle()
public
getTitle() : string
Return values
stringgetUrl()
public
getUrl() : string
Return values
stringinitByRow()
public
static initByRow(array<string|int, mixed> $row) : self
Parameters
- $row : array<string|int, mixed>
Return values
selfinitByTaskObject()
public
static initByTaskObject(TaskObject $taskObject) : self
Parameters
- $taskObject : TaskObject
Return values
selfsetColor()
public
setColor(string $color) : TaskItem
Parameters
- $color : string
Return values
TaskItemsetContext()
Sets new context for operations.
public
setContext(Context|null $context) : self
Parameters
- $context : Context|null
Return values
selfsetContextUser()
public
setContextUser(mixed $user) : self
Parameters
- $user : mixed
Return values
selfsetCreatorId()
public
setCreatorId(int $creatorId) : TaskItem
Parameters
- $creatorId : int
Return values
TaskItemsetDeadline()
public
setDeadline(DateTime|null $deadline) : TaskItem
Parameters
- $deadline : DateTime|null
Return values
TaskItemsetMembersIds()
public
setMembersIds(array<string|int, mixed> $membersIds) : self
Parameters
- $membersIds : array<string|int, mixed>
Return values
selfsetResponsibleId()
public
setResponsibleId(int $responsibleId) : TaskItem
Parameters
- $responsibleId : int
Return values
TaskItemsetState()
public
setState(string $state) : TaskItem
Parameters
- $state : string
Return values
TaskItemsetStatus()
public
setStatus(int $status) : TaskItem
Parameters
- $status : int
Return values
TaskItemsetStatusTitle()
public
setStatusTitle(string $statusTitle) : TaskItem
Parameters
- $statusTitle : string
Return values
TaskItemsetTaskId()
public
setTaskId(int $taskId) : TaskItem
Parameters
- $taskId : int
Return values
TaskItemsetTitle()
public
setTitle(string $title) : TaskItem
Parameters
- $title : string
Return values
TaskItemtoRestFormat()
Returns an array in JSON like format to return the entity as a rest response.
public
toRestFormat([array<string|int, mixed> $option = [] ]) : array<string|int, mixed>|null
Parameters
- $option : array<string|int, mixed> = []
Return values
array<string|int, mixed>|nullwithContext()
Provides local context for the action.
public
withContext(Context|null $context) : static
Parameters
- $context : Context|null
Return values
staticwithContextUser()
Provides local context for the action.
public
withContextUser(int|User|User $user) : static
Parameters
- $user : int|User|User