2

we have th strangest problem. In admin/sales_order_create/index the email field is missing. We actually found this in 2 stores.

The form is loaded here

app/code/core/Mage/Adminhtml/Block/Sales/Order/Create/Form/Account.php

// add system required attributes foreach ($customerForm->getSystemAttributes() as $attribute) { /* @var $attribute Mage_Customer_Model_Attribute */ if ($attribute->getIsRequired()) { $attributes[$attribute->getAttributeCode()] = $attribute; } } 

It seems that $attribute->getIsRequired() is not true for $attribute->getAttributeCode()=="email"

I have seen this for the 3rd time now in 3 stores.

Question: Where and how can the required-ness of the "email" attribute be changed? (so we don't see this problem anymore)

enter image description here

2 Answers 2

0

We changed this line to:

 if ($attribute->getIsRequired()||$attribute->getAttributeCode()=="email") { // TEMP MODIFICATION $attributes[$attribute->getAttributeCode()] = $attribute; } 

But I don't know how the required-ness of the "email" attribute changed. If someone has an answer to that I am very interested

0

I have checked and solved. You can make Email field require. Please update below code

protected function addAdditionalFormElementData(Varien_Data_Form_Element_Abstract $element) { switch ($element->getId()) { case 'email': $element->setRequired(1); $element->setClass('validate-email'); break; } return $this; } 

In app/code/core/Mage/Adminhtml/Block/Sales/Order/Create/Form/Account.php.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.