diff --git a/core/lib/Thelia/Form/CustomerModification.php b/core/lib/Thelia/Form/CustomerModification.php index 61f1e0834..358154a18 100755 --- a/core/lib/Thelia/Form/CustomerModification.php +++ b/core/lib/Thelia/Form/CustomerModification.php @@ -24,6 +24,7 @@ namespace Thelia\Form; use Symfony\Component\Validator\Constraints; +use Thelia\Core\Translation\Translator; /** * Class CustomerModification @@ -56,60 +57,93 @@ class CustomerModification extends BaseForm { $this->formBuilder - ->add('update_logged_in_user', 'boolean') // In a front office context, update the in-memory logged-in user data + ->add('update_logged_in_user', 'integer') // In a front office context, update the in-memory logged-in user data ->add("firstname", "text", array( "constraints" => array( new Constraints\NotBlank() ), - "label" => "firstname" + "label" => Translator::getInstance()->trans("First Name"), + "label_attr" => array( + "for" => "firstname" + ) )) ->add("lastname", "text", array( "constraints" => array( new Constraints\NotBlank() ), - "label" => "lastname" + "label" => Translator::getInstance()->trans("Last Name"), + "label_attr" => array( + "for" => "lastname" + ) )) ->add("address1", "text", array( "constraints" => array( new Constraints\NotBlank() ), - "label" => "address" + "label_attr" => array( + "for" => "address" + ), + "label" => Translator::getInstance()->trans("Street Address") )) ->add("address2", "text", array( - "label" => "Address Line 2" + "label" => Translator::getInstance()->trans("Address Line 2"), + "label_attr" => array( + "for" => "address2" + ) )) ->add("address3", "text", array( - "label" => "Address Line 3" + "label" => Translator::getInstance()->trans("Address Line 3"), + "label_attr" => array( + "for" => "address3" + ) )) ->add("phone", "text", array( - "label" => "phone" + "label" => Translator::getInstance()->trans("Phone"), + "label_attr" => array( + "for" => "phone" + ) )) ->add("cellphone", "text", array( - "label" => "cellphone" + "label" => Translator::getInstance()->trans("Cellphone"), + "label_attr" => array( + "for" => "cellphone" + ) )) ->add("zipcode", "text", array( "constraints" => array( new Constraints\NotBlank() ), - "label" => "zipcode" + "label" => Translator::getInstance()->trans("Zip code"), + "label_attr" => array( + "for" => "zipcode" + ) )) ->add("city", "text", array( "constraints" => array( new Constraints\NotBlank() ), - "label" => "city" + "label" => Translator::getInstance()->trans("City"), + "label_attr" => array( + "for" => "city" + ) )) ->add("country", "text", array( "constraints" => array( new Constraints\NotBlank() ), - "label" => "country" + "label" => Translator::getInstance()->trans("Country"), + "label_attr" => array( + "for" => "country" + ) )) ->add("title", "text", array( "constraints" => array( new Constraints\NotBlank() ), - "label" => "title" + "label" => Translator::getInstance()->trans("Title"), + "label_attr" => array( + "for" => "title" + ) )) ; } diff --git a/templates/admin/default/customer-edit.html b/templates/admin/default/customer-edit.html new file mode 100644 index 000000000..d3f9b6bc5 --- /dev/null +++ b/templates/admin/default/customer-edit.html @@ -0,0 +1,152 @@ +{extends file="admin-layout.tpl"} + +{block name="page-title"}{intl l='Edit a customer'}{/block} + +{block name="check-permissions"}admin.customer.edit{/block} + +{block name="main-content"} +