Merge branch 4.5 into master
[civicrm-core.git] / CRM / Custom / Form / MoveField.php
index 1a94fd5ba559004b2eb0ad9386f29e32e9724bb8..ce103511884e05d8cbc57d0ec75ad3810bec8586 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        |
  +--------------------------------------------------------------------+
-*/
+ */
 
 /**
  *
@@ -95,8 +95,8 @@ class CRM_Custom_Form_MoveField extends CRM_Core_Form {
     );
 
     CRM_Utils_System::setTitle(ts('Custom Field Move: %1',
-        array(1 => $this->_srcFieldLabel)
-      ));
+      array(1 => $this->_srcFieldLabel)
+    ));
 
     $session = CRM_Core_Session::singleton();
     $session->pushUserContext(CRM_Utils_System::url('civicrm/admin/custom/group/field', "reset=1&action=browse&gid={$this->_srcGID}"));
@@ -116,7 +116,8 @@ class CRM_Custom_Form_MoveField extends CRM_Core_Form {
     }
 
     $customGroup = array(
-      '' => ts('- select -')) + $customGroup;
+      '' => ts('- select -'),
+    ) + $customGroup;
     $this->add('select',
       'dst_group_id',
       ts('Destination'),
@@ -149,8 +150,8 @@ class CRM_Custom_Form_MoveField extends CRM_Core_Form {
    */
   public static function formRule($fields, $files, $self) {
     $self->_dstGID = $fields['dst_group_id'];
-    $tmp           = CRM_Core_BAO_CustomField::_moveFieldValidate($self->_srcFID, $self->_dstGID);
-    $errors        = array();
+    $tmp = CRM_Core_BAO_CustomField::_moveFieldValidate($self->_srcFID, $self->_dstGID);
+    $errors = array();
     if ($tmp['newGroupID']) {
       $errors['dst_group_id'] = $tmp['newGroupID'];
     }
@@ -172,9 +173,10 @@ class CRM_Custom_Form_MoveField extends CRM_Core_Form {
     $srcUrl = CRM_Utils_System::url('civicrm/admin/custom/group/field', "reset=1&action=browse&gid={$this->_dstGID}");
     CRM_Core_Session::setStatus(ts("%1 has been moved to the custom set <a href='%3'>%2</a>.",
       array(
-      1 => $this->_srcFieldLabel,
-          2 => $dstGroup,
-        3 => $srcUrl
-        )), '', 'success');
+        1 => $this->_srcFieldLabel,
+        2 => $dstGroup,
+        3 => $srcUrl,
+      )), '', 'success');
   }
+
 }