You are here

function checklistapi_checklist_load in Checklist API 8

Same name and namespace in other branches
  1. 7 checklistapi.module \checklistapi_checklist_load()

Loads a checklist object.

Parameters

string $id: The checklist ID.

Return value

Drupal\checklistapi\ChecklistapiChecklist|false A fully-loaded checklist object, or FALSE if the checklist is not found.

7 calls to checklistapi_checklist_load()
ChecklistapiChecklistClearForm::buildForm in src/Form/ChecklistapiChecklistClearForm.php
Form constructor.
ChecklistapiChecklistForm::buildForm in src/Form/ChecklistapiChecklistForm.php
Form constructor.
ChecklistapiCommands::infoCommand in src/Commands/ChecklistapiCommands.php
Show detailed info for a given checklist.
ChecklistapiCommands::listCommand in src/Commands/ChecklistapiCommands.php
Get an overview of your installed checklists with progress details.
ChecklistapiController::report in src/Controller/ChecklistapiController.php
Returns the Checklists report.

... See full list

File

./checklistapi.module, line 54
An API for creating fillable, persistent checklists.

Code

function checklistapi_checklist_load($id) {
  $definition = checklistapi_get_checklist_info($id);
  return $definition ? new ChecklistapiChecklist($definition) : FALSE;
}