[*] BO : added a new Validate method "isPercentage"

This commit is contained in:
dMetzger
2012-07-09 13:05:31 +00:00
parent 249d347c01
commit 96d2a19587
4 changed files with 16 additions and 5 deletions
+1 -1
View File
@@ -97,7 +97,7 @@ class CartRuleCore extends ObjectModel
'product_restriction' => array('type' => self::TYPE_BOOL, 'validate' => 'isBool'),
'shop_restriction' => array('type' => self::TYPE_BOOL, 'validate' => 'isBool'),
'free_shipping' => array('type' => self::TYPE_BOOL, 'validate' => 'isBool'),
'reduction_percent' => array('type' => self::TYPE_FLOAT, 'validate' => 'isFloat'),
'reduction_percent' => array('type' => self::TYPE_FLOAT, 'validate' => 'isPercentage'),
'reduction_amount' => array('type' => self::TYPE_FLOAT, 'validate' => 'isFloat'),
'reduction_tax' => array('type' => self::TYPE_BOOL, 'validate' => 'isBool'),
'reduction_currency' => array('type' => self::TYPE_INT, 'validate' => 'isUnsignedId'),