Skip to content

BasePrice Criterion

The BasePrice Search Criterion searches for products by their base price.

Arguments

  • value - a Money\Money object representing the price in a specific currency
  • (optional) operator - Operator constant (EQ, GT, GTE, LT, LTE, default EQ)

Limitations

The BasePrice Criterion isn't available in the Legacy Search engine.

Example

PHP

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
use Ibexa\Contracts\ProductCatalog\Values\Product\ProductQuery;
use Ibexa\Contracts\ProductCatalog\Values\Product\Query\Criterion;

$query = new ProductQuery(
    null,
    new \Ibexa\Contracts\ProductCatalog\Values\Product\Query\Criterion\BasePrice(
        \Money\Money::EUR(12900),
        \Ibexa\Contracts\ProductCatalog\Values\Product\Query\Criterion\Operator::GTE
    )
);