commiting uncommited changes on live site
[weblabels.fsf.org.git] / crm.fsf.org / 20131203 / files / sites / all / modules-old / ctools / page_manager / help / api-task-handler.html
1 task handler definition:
2 title -- visible title of the task handler.
3 description -- description of the task handler.
4 task type -- The type of the task this handler can service.
5 render -- callback of the function to render the handler. The arguments to this callback are specific to the task type.
6 admin title -- callback to render the admin title as this handler is listed.
7 params: $handler, $task, $subtask_id
8 admin summary -- callback to render what's in the collapsible info as the handler is listed. Optional.
9 params: $handler, $task, $subtask_id
10 default conf -- either an array() of default conf data or a callback that returns an array.
11 params: $handler, $task, $subtask_id
12 save -- callback to call just prior to the task handler being saved so it can adjust its data.
13 params: &$handler, $update (as drupal_write_record would receive)
14 export -- callback to call just prior to the task being exported. It should return text to append to the export if necessary.
15 params: &$handler, $indent
16
17 forms => array(
18 'id' => array(
19 'form' => form callback (receives $form, $form_state)
20 'submit' => submit callback
21 'validate' => validate callback
22 'include' => an optional file to include to get functionality for this form. Must include full path.
23 'no return' => hide the 'return' button, meaning that the form requires extra steps if submitted
24 'alternate next' => an alternate next form. Used for hidden edit forms that don't have tabs.
25 'no blocks' => if TRUE, use Drupal's mechanism to not render blocks for this form.
26 )
27 )
28 ),
29
30 'add forms' => array(
31 'form1', => t('form title'),
32 'form2', => t('form title'),
33 // ...etc.../
34 ),
35 'edit forms' => array(
36 'id' => t('tab name'),
37 'id2' => t('tab name'),
38 ),
39
40 If a form name is blank it is a 'hidden' form -- it has no tab but can still be reached.
41
42
43 Notes: Because #required validation cannot be skipped when clicking cancel, please don't use it.