public function priceRule()
    {
        $options = array(
            'status' => 1,
            'order' => 'desc',
            'sort' => 'created',
            'limit' => array(0, $this->config->get('dashboard_limit', 10)));

        $items = $this->pricerule->getList($options);

        array_walk($items, function (&$item) {
            $item['value_formatted'] = $this->price->format($item['value'], $item['currency']);
        });

        return $items;
    }
public function priceRule()
    {
        $options = array(
            'status' => 1,
            'order' => 'desc',
            'sort' => 'created',
            'limit' => array(0, $this->config->get('dashboard_limit', 10)));

        $items = $this->pricerule->getList($options);

        array_walk($items, function (&$item) {
            $item['value_formatted'] = $this->price->format($item['value'], $item['currency']);
        });

        return $items;
    }
public function priceRule ( ) { $ options = array ( 'status' => 1 , 'order' => 'desc' , 'sort' => 'created' , 'limit' => array ( 0 , $ this -> config -> get ( 'dashboard_limit' , 10 ) ) ) ; $ items = $ this -> pricerule -> getList ( $ options ) ; array_walk ( $ items , function ( & $ item ) { $ item [ 'value_formatted' ] = $ this -> price -> format ( $ item [ 'value' ] , $ item [ 'currency' ] ) ; } ) ; return $ items ; }
Returns an array of active price rules
@return array
Returns an array of active price rules