3 +--------------------------------------------------------------------+
4 | Copyright CiviCRM LLC. All rights reserved. |
6 | This work is published under the GNU AGPLv3 license with some |
7 | permitted exceptions and without any warranty. For full license |
8 | and copyright information, see https://civicrm.org/licensing |
9 +--------------------------------------------------------------------+
15 * @copyright CiviCRM LLC https://civicrm.org/licensing
19 class CRM_Group_Controller
extends CRM_Core_Controller
{
25 * @param bool|int $action
28 public function __construct($title = NULL, $action = CRM_Core_Action
::NONE
, $modal = TRUE) {
29 parent
::__construct($title, $modal);
31 $this->_stateMachine
= new CRM_Group_StateMachine($this, $action);
33 // create and instantiate the pages
34 $this->addPages($this->_stateMachine
, $action);
36 // hack for now, set Search to Basic mode
37 $this->_pages
['Basic']->setAction(CRM_Core_Action
::BASIC
);
39 // add all the actions
40 $config = CRM_Core_Config
::singleton();
42 // to handle file type custom data
43 $uploadDir = $config->uploadDir
;
45 $uploadNames = $this->get('uploadNames');
46 if (!empty($uploadNames)) {
47 $uploadNames = array_merge($uploadNames,
48 CRM_Core_BAO_File
::uploadNames()
52 $uploadNames = CRM_Core_BAO_File
::uploadNames();
55 // add all the actions
56 $this->addActions($uploadDir, $uploadNames);
62 public function run() {
69 public function selectorName() {
70 return $this->get('selectorName');