Mailinglist
 All Data Structures Files Functions Variables Pages
MailinglistListUI Class Reference

Represents an Mailinglist personality module. More...

Inheritance diagram for MailinglistListUI:
Inheritance graph
[legend]
Collaboration diagram for MailinglistListUI:
Collaboration graph
[legend]

Public Member Functions

ctools_export_ui
 edit_form (&$form, &$form_state)
 Implements ctools_export_ui::edit_form(). More...
 
 hook_menu (&$items)
 Implements ctools_export_ui:hook_menu() More...
 
 list_header ($form_state)
 list_header() More...
 
 test_page ($js, $input, $mailbox)
 Callback to test a mailbox connection. More...
 
- Public Member Functions inherited from MailinglistExportUI
 edit_form (&$form, &$form_state)
 Implements ctools_export_ui::edit_form(). More...
 
 edit_form_validate (&$form, &$form_state)
 Implements ctools_export_ui::edit_form_validate(). More...
 
 edit_form_submit (&$form, &$form_state)
 Implements ctools_export_ui::edit_form_submit(). More...
 
 edit_save_form ($form_state)
 
 delete_form_submit (&$form_state)
 Implements ctools_export_ui::delete_form_submit(). More...
 

Detailed Description

Represents an Mailinglist personality module.

Definition at line 11 of file MailinglistListUI.class.php.

Member Function Documentation

edit_form ( $form,
$form_state 
)

Implements ctools_export_ui::edit_form().

Definition at line 20 of file MailinglistListUI.class.php.

References _mailinglist_build_options(), and mailinglist_get_plugins().

20  {
21  // All Retrievers will need some settings for connection.
22  $form['basic']['#tree'] = FALSE;
23  $form['basic']['#weight'] = 20;
24  $form['basic']['settings']= array(
25  '#type' => 'fieldset',
26  '#title' => 'Basic List settings',
27  '#tree' => TRUE,
28  '#collapsible' => TRUE,
29  '#collapsed' => FALSE,
30  );
31 
32  $form['extra']['#tree'] = FALSE;
33  $form['extra']['#weight'] = 90;
34  $form['extra']['settings']= array(
35  '#type' => 'fieldset',
36  '#title' => 'Advanced Settings',
37  '#tree' => TRUE,
38  '#collapsible' => TRUE,
39  '#collapsed' => TRUE,
40  );
41 
42 
43  parent::edit_form($form, $form_state);
44  // object_type selection is not dependant on type of object
45 
46  $list_plugins = mailinglist_get_plugins('mailinglist', 'list');
47  /* Type of Mailing List */
48  $form['info']['object_type'] = array(
49  '#type' => 'select',
50  '#title' => t('List Type'),
51  '#options' => _mailinglist_build_options($list_plugins),
52  '#default_value' => isset($form_state['item']->object_type) ? $form_state['item']->object_type : NULL,
53  '#description' => t('The List presonality plugin to use for this list'),
54  '#required' => TRUE,
55  );
56  }
_mailinglist_build_options($source, $key_name= 'name')
Builds a Select control array from a menu form an array from a ctools_get_plugin. ...
mailinglist_get_plugins($module, $type)
Wrapper to load plugins.

Here is the call graph for this function:

hook_menu ( $items)

Implements ctools_export_ui:hook_menu()

Definition at line 61 of file MailinglistListUI.class.php.

61  {
62  parent::hook_menu($items);
63  if (isset($items['admin/config/system/mailinglist/list'])) {
64  $items['admin/config/system/mailinglist/list']['type'] = MENU_LOCAL_TASK;
65  }
66  }
list_header (   $form_state)

list_header()

Definition at line 71 of file MailinglistListUI.class.php.

71  {
72  if (isset($form_state['input']['test_result'])) {
73  return $form_state['input']['test_result'];
74  }
75  }
test_page (   $js,
  $input,
  $mailbox 
)

Callback to test a mailbox connection.

Definition at line 80 of file MailinglistListUI.class.php.

References _mailinglist_mailbox_test_output().

80  {
81  $input['test_result'] = _mailinglist_mailbox_test_output($mailbox);
82  if (!$js) {
83  drupal_goto(ctools_export_ui_plugin_base_path($this->plugin));
84  }
85  else {
86  return $this->list_page($js, $input);
87  }
88  }
_mailinglist_mailbox_test_output($mailbox)
_mailinglist_mailbox_test_output()

Here is the call graph for this function:


The documentation for this class was generated from the following file: