X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=CRM%2FGrant%2FForm%2FSearch.php;h=ae60d6ea9a2a44520e1341e6416050aa60fc1c74;hb=e341bbeea78a4c1d1847890146685322d15dc207;hp=094f5fac1c1088f265a905b8464325b5383683db;hpb=f8c36033b83eb127a5443595b7aea3c6e68cd855;p=civicrm-core.git diff --git a/CRM/Grant/Form/Search.php b/CRM/Grant/Form/Search.php index 094f5fac1c..ae60d6ea9a 100644 --- a/CRM/Grant/Form/Search.php +++ b/CRM/Grant/Form/Search.php @@ -1,7 +1,7 @@ _searchButtonName = $this->getButtonName('refresh'); - $this->_printButtonName = $this->getButtonName('next', 'print'); $this->_actionButtonName = $this->getButtonName('next', 'action'); $this->_done = FALSE; @@ -237,6 +228,7 @@ class CRM_Grant_Form_Search extends CRM_Core_Form { $rows = $this->get('rows'); if (is_array($rows)) { + CRM_Core_Resources::singleton()->addScriptFile('civicrm', 'js/crm.livePage.js'); if (!$this->_single) { $this->addElement('checkbox', 'toggleSelect', NULL, NULL, array('onchange' => "toggleTaskAction( true ); return toggleCheckboxVals('mark_x_',this);")); foreach ($rows as $row) { @@ -266,13 +258,6 @@ class CRM_Grant_Form_Search extends CRM_Core_Form { ) ); - $this->add('submit', $this->_printButtonName, ts('Print'), - array( - 'class' => 'form-submit', - 'onclick' => "return checkPerformAction('mark_x', '" . $this->getName() . "', 1);", - ) - ); - // need to perform tasks on all or selected items ? using radio_ts(task selection) for it $this->addElement('radio', 'radio_ts', NULL, '', 'ts_sel', array('checked' => 'checked')); $this->addElement('radio', 'radio_ts', NULL, '', 'ts_all', array('onchange' => $this->getName() . ".toggleSelect.checked = false; toggleCheckboxVals('mark_x_',this); toggleTaskAction( true );")); @@ -326,11 +311,11 @@ class CRM_Grant_Form_Search extends CRM_Core_Form { $this->set('queryParams', $this->_queryParams); $buttonName = $this->controller->getButtonName(); - if ($buttonName == $this->_actionButtonName || $buttonName == $this->_printButtonName) { + if ($buttonName == $this->_actionButtonName) { // check actionName and if next, then do not repeat a search, since we are going to the next page // hack, make sure we reset the task values - $stateMachine = &$this->controller->getStateMachine(); + $stateMachine = $this->controller->getStateMachine(); $formName = $stateMachine->getTaskFormName(); $this->controller->resetPage($formName); return;