[*] Classes: Remove $fieldsRequired, $fieldsSize and $fieldsValidate (and lang properties) properties, use $definition instead
git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@11155 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
+15
-5
@@ -36,18 +36,28 @@ class AttributeCore extends ObjectModel
|
||||
public $position;
|
||||
public $default;
|
||||
|
||||
protected $fieldsRequired = array('id_attribute_group');
|
||||
protected $fieldsValidate = array('id_attribute_group' => 'isUnsignedId', 'color' => 'isColor', 'position' => 'isInt');
|
||||
protected $fieldsRequiredLang = array('name');
|
||||
protected $fieldsSizeLang = array('name' => 64);
|
||||
protected $fieldsValidateLang = array('name' => 'isGenericName');
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* @see ObjectModel::$definition
|
||||
*/
|
||||
public static $definition = array(
|
||||
'table' => 'attribute',
|
||||
'primary' => 'id_attribute',
|
||||
'multilang' => true,
|
||||
'fields' => array(
|
||||
'id_attribute_group' => array('type' => 'FILL_ME', 'validate' => 'isUnsignedId', 'required' => true),
|
||||
'color' => array('type' => 'FILL_ME', 'validate' => 'isColor'),
|
||||
'position' => array('type' => 'FILL_ME', 'validate' => 'isInt'),
|
||||
'name' => array('type' => 'FILL_ME', 'lang' => true, 'validate' => 'isGenericName', 'required' => true, 'size' => 64),
|
||||
),
|
||||
);
|
||||
|
||||
|
||||
protected $image_dir = _PS_COL_IMG_DIR_;
|
||||
|
||||
protected $webserviceParameters = array(
|
||||
|
||||
Reference in New Issue
Block a user