Merge pull request #4983 from colemanw/CRM-15842
[civicrm-core.git] / CRM / Custom / Form / Group.php
index 61b90ecd109750a81340d1a96687850356ce619c..8f88a64ac70541e70fd09060704726290517bb3e 100644 (file)
@@ -23,7 +23,7 @@
  | GNU Affero General Public License or the licensing of CiviCRM,     |
  | see the CiviCRM license FAQ at http://civicrm.org/licensing        |
  +--------------------------------------------------------------------+
-*/
+ */
 
 /**
  *
@@ -387,7 +387,7 @@ class CRM_Custom_Form_Group extends CRM_Core_Form {
       ),
     );
     if (!$this->_isGroupEmpty && !empty($this->_subtypes)) {
-      $buttons[0]['js'] = array('onclick' => "return warnDataLoss()");
+      $buttons[0]['class'] = 'crm-warnDataLoss';
     }
     $this->addButtons($buttons);
 
@@ -552,4 +552,5 @@ class CRM_Custom_Form_Group extends CRM_Core_Form {
     }
     return $relName;
   }
+
 }