// Format definitions

This commit is contained in:
rMalie
2011-12-13 16:34:09 +00:00
parent c3840ac6e2
commit d1c9c439fd
10 changed files with 77 additions and 270 deletions
+2 -14
View File
@@ -33,10 +33,6 @@ class TaxRulesGroupCore extends ObjectModel
/** @var bool active state */
public $active;
/**
* @see ObjectModel::$definition
*/
@@ -44,21 +40,13 @@ class TaxRulesGroupCore extends ObjectModel
'table' => 'tax_rules_group',
'primary' => 'id_tax_rules_group',
'fields' => array(
'name' => array('type' => 'FILL_ME', 'validate' => 'isGenericName', 'required' => true, 'size' => 64),
'name' => array('type' => self::TYPE_STRING, 'validate' => 'isGenericName', 'required' => true, 'size' => 64),
'active' => array('type' => self::TYPE_BOOL),
),
);
protected static $_taxes = array();
public function getFields()
{
$this->validateFields();
$fields['name'] = ($this->name);
$fields['active'] = (int)$this->active;
return $fields;
}
public static function getTaxRulesGroups($only_active = true)
{
return Db::getInstance()->executeS('