# Stage
In FLuentBoards, each board is made up of one or more stages. These stages are normally arranged side by side on the board, allowing you to see your entire workflow at a glance.
# Creating a stage
If you want to create a stage in a board:
FluentBoardsApi('stages')->create($stageData);
FluentBoardsApi() this is fluent-boards global api function. You need to pass 'stages' argument to access all stage related api.
create() method is used to create a new stage. This function takes $stageData as an argument which must be an associative array.
$taskData = [
'title' => 'Test Stage',
'board_id' => 1,
'status' => 'open'
];
2
3
4
5
$taskData['title']stringrequired$taskData['board_id']integerrequired$taskData['status']stringvalues:'open'or'closed', default:'open'
# Getting Stages of a Board
FluentBoardsApi('stages')->getStagesByBoard($boardId, $with = []);
Parameters
- $boardId
intrequired - $with
array
Return array
# Getting a task
FluentBoardsApi('stages')->getStage($taskId, $with = []);
Parameters
- $taskId
intrequired - $with
array
Return object
# Updating a stage
FluentBoardsApi('stages')->updateProperty($stageId, $property, $value);
Parameters
- $stageId
intrequired - $property
stringrequired, possible values:'title'or'status'or'bg_color' - $value
stringrequired
$value could be either a value of title or status or bg_color. For title it will be a regular
string, for status it must be a string valued either 'open' or 'closed' and for bg_color will must be
color hex code like '#DAF7A6'
Return object
# Archiving a stage
FluentBoardsApi('stages')->archiveStage($stageId);
Parameters
- $stageId
intrequired
Return object
# Restoring a archived stage
FluentBoardsApi('stages')->restoreStage($stageId);
Parameters
- $stageId
intrequired
Return object