X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=CRM%2FContact%2FForm%2FEdit%2FHousehold.php;h=417a8261043e00f43d6d959e838d00432e2bdca0;hb=b44e3f8468ceba3e1b321d31dd2e35a1aa1a5d9a;hp=4ad5751d20e3b456bd34d19398148e6573f464d4;hpb=5667521530926d61b370a4bb0806b7e5ad63ccbc;p=civicrm-core.git diff --git a/CRM/Contact/Form/Edit/Household.php b/CRM/Contact/Form/Edit/Household.php index 4ad5751d20..417a826104 100644 --- a/CRM/Contact/Form/Edit/Household.php +++ b/CRM/Contact/Form/Edit/Household.php @@ -3,7 +3,7 @@ +--------------------------------------------------------------------+ | CiviCRM version 4.6 | +--------------------------------------------------------------------+ - | Copyright CiviCRM LLC (c) 2004-2014 | + | Copyright CiviCRM LLC (c) 2004-2015 | +--------------------------------------------------------------------+ | This file is a part of CiviCRM. | | | @@ -23,29 +23,31 @@ | GNU Affero General Public License or the licensing of CiviCRM, | | see the CiviCRM license FAQ at http://civicrm.org/licensing | +--------------------------------------------------------------------+ -*/ + */ /** * * @package CRM - * @copyright CiviCRM LLC (c) 2004-2014 + * @copyright CiviCRM LLC (c) 2004-2015 * $Id$ * */ /** - * Auxilary class to provide support to the Contact Form class. Does this by implementing + * Auxiliary class to provide support to the Contact Form class. Does this by implementing * a small set of static methods * */ class CRM_Contact_Form_Edit_Household { /** - * This function provides the HTML form elements that are specific + * This function provides the HTML form elements that are specific. * to the Household Contact Type * - * @param CRM_Core_Form $form form object - * @param int $inlineEditMode ( 1 for contact summary + * @param CRM_Core_Form $form + * Form object. + * @param int $inlineEditMode + * ( 1 for contact summary. * top bar form and 2 for display name edit ) * * @return void @@ -55,18 +57,18 @@ class CRM_Contact_Form_Edit_Household { $form->applyFilter('__ALL__', 'trim'); - if ( !$inlineEditMode || $inlineEditMode == 1 ) { + if (!$inlineEditMode || $inlineEditMode == 1) { // household_name $form->add('text', 'household_name', ts('Household Name'), $attributes['household_name']); } - if ( !$inlineEditMode || $inlineEditMode == 2 ) { + if (!$inlineEditMode || $inlineEditMode == 2) { // nick_name $form->addElement('text', 'nick_name', ts('Nickname'), $attributes['nick_name']); $form->addElement('text', 'contact_source', ts('Source'), CRM_Utils_Array::value('source', $attributes)); } - if ( !$inlineEditMode ) { + if (!$inlineEditMode) { $form->add('text', 'external_identifier', ts('External ID'), $attributes['external_identifier'], FALSE); $form->addRule('external_identifier', ts('External ID already exists in Database.'), @@ -77,13 +79,16 @@ class CRM_Contact_Form_Edit_Household { } /** - * Add rule for household + * Add rule for household. * - * @param array $fields array of form values - * @param array $files - unused + * @param array $fields + * Array of form values. + * @param array $files + * Unused. * @param int $contactID * - * @return array|bool $error@static + * @return array|bool + * $error */ public static function formRule($fields, $files, $contactID = NULL) { $errors = array(); @@ -99,4 +104,5 @@ class CRM_Contact_Form_Edit_Household { return empty($errors) ? TRUE : $errors; } + }