public static function deleteAllByAttributes($attributes, $condition = null, $params = array())
    {
        if (!is_a($condition, '\\mpf\\datasources\\sql\\ModelCondition')) {
            $condition = ModelCondition::getFrom($condition, get_called_class());
        }
        /* @var $condition ModelCondition */
        foreach ($attributes as $k => $v) {
            $condition->compareColumn($k, $v);
        }
        return static::deleteAll($condition, $params);
    }
public static function deleteAllByAttributes($attributes, $condition = null, $params = array())
    {
        if (!is_a($condition, '\\mpf\\datasources\\sql\\ModelCondition')) {
            $condition = ModelCondition::getFrom($condition, get_called_class());
        }
        /* @var $condition ModelCondition */
        foreach ($attributes as $k => $v) {
            $condition->compareColumn($k, $v);
        }
        return static::deleteAll($condition, $params);
    }
public static function deleteAllByAttributes ( $ attributes , $ condition = null , $ params = array ( ) ) { if ( ! is_a ( $ condition , '\\mpf\\datasources\\sql\\ModelCondition' ) ) { $ condition = ModelCondition :: getFrom ( $ condition , get_called_class ( ) ) ; } /* @var $condition ModelCondition */ foreach ( $ attributes as $ k => $ v ) { $ condition -> compareColumn ( $ k , $ v ) ; } return static :: deleteAll ( $ condition , $ params ) ; }
Delete all by attributes
@param array $attributes
@param null|string|ModelCondition $condition
@param array $params
@return int
Delete all by attributes