PrestaShop/PrestaShop — pull request #1064 by neemzy (2013-12-01 11:23:58+00:00)
Title: [-] Fix multilingual field bad value retrieval

The original way of finding multilingual fields in objects (`ObjectModel` child classes) only worked for fields defined with a `validate` field. This means that when writing this :

```php
public static $definition = array(
'multilang' => true,

'fields' => array(
'myfield' => array(
'type' => ObjectModel::TYPE_STRING,
'required' => true
),
'mylangfield' => array(
'type' => ObjectModel::TYPE_STRING,
'required' => true,
'lang' => true
)
)
);
```

...`mylangfield` wasn't found, which means no update of the field in the database upon `update` for example. In order to make it work, you had to add a `validate` key to the field's definition array, and if you had no particular validation rule to apply to the field, you just ended up setting `isAnything` as a value. Not really useful.

The way I changed it into directly checks the class's `$definition` static variable to find multilingual fields, regardless of the fact they need to be validated or not, just to trigger the value retrieval, and therefore eliminates the need for said `validate` key.

PS : I didn't specify a "category" in my commit message as this issue is directly core-related (neither front-office-, back-office- nor module- specifically related).

PPS : This is a repost of https://github.com/PrestaShop/PrestaShop/pull/1052 on the `bootstrap` branch, as requested. FMI, am I supposed to direct future PRs to this branch as well ?