CRM-12872 - Add livePage js to search forms
authorColeman Watts <coleman@civicrm.org>
Wed, 8 Jan 2014 23:27:06 +0000 (15:27 -0800)
committerColeman Watts <coleman@civicrm.org>
Wed, 8 Jan 2014 23:27:06 +0000 (15:27 -0800)
CRM/Activity/Form/Search.php
CRM/Campaign/Form/Search.php
CRM/Case/Form/Search.php
CRM/Contact/Form/Search.php
CRM/Event/Form/Search.php
CRM/Grant/Form/Search.php
CRM/Member/Form/Search.php
CRM/Pledge/Form/Search.php

index 2c3cd9946dd789e1dbeac889816809d48ebb1265..fbc77f0ece2640c919dde6019a973dfe0ebee96e 100644 (file)
@@ -243,6 +243,7 @@ class CRM_Activity_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('onclick' => "toggleTaskAction( true ); return toggleCheckboxVals('mark_x_',this);")
index ff7089ff47e64a36aa06392c64d5c8551a087f04..9ffa03d362df0fdfaeded92b99da93cda301da21 100755 (executable)
@@ -268,6 +268,7 @@ class CRM_Campaign_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('onclick' => "toggleTaskAction( true ); return toggleCheckboxVals('mark_x_',this);"));
         foreach ($rows as $row) {
index 7e786fa4d9a34d8d15a8a48bca68556f938e8f5a..5d96464c410a6be4cd4ff8d6e86dbf2b63856203 100644 (file)
@@ -253,7 +253,7 @@ class CRM_Case_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',
index adb3c512ef2a038e6c5f32afeacdcebe24db6d9b..43d2de41a473e39c412ee439d468fa7a54223ac6 100644 (file)
@@ -379,6 +379,7 @@ class CRM_Contact_Form_Search extends CRM_Core_Form {
    * @return void
    */
   function buildQuickForm() {
+    CRM_Core_Resources::singleton()->addScriptFile('civicrm', 'js/crm.livePage.js');
     $permission = CRM_Core_Permission::getPermission();
     // some tasks.. what do we want to do with the selected contacts ?
     $tasks = array('' => ts('- actions -'));
@@ -524,9 +525,9 @@ class CRM_Contact_Form_Search extends CRM_Core_Form {
     $this->assign('ts_all_id', $allRowsRadio->_attributes['id']);
 
     /*
-         * add form checkboxes for each row. This is needed out here to conform to QF protocol
-         * of all elements being declared in builQuickForm
-         */
+     * add form checkboxes for each row. This is needed out here to conform to QF protocol
+     * of all elements being declared in builQuickForm
+     */
 
     $rows = $this->get('rows');
 
index c3bb5899711fb2e6f7534e4d1355e859682b83e4..75c41f9dbba764a2c0468bf924feb98cbb89f62e 100644 (file)
@@ -243,6 +243,7 @@ class CRM_Event_Form_Search extends CRM_Core_Form {
      */
     $rows = $this->get('rows');
     if (is_array($rows)) {
+      CRM_Core_Resources::singleton()->addScriptFile('civicrm', 'js/crm.livePage.js');
       $lineItems = $eventIds = array();
       if (!$this->_single) {
         $this->addElement('checkbox',
index 95f0cd8deaa19f1d49606e079da99ada4c4fddfa..6e207fea2bccb9ce5ccd3321ad34edd59aff5c16 100644 (file)
@@ -237,6 +237,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) {
index 747ad25d0aafe43acaf0689dd581e0e23856e3fa..e0bfebc3f521e780a7824ce3e5fa82fca8c6995a 100644 (file)
@@ -233,6 +233,7 @@ class CRM_Member_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('onclick' => "toggleTaskAction( true ); return toggleCheckboxVals('mark_x_',this);"));
         foreach ($rows as $row) {
index d07a3a5f94e2688831bd985443f60636c2d9a49b..d81bf2f98ce039023aadf9887c8589dfed46df93 100644 (file)
@@ -231,7 +231,7 @@ class CRM_Pledge_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('onclick' => "toggleTaskAction( true ); return toggleCheckboxVals('mark_x_',this);"));