Prior Price Omnibus: Lowest Price in 30 Days. In the European Union every announcement of a price reduction must also show the prior price: the lowest price applied in the 30 days before the reduction. To show it you need the history of your prices, and the history must be complete.

📄 Download the guide as a PDF

This module records every change of the price of your products and combinations, shop by shop, as a visitor of the shop sees it, and shows the lowest price of the days before the reduction on the product page and, if you wish, in quick view and in product lists. It can also remove the crossed out price where a reduction is not real, or use the prior price as the crossed out price and as the base of the percentage. The price the customer pays never changes. From version 1.1.0 it can also draw, under the line, a chart of the prices recorded for the product: it is off by default.

A history is only as good as its collection. The module collects the changes in several ways at the same time (saves in the back office, timed discounts, fingerprints of the price data, a rotating check of the whole catalog, a cron job, a traffic based pseudo-cron and ways in for external software), writes every run in a log in the database and warns you in the back office as soon as the collection stops. This guide describes version 1.1.0.

This guide is not legal advice. The module calculates and shows the prior price from the history it recorded. Which rules apply to your shop, the texts you show and the reductions you announce remain your responsibility: check the rules of your country, ideally with your legal advisor.

1. Installation

  1. In the back office go to Modules → Module Manager → Upload a module and select the module ZIP.
  2. Once installed, click Configure and then Go to the module page. The page is also in the menu Modules → Omnibus price history.

During the installation the module creates its tables, saves the default settings and the texts of the product page in English, Italian, French, Spanish, German, Polish and Dutch (the other languages of the shop receive the English texts, which you can change), and takes a first snapshot of the prices: the first products straight away, within 10 seconds, the others in the next runs. Until the snapshot is complete, the Status tab shows how many items are already recorded. From then on every change is recorded.

On a multistore installation, install the module from the back office in the context of all shops, or enable it afterwards in each shop: an installation from the command line enables it only in the default shop (this is how PrestaShop works). The line is shown only in the shops where the module is enabled.

Updates are automatic. Updates are included. Development domains (.local, .test, localhost) are always allowed. When a new version is available it is shown right inside the module.
Server requirement. PHP 7.1 or later. On an older PHP the module does not install and says why.

2. What the rule asks

Article 6a of Directive 98/6/EC, added by Directive (EU) 2019/2161 and applied since 28 May 2022, asks that every announcement of a price reduction shows the prior price: the lowest price the trader applied during a period of not less than 30 days before the reduction. In Italy the rule is article 17-bis of the Consumer Code. In short:

  • The 30 days come before the reduction. The period is anchored to the start of the reduction, not to today. According to the Commission guidelines (2021/C 526/02, point 2.1), a reduction that lasts more than 30 days keeps as prior price the lowest price of the 30 days before its start. The module calculates it this way.
  • Every price applied in the period counts, including earlier reductions and prices that lasted a short time. This is why the module records every change with its date and time, and not one price per day.
  • New products and progressive reductions. The directive lets each country set its own rule for products on sale for less than 30 days and for reductions that grow step by step without interruption (in that case the prior price can stay the one before the first step).
  • Judgment C-330/23 of the Court of Justice (Aldi Süd, 26 September 2024): a reduction announced as a percentage, or with a statement that stresses how convenient the price is, must be calculated on the prior price, and a price presented as reduced cannot be equal to the prior price or higher. The judgment does not deal with the crossed out price; the Commission guidelines treat a crossed out price (“now 50 instead of 100”) as an announcement of a reduction.

Some national points, limited to those found in the law or in the guidance of the authority:

CountryLawNew productsProgressive reductionsDisplay
Italyart. 17-bis Consumer Codestate the period the prior price refers toprice before the first reduction, same campaign without interruptionin extraordinary sales the lowest price of the 30 days is shown as the crossed out price
Franceart. L.112-1-1 Code de la consommationno written ruleprice before the first reductionfree form: amount, percentage or crossed out price
Germany§ 11 PAngVno written ruleprice before the start of the reduction, while it grows without interruption
Netherlandsart. 5a Besluit prijsaanduiding producten (ACM guidelines)a reasonable period, chosen by the seller and statedthe same prior price for 3 months at most; an interruption starts a new campaignfixed text next to the price, not behind an “i” icon
IrelandS.I. 597/2022 (CCPC guidance)prior price fixed at the lowest before the first reductionkeep a recommended retail price apart from the prior price

For Spain, Poland, Belgium and Austria some points could not be verified with enough certainty to be listed here. The Country profile of the module (section 3.2) has suggested values for these countries too: check them.

What the module cannot know. It records the price of the product as a visitor sees it. Vouchers and cart rules, promotional statements written in your theme, banners or descriptions, and discounts “for members only” that are in fact open to anyone are outside what it can see: if you use them, check what your rules ask.

3. Configuration · step by step

The module page has five tabs: Status, Display, Appearance, Collection and Tools. On a multistore installation the settings follow the shop selected at the top of the back office: in the context of all shops or of a group, a note reminds you that the settings you save apply to all the shops of that context.

3.1 Status

The first tab tells you whether the collection works. At the top a green message (The collection is working: no warnings.) or a red one (The collection needs attention) with the list of the problems.

Status tab of the module
The Status tab: state of the collection, shops, last run of each way in
  • Status of the collection: the expected frequency, the pseudo-cron and its next run, the products waiting in the queue, the next start or end of a timed discount, the rows in the price history and the oldest one, whether a run is in progress and whether a complete check of the catalog has been requested.
  • Shops: for each shop the active products and combinations, how many are recorded, how many were checked in the last 24 hours, the end of the last complete check, the state of the initial snapshot (Complete, or how many items are recorded so far), the last pass of the fingerprints and how many products it found changed (section 4.4).
  • Last run by source: one row for each way in (command line, cron URL, pseudo-cron, saves, HTTP endpoint, public hook, static method, back office, installation) with start, result, items checked, changes, errors and a short summary.
  • Run now starts a run of up to 20 seconds; Start a complete check of the catalog restarts the rotating check from the first product (section 4.4).

The red warnings are:

  • no run recorded yet, or the last run started more than twice the expected frequency ago;
  • the pseudo-cron is off and no cron job ran recently: nothing starts the collection;
  • the last run had errors (with the first error);
  • in a shop the complete check of the catalog has not closed for more than 24 hours;
  • in a shop the initial snapshot is not complete yet.

Two blue notes may appear too: when in the last 24 hours the longest interval between two runs was more than an hour (a timed discount that starts and ends in between cannot be recorded), and when some items were not observed for a while (section 4.7).

Status tab with a warning
The same tab when the collection has stopped

When the collection has stopped, the dashboard of the back office shows a red message too, with the time of the last run and a link to the Status tab:

Warning on the dashboard
The warning on the dashboard

3.2 Display

What the shop shows, and how the prior price is calculated.

Display tab, country profile and display settings
Country profile and display settings

Country profile. Choose a country in Apply the suggested values for (Italy, France, Spain, Germany, Austria, Poland, Netherlands, Belgium, Ireland) and click Fill the form: the window, the new products, the progressive reductions with their longest duration and the default texts of each language are filled in. Nothing is saved until you click Save. The suggested values are a window of 30 days everywhere, progressive reductions on everywhere except Spain, a longest progressive reduction of 90 days for the Netherlands and no limit elsewhere, new products on everywhere. They are indicative values, not legal advice.

  • Mode: three ways to follow judgment C-330/23. The price the customer pays never changes, in any mode: the module only changes what is shown as crossed out price and percentage.
    • Information: a line under the price (the default): the line with the prior price under the price; the crossed out price and the percentage of the theme do not change.
    • Strict: a line, and no crossed out price where the reduction is not real: the line as above; where the current price is not lower than the prior price, the crossed out price and the percentage of the theme disappear, because that reduction cannot be announced.
    • Prior price as crossed out price: the prior price becomes the crossed out price and the base of the percentage, and a reduction that is not real loses them. The line shows only with a partial history or a new product, because the period must be stated.
    Products whose reduction began before the collection started or while it was stopped keep the crossed out price of the theme. On PrestaShop 1.7.1 to 1.7.4 the quick view and the change of combination keep the price of the theme, and so do product lists that are not built by the search or by category pages (for example featured products before 1.7.8).
  • When: Only on products with a price reduction (the default), or Always: also without a reduction the line shows the lowest price of the last days, today included, with its own text.
  • Reduction not real: a reduction is not real when the current price is not lower than the prior price. Show the line anyway (the default) or Do not show the line. These products are listed in the Tools tab.
  • History shorter than the window: when the history does not cover the whole window yet (for example in the first 30 days after the installation), Show the lowest price since the start of the history (the default, with the text “since {date}”) or Do not show the line.
  • No history before the reduction: for products whose reduction began before the collection started or while it was stopped, the start of the reduction is not known. Do not show the line (the default) or Show the lowest price since the start of the history. The rebuild from discounts with dates, in the Tools tab, can complete the history only for a discount with dates that began before the module first observed the product.
  • Position on the product page: Under the price (the default) or Next to the crossed out price. For a custom theme the module offers a widget and a hook (section 6).
  • Quick view (on by default) and Product lists (off by default): the line also in the quick view window and in the product thumbnails of themes that print the unit price block, such as classic and Hummingbird.
  • Excluded categories: category ids separated by commas, for example an outlet category or perishable goods. Products whose default category is one of them show no line and keep the crossed out price of the theme; their history is recorded anyway.
Computation and texts
Computation and texts of the line, one row per language
  • Window (days): at least 30 days (up to 365). The window is counted in calendar days in the time zone of the shop: it starts at midnight of the day that comes that many days before the start of the reduction, and ends when the reduction starts.
  • Progressive reductions: Keep the prior price of the first reduction while the reduction only grows (the default) or Every change of the reduced price starts a new window. Example: a product at 100 is reduced to 90, and ten days later to 80. With the option on, the prior price stays 100, the price before the first step, as long as the reduction keeps growing without interruption. With the option off, the step to 80 starts a new window and the prior price becomes the lowest price of the days before it, 90. The directive lets each country decide; the country profile sets this option (it is off for Spain). The module sees prices, not campaigns: for two campaigns in a row see section 8.
  • Longest progressive reduction (days): 0 means no limit. Beyond it the general rule applies again (in the Netherlands the same prior price can be kept for 3 months at most).
  • New products: On sale for less than the window: lowest price since they were added (the default) or Treat them as a partial history.
  • Texts: for each language, the text With a reduction, the text for a Partial history or new product and the text Without a reduction (always). Placeholders: {price} the prior price, {date} the date (in the date format of the language), {days} the days of the window, {percent} the reduction calculated on the prior price. Every text must contain {price}; an empty text uses the default text of the language.

The default English texts are: Lowest price in the last {days} days: {price} (with a reduction), Lowest price since {date}: {price} (partial history or new product) and Lowest price in the last {days} days: {price} (without a reduction). The country profiles of Poland and the Netherlands fill in a text that says “before the discount”: Lowest price in the {days} days before the discount: {price}.

3.3 Appearance

The Appearance tab sets how the line looks and whether the price chart is shown, without touching the theme.

Gallery of the models and live preview
The gallery of the models, drawn with the template of the shop, and the live preview with the contrast check
  • Model on the product page and Model in product lists: 23 models, each drawn in the gallery with the template of the shop and a sample text. Plain text (the default on the product page, with the font of the theme), Muted, Inline, Pill, Badge, Split badge, Outline, Coupon, Soft box, Callout, Info bar, Price tag, Two lines, Underlined price, Highlighter, Ribbon, Compact (the default in product lists), Card, High contrast, Dark, Theme accent, Between two rules, Price list. A click on a model in the gallery chooses it.
  • Customise: Text colour, Background colour, Border colour and Accent colour (empty fields keep the value of the model), Text size, percent of the theme, Weight, Price in bold, Alignment, Corner radius in pixels, Space above in pixels, Icon (none, information, calendar, price tag, clock, chart, shield: the icon is decorative and the text always stays visible next to the price) and Extra CSS class. Under a setting that the chosen models do not use, a note says that it has no effect for now. Your colours apply to the model of the product page; product lists keep the colours of their model unless you tick Same colours in product lists.
  • Live preview: the price block of a product page and a product thumbnail, at desktop width and at 390 pixels, updated while you change the values, with the lowest contrast of the line: a green message above 4.5:1, the AA minimum for text, a warning below it. Back to the values of the model clears your changes; Save applies them.
Customisation of the line
Customisation of a model: colours, size, icon and preview
Dark themes. The contrast check measures on white and on light grey, not on the background of your theme. On a dark theme choose a model that takes the text colour from the theme (Plain text, Inline, Pill, Outline, Coupon, Soft box, Callout, Price tag, Two lines, Underlined price, Between two rules, Price list) or set the text and background colours yourself: Muted, Compact, Info bar, Card, Theme accent, High contrast and Highlighter have colours made for light backgrounds.

Price chart. Below the models, the sub-section Price chart (new in version 1.1.0) decides whether the product page also shows a chart of the recorded prices (what the customers see is in section 6). The chart is off by default: a shop that updates from an earlier version finds it off, and its product pages stay as they were until you turn it on.

The Price chart sub-section of the Appearance tab
The Price chart sub-section: switch, periods, position and colours
  • Show the price chart on the product page: turns the chart on for the shop (off by default).
  • Periods offered: 30 days, 90 days and 1 year. The customer chooses among the ones you tick, above the chart; with a single period there is nothing to choose.
  • Period shown first: the period drawn when the page opens (90 days by default). When it is not among the periods offered, the first period offered is shown.
  • Position: Under the price, after the Omnibus line (the default), Under the add to cart button or Only where the theme places it (widget). With the last one nothing appears until you add one of the two lines shown under the field to the product template of the theme (section 6, Custom themes). If your theme does not redraw the block under the add to cart button when the customer changes the combination, choose the first position.
  • Also draw the regular price: adds to the chart a second line with the regular price, the one without reductions, next to the price paid (off by default).
  • Colour of the price line, Colour of the regular price and Colour of the lowest price: an empty field (Automatic) follows the text colour of the theme, with a blue for the price line, the text colour for the regular price and an orange for the lowest price and its window. Fill in a field only if you want another colour, and look at it on the background of your theme.

A value that is not valid (for example no period ticked, or a colour that is not a valid hexadecimal code such as #2484b5) is replaced by the default one when you save, and the page tells you which.

3.4 Collection

How and how often the prices are collected, and the ways in for cron jobs and external software.

Collection tab
Reference visitor and collection settings
  • Reference visitor: the Customer group (by default the Visitor group of PrestaShop) and the Country (by default the default country of the shop). Prices are recorded as this visitor sees them, in the default currency of the shop, for one unit, with and without tax. Visitors whose price differs (another group with its own prices, a price set for their currency) do not see the line. Choose them at the start: changing them later rewrites the base of the history (section 8).
  • Expected frequency of the runs: every 5, 15 (the default), 30 or 60 minutes, or once a day. A warning appears when no run happened for twice this time.
  • Pseudo-cron on the shop traffic: on by default (section 4.5).
  • Time of a run started by the cron URL (25 seconds by default, never more than the PHP time limit of the server minus 5 seconds) and by the pseudo-cron (3 seconds by default).
  • Keep the history for (days): 400 by default, at least 90. For each item the last price before the limit is kept, so the module always knows what an item cost at the limit; an item with a running reduction keeps its whole history as long as the reduction lasts.
  • Gap of observation after (hours): 25 by default, and in any case at least twice the expected frequency; 0 = off (section 4.7).
  • Endpoint: items per call (500) and Endpoint: calls per hour (120): limits of the HTTP endpoint (section 5.5).
  • Delete all data on uninstall: No, keep the price history by default.
Cron job and external software
The ready lines for the cron job and the external software (token hidden in this picture)

The panel Cron job and external software shows, ready to copy, the line for the crontab with the path of your shop, the cron URL with its token, a curl example for the endpoint and two lines for modules and scripts. They are explained in section 5. Create a new token replaces the token: the cron URL and the endpoint share it, so after a new token update the cron service and the external software.

3.5 Tools

Tools tab
Complete check, rebuild from dated discounts with its preview, CSV export
  • Complete check of the catalog: the same buttons of the Status tab.
  • Rebuild from discounts with dates: for the products reduced today by a discount whose start date comes before the first observation of the product (typically the discounts already running when you installed the module), the module can add two rows with the prices of that first observation: the regular price from the start of the window before the discount (section 3.2), and the reduced price from the start of the discount. This assumes that the regular price did not change in that period. Items that were not reduced at their first observation are skipped: their reduction started inside the history, which already records it. Click Preview to see how many items and rows would be added, with some examples, then Apply. Each item is rebuilt once.
  • CSV export of the price history: the whole history, or the rows between two dates (From, To), in UTF-8 with a semicolon as separator. Columns: shop, product ID, combination ID, reference, name, from, price tax incl., price tax excl., regular price tax incl., regular price tax excl., source (install, hook, boundary, scan, external, rebuild, admin) and “not observed since”. A name or a reference that begins with =, +, - or @ is written with an apostrophe in front, so that a spreadsheet shows it as text and does not run it as a formula. It is your record of the prices you applied, for example for a check by an authority.
Reductions that are not real
Reductions that are not real: the reason for each item

Reductions that are not real lists the products and combinations reduced today whose price is not lower than the prior price, and those whose reduction began before the collection started or while it was stopped: following judgment C-330/23 they should not be presented as a reduction. The column Why gives the reason. The list is calculated only when you open the tab, 500 items at a time, and CSV of the whole list exports all of them.

3.6 The price history in the product page

In the product page of the back office, tab Modules, the module shows the price history of the product (when several modules are listed there, click Configure on the card of the module, or choose it in the list). On PrestaShop 9 with multistore, the product page needs a shop selected at the top.

Price history in the product page
The price history of a product: the prior price shown on the shop, the chart and the last rows
  • For the product, or for each combination: the prior price shown on the shop with the start of the reduction, or the lowest price since a date, a red note when the start of the reduction is not known (with a link to the Tools tab), or “no line on the shop” when there is no reduction.
  • Under it, the chart of that product or combination: the same drawing the customers see (section 6), with the periods you offer in the Appearance tab (section 3.3), the window and the lowest price of the line, and the prices as a table under Show prices as a table. It is drawn for the reference visitor of the Collection tab (default currency of the shop and tax of the reference group) and it is always there, whatever the setting that shows the chart on the shop: it does not depend on it. Unlike on the shop, it is also drawn when the price never changed, as a flat line. The first five items are shown open; the others are collapsed under Other combinations, with their number.
  • The last 20 rows of the history: from, price tax incl., price tax excl., regular price tax incl., and a note when an item was not observed for a while.
  • Check now recomputes the product at once; CSV of this product exports its whole history.

4. How the prices are collected

4.1 What is recorded

For every active product and combination of every shop the module records four values: the final price and the regular price (without reductions), each with and without tax, as the reference visitor sees them, in the default currency, for one unit. A new row is written only when one of them changes (compared to the precision of the currency), with the date and the time of the change. Recording twice the same price writes nothing.

4.2 Saves

When a product, a combination, a specific price, a catalog price rule, a tax, a tax rules group, the reference group or the default currency is saved, the module puts the products concerned in a queue. This covers the back office, the PrestaShop web service and the CSV import of the back office, which all save through PrestaShop. At the end of the same request (never on the pages of the shop) up to 50 products of the queue are recorded, with the time of the save; the rest goes to the next run. A specific price for one cart or one customer is ignored, because it does not change the price of the reference visitor; a specific price for all products or a change of a tax asks for a complete check of the catalog. When a catalog price rule is deleted, the fingerprints of the products are compared again at the end of the same request and the changes are recorded with the time of the deletion (on a large catalog the next run completes the comparison).

4.3 Timed discounts

Every run looks for the specific prices whose start or end fell since the previous run, and records the change with the time of the start or of the end, not with the time of the run. The next start or end is also the next appointment of the pseudo-cron: the first visit after a promotion starts triggers the run. A promotion that starts and ends completely between two runs cannot be recorded, because PrestaShop calculates prices only for the present moment: if the interval between your runs is long, the Status tab tells you. Dates before the year 2000 or from 2100 on, which some imports use for “always”, are not treated as a start or an end.

4.4 Prices written directly in the database

Some imports and external programs write the prices directly in the database, without telling PrestaShop. To find these changes, every complete run compares a fingerprint of the price data of each active product (price, taxes, combinations, specific prices active now, priorities) with the one of the previous run, and recomputes only the products whose fingerprint changed: a price written directly in the database is recorded at the next run. A fingerprint of the whole shop (tax rules of the reference country, reductions of the reference group and of the categories, specific prices for all products, rate of the default currency, price settings) asks for a complete check when it changes. With a short run, as the one of the pseudo-cron, a large catalog may need a few runs to compare all fingerprints: each run continues where the previous one stopped.

As a safety net, the rotating check also reads again the active products of each shop, 100 at a time, from where the previous run stopped, and records what changed. When the end of the catalog is reached, the complete check of the shop is closed (Last complete check in the Status tab) and the next run starts again from the first product. A run from the command line goes through the whole cycle (unless you give it --budget); a run from the cron URL works 25 seconds; a pseudo-cron run 3 seconds.

A complete check restarts the cycle from the first product and continues in the next runs until the end: button in the Status and Tools tabs, --full on the command line, &full=1 on the cron URL, all=1 on the endpoint, empty lists for the hook and the static method. A request made while a complete check is already in progress continues it from where it has arrived: the products already checked are seen again by the next cycle. The back office and cron.php --full say so when it happens.

The order of a run is: the queue, the timed discounts, the fingerprints, the rotating check, and once a day the clean-up (rows older than the retention period except the last one before the limit and the history of the items reduced today, items of deleted products and combinations, runs of the log beyond the last 500).

4.5 Pseudo-cron

The pseudo-cron is on by default, so the collection works even without a cron job. On every page of the shop the module reads one value, the time of the next run. When that time has come, a short run starts at the end of the request: with PHP-FPM after the page has been sent to the visitor (3 seconds by default), otherwise for 1 second. A visitor whose cart already has an address does not start it. Every complete run (command line, cron URL, pseudo-cron, the Run now button) moves the next appointment forward by the expected frequency: with a cron job that runs on time the pseudo-cron does not start, and stays as a safety net.

On a shop with little traffic, or with a large catalog, set up the cron job (section 5.1): the pseudo-cron alone could take a long time to complete a cycle of the rotating check.

4.6 Status, log and lock

Every run is written in a log in the database (the last 500 runs), with its way in, start and end, result, items checked, changes and errors: no log files, no files to make writable. Two runs never work at the same time: they take a lock in the database, which the database releases by itself if a process dies. The state of the collection and the warnings are in the Status tab, on the dashboard and in the --status command (section 7).

4.7 Gaps of observation

With a history made of changes, “the price did not change” and “nobody looked” would look the same. So, when no complete run (command line, cron URL, pseudo-cron, the Run now button, the installation) happened for longer than Gap of observation after (hours) (and at least for twice the expected frequency), the next complete run marks every item of the shop in the history, at the same price: the collection had stopped. What the line shows then depends on when the reduction started:

  • before the stop: the reduction keeps its line, with the prior price observed before the reduction;
  • during the stop: there is no history before its start, so by default no line, or the lowest price since the start of the history if No history before the reduction is set to show it; the same holds for a reduction found after the stop on a product not yet checked again, when the time of the change is not known;
  • after the stop: until the window is complete again the reduction follows History shorter than the window: by default the lowest price since the end of the stop (“since” and the date), or no line.

If a discount was removed and put back during the stop, the module cannot know it. The Status tab shows a note for each shop with items not observed for a while in the window. The saves of the back office and the calls on single products do not count as complete runs. Set 0 to switch it off, for shops that change prices only from the back office.

5. For those who update prices from an ERP or another program

If your program saves the products through PrestaShop (the web service, the CSV import of the back office, the PrestaShop objects in a module), the module records the changes by itself (section 4.2). If it writes the prices directly in the database, PrestaShop does not know about it: the next complete run finds the change through the fingerprints (section 4.4), but you can tell the module at once in one of the ways below. All of them end in the same function and can be called again with the same prices without writing anything.

WayUse it when
Cron job, command line (5.1)you have access to the crontab of the server; also right after a nightly import
Cron job, URL (5.2)you only have a cron service that calls an address
Public hook (5.3)the import runs in a PrestaShop module
Static method (5.4)the import is a PHP script that loads PrestaShop
HTTP endpoint (5.5)the program runs elsewhere and knows ids, references or EAN-13 codes

In the examples, www.example.com is the address of your shop, /path/to/shop its folder on the server and YOUR_TOKEN the token shown in the Collection tab. Keep the token secret: anyone who has it can start runs.

5.1 Cron job from the command line

The recommended way. Copy the line from the Collection tab (it already contains the path of your shop) and add it to the crontab of the user of the web server, for example with crontab -u www-data -e on Debian and Ubuntu, or as a cron job of your account in the hosting panel:

# every 15 minutes, as the user of the web server
7,22,37,52 * * * * php /path/to/shop/modules/cll_omnibus/cron.php --quiet

Run it as the user of the web server, so that the files PrestaShop may write in its cache keep the right owner. The minutes of the line follow the expected frequency chosen in the Collection tab. Options:

  • --quiet: no output when everything is fine (errors are still printed);
  • --full: restart the complete check from the first product (if one is already running, it continues: section 4.4); --shop=ID: one shop only; --budget=SECONDS: stop after that time (without it, the run finishes the current cycle);
  • --status and --explain=ID_PRODUCT[:ID_COMBINATION]: diagnosis (section 7).

Without --quiet the command prints the summary of the run:

$ php /path/to/shop/modules/cll_omnibus/cron.php
status=ok run=3 checked=406 changed=0 gaps=0 errors=0 queued_left=0
queue 0, boundaries 0, fingerprints 346 read in 0.24 s, 4 changed, scan 346

The exit code is 0 when the run ended without errors (also when it stopped because of --budget), 1 with errors, 2 when another run is in progress. After a nightly import that writes the prices directly in the database, chain a run to it: the fingerprints find the products that changed. If you also want every item recomputed, add --full: without --budget the whole catalog is checked in that run.

30 2 * * * /path/to/your-import.sh && php /path/to/shop/modules/cll_omnibus/cron.php --quiet

The file cron.php refuses to run from a browser: it works only from the command line.

PrestaShop 1.7.1 with several shops and different default currencies. On this version a run can calculate the prices of one default currency only, so set one cron line per shop with --shop=N (or add &id_shop=N to the cron URL, section 5.2). A run that cannot calculate a shop ends with errors=1 and an error that mentions cron.php --shop=N: cron.php prints it on the line first error:, and the Status tab shows it too. Whenever you see it, use one line per shop. From PrestaShop 1.7.8 on this is not needed.

5.2 Cron job with the URL

For a cron service that calls an address. Copy the URL from the Collection tab; with friendly URLs it looks like the first line below, and the second form works too:

https://www.example.com/module/cll_omnibus/cron?token=YOUR_TOKEN
https://www.example.com/index.php?fc=module&module=cll_omnibus&controller=cron&token=YOUR_TOKEN

From a crontab, with curl or wget:

7,22,37,52 * * * * curl -fsS "https://www.example.com/module/cll_omnibus/cron?token=YOUR_TOKEN"
7,22,37,52 * * * * wget -q -O - "https://www.example.com/module/cll_omnibus/cron?token=YOUR_TOKEN"

The answer is plain text with the summary of the run:

status=ok run=4 checked=402 changed=0 gaps=0 errors=0 queued_left=0
queue 0, boundaries 0, fingerprints 346 read in 0.07 s, 0 changed, scan 346

With a wrong token the answer is 403 with the text forbidden. Add &full=1 to restart the complete check, &id_shop=N for one shop. A run from the URL works for the time set in the Collection tab (25 seconds by default) and continues at the next call. The URL works also while the shop is in maintenance, and asks search engines not to index it.

5.3 Public hook, from a module

If your import runs in a PrestaShop module, call the hook actionCllOmnibusRefresh after writing the prices:

$result = Hook::exec('actionCllOmnibusRefresh', [
    'products' => [12, 15],         // product ids: all their combinations
    'combinations' => [[12, 40]],   // [id_product, id_product_attribute] pairs
    'id_shop' => null,              // null = every shop of each product
], null, true);
// $result = ['cll_omnibus' => ['checked' => 6, 'changed' => 0, 'queued' => 0, 'run' => 12, 'full' => false]]

Pass null, true as third and fourth argument to receive the counts: without them PrestaShop does not hand back the answer of the module (the prices are recorded anyway). If the module is not installed, the call returns an empty array and nothing happens, so your module does not depend on it. Empty lists ask for a complete check of the catalog.

5.4 Static method, from a script

From a PHP script that loads PrestaShop, for example a script in the root folder of the shop run as the user of the web server:

<?php
// update-omnibus.php, in the root folder of the shop
require __DIR__ . '/config/config.inc.php';

// ... here your script writes the new prices ...

Module::getInstanceByName('cll_omnibus'); // loads the classes of the module
$result = CllOmnibusApi::refresh([12, 15], [[12, 40]]);
// $result = ['checked' => 6, 'changed' => 2, 'queued' => 0, 'run' => 14, 'full' => false]

The method is CllOmnibusApi::refresh(array $products = [], array $combinations = [], $idShop = null), with the same lists as the hook. In the answer, checked is the number of items recomputed (each combination in each shop), changed the rows written in the history, queued the products put in the queue and run the number of the run in the log. Up to 200 products are recorded at once; with more, or when another run is in progress for more than 5 seconds, the products go to the queue and the next runs record them. Calling it again with the same prices gives changed 0.

5.5 HTTP endpoint

For a program that runs elsewhere. The address is:

https://www.example.com/module/cll_omnibus/refresh
https://www.example.com/index.php?fc=module&module=cll_omnibus&controller=refresh

Send the token in the X-Cll-Omnibus-Token header (or in a token parameter: a token in the address ends up in the logs of the web server, so prefer the header). The request can be a POST in JSON or as a form, or a GET for short lists. For calls with a large body (over 1 MB) put the token in the X-Cll-Omnibus-Token header: if the token is only in the body, the call receives 403. Parameters:

  • ids: product ids ("12") or combinations ("12:40", product and combination);
  • references and ean13: references and EAN-13 codes of products or of combinations;
  • all=1: a complete check of the catalog; id_shop: one shop only.

In JSON:

curl -s -X POST "https://www.example.com/module/cll_omnibus/refresh" \
  -H "X-Cll-Omnibus-Token: YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"ids":["12","12:40"],"references":["REF-1"],"ean13":["4006381333931"]}'

Example of answer:

{"ok":true,"resolved":4,"not_found":[],"checked":8,"changed":2,"queued":0,"run":16}

As a form, or with a GET:

curl -s -X POST "https://www.example.com/module/cll_omnibus/refresh" \
  -H "X-Cll-Omnibus-Token: YOUR_TOKEN" -d "ean13=4006381333931,4006381333948"

curl -s "https://www.example.com/index.php?fc=module&module=cll_omnibus&controller=refresh&token=YOUR_TOKEN&references=REF-1,REF-2"

A code that matches nothing is listed in not_found, for example {"ok":true,"resolved":1,"not_found":["reference:REF-2"],...}. A complete check: -d '{"all":1}' answers {"ok":true,...,"full":true,"run":0} and the next runs do the work.

CodeAnswerMeaning
200{"ok":true,"resolved":...,"not_found":[...],"checked":...,"changed":...,"queued":...,"run":...}done; resolved = items found
400{"ok":false,"error":"nothing_requested"}no id, reference or EAN in the request
403{"ok":false,"error":"forbidden"}wrong or missing token
413{"ok":false,"error":"too_many_items","max":500}more items than Endpoint: items per call: split the list
429{"ok":false,"error":"too_many_calls","retry_after":1693}more calls than Endpoint: calls per hour; the Retry-After header gives the seconds to wait

The token never appears in the answers or in the log of the runs. Sending the same list twice writes nothing the second time.

6. What your customers see

On the product page of a reduced product the line appears under the price (or next to the crossed out price), in the language of the visitor, in the visitor's currency and with or without tax like the rest of the page. With the default texts:

  • with a reduction: Lowest price in the last 30 days: €13.07;
  • with a history shorter than the window, or for a new product: Lowest price since 11/06/2026: €13.07;
  • with the option Always and no reduction: Lowest price in the last 30 days: €14.52.
The line on the product page
The line under the price on the product page (model Plain text)
The line on a phone
The same on a phone, 390 pixels wide

When a combination is chosen, the line follows it. In the mode Strict a reduction that is not real loses the crossed out price and the percentage of the theme, and the line stays. In the mode Prior price as crossed out price the crossed out price and the percentage of the theme are replaced by the prior price and by the reduction calculated on it. In every mode the price the customer pays stays the same.

Prior price as crossed out price
Mode Prior price as crossed out price: crossed out price and percentage calculated on the prior price

With Product lists on, the line also appears in the product thumbnails of themes that print the unit price block (model Compact by default).

The line in a product list
The line in a product thumbnail

The line is not shown when the price the visitor sees is not the recorded one (another customer group with its own prices, a price set for a currency, a change not collected yet), for products of an excluded category, for products never recorded, by default for products whose reduction began before the collection started or while it was stopped, and according to the options for reductions that are not real and for a partial history. The module never shows a prior price it cannot vouch for.

The price chart

With the chart on (section 3.3: it is off by default), the product page shows, under the Omnibus line, the prices recorded for the combination shown, drawn as a thin line. The line of text stays the element that the rule asks for: the chart is information in addition to it and never replaces it. As everywhere in this guide, this is not legal advice: what your country asks is for you to assess.

The price chart under the Omnibus line
The chart under the Omnibus line, period of 90 days
  • Price paid, in steps: the line stays flat while the price is the same and makes a step on the day of each change. The prices are the recorded ones, shown as the Omnibus line shows them: in the currency of the visitor and with or without tax like the rest of the page.
  • The window and the lowest price: a shaded band marks the days that the Omnibus line looked at to find the prior price, and a dot marks the lowest price, with the same text and the same amount as the line: the chart does not calculate a second one. Where the window starts before the period shown, only the visible part is drawn. Where the Omnibus line is not shown for the product (a product that is not reduced, or an option of the Display tab that hides it in that case), the chart is still drawn, without the band and the dot.
  • Periods: above the chart the customer chooses among the periods you offer (30 days, 90 days, 1 year); the one you set as first is shown when the page opens. It works with the mouse, with a tap and with the keyboard.
  • Prices one by one: moving the mouse over the chart, tapping it or using the left and right arrow keys shows a tip with the price and the dates in which it applied.
  • As a table: Show prices as a table opens the same prices as a table (From, To, Price paid, and Regular price when you draw it). It is for those who use the keyboard or a screen reader, and for anyone who prefers numbers. The drawing also has a text description for screen readers: the price of today, the lowest and the highest of the period and the number of changes.
The price chart on a phone
The same on a phone, 390 pixels wide
The chart with the missing stretch, the tip and the table
Period of 1 year: the missing stretch of a stop of the collection, the tip on a price and the table open

Why the dot is on €16.96 although there are lower prices on the right. The two steps on the right, €15.26 and €13.57, are the reduction in progress (first -10%, then -20%), not prior prices. The shaded band is the days before the start of the reduction, and there the lowest price is €16.96. With progressive reductions on, the prior price stays the price before the first step, as section 3.2 explains (Progressive reductions).

When the data is not complete, or is large, the chart behaves like this:

  • A stop of the collection (section 4.7) is drawn as a hatched stretch: the line does not run through it and nothing is guessed, and the table has a row Prices not recorded for those days.
  • A short history (a new product, or just after the installation): the drawing starts from the first recorded price, and the date under it says Since and that date.
  • More than 240 changes in the period: the chart shows the lowest price of each day, and a note under the drawing says so.
  • A second currency: the recorded prices are converted at today's rate, with a note under the chart that says so.
  • Combinations and quick view: the chart follows the combination chosen: when the customer chooses another one, the theme redraws the price block and the chart is the one of the new combination. In the quick view of the themes that have one, the chart appears when the line does (Quick view in the Display tab). In a quick view opened from a product list the tip on mouse over is not available, while the periods and the table work.

The chart is drawn on the product page only, never in product lists. It is not shown, and nothing is printed, when the chart is off, when the product belongs to an excluded category, when the price the visitor sees is not the recorded one (a customer group with its own prices, a price set for a currency, a country or a rule that gives another price: the same condition as for the line), when the price did not change in the longest period offered, or when the price of today is zero. If the shop does not show prices to a visitor (catalog mode, a group without prices, a product with its price hidden), there is no chart for that visitor either.

Custom themes

If your theme does not print the standard price block of the product page, place the line yourself with the widget or the hook of the module:

{widget name='cll_omnibus' product=$product}
{hook h='displayCllOmnibus' product=$product}
{widget name='cll_omnibus' id_product=12 id_product_attribute=40}

The line is a span element shown as a block, with the class cll-omnibus, the class of its model (for example cll-omnibus--plain) and the attribute data-cll-omnibus-state (ok, partial, new or always); the price is in its own element, cll-omnibus__price. When there is nothing to show, nothing is printed. To go beyond the Appearance tab, redefine the CSS variables of the line in the stylesheet of your theme (--cll-omnibus-text, --cll-omnibus-bg, --cll-omnibus-border, --cll-omnibus-accent, --cll-omnibus-size, --cll-omnibus-radius), or copy the template views/templates/hook/omnibus.tpl of the module into themes/your-theme/modules/cll_omnibus/views/templates/hook/.

To place the price chart, set Position to Only where the theme places it (widget) in the Appearance tab (section 3.3) and add one of these lines where you want the chart:

{widget name='cll_omnibus' show='chart' product=$product}
{hook h='displayCllOmnibus' product=$product show='chart'}

Without show='chart' the widget and the hook print the line, as before. With show='chart' they print the chart, and only when the chart is on and its position is the widget; in every other case they print nothing. The chart is a figure element with the class cll-omnibus-chart; its style sheet and its script are loaded only when the chart is on.

7. Check that it works

  • Open the Status tab: the message is green, Initial snapshot says Complete for every shop and Last run by source shows recent runs.
  • From the command line, --status gives the same information in JSON: the last run of each way in, the queue, the shops and the list of warnings (empty when everything is fine).
$ php /path/to/shop/modules/cll_omnibus/cron.php --status
{
    "now": "2026-11-30 09:31:58",
    "frequency": 15,
    "pseudo_cron": true,
    "last": { "cli": { "status": "ok", "checked": 402, ... }, ... },
    "queue": 0,
    "shops": [ { "id_shop": 1, "items": 354, "recorded": 354, "fresh": 354, "snapshot_done": "2026-11-30 09:29:05", ... } ],
    "warnings": []
}
  • --explain=ID_PRODUCT[:ID_COMBINATION] shows how the prior price of one item is calculated for the reference visitor: the periods of the history, the start of the reduction, the window, the prior price, whether the reduction is real, and the text the shop would show (in the default language of the shop).
$ php /path/to/shop/modules/cll_omnibus/cron.php --explain=7
"result": { "state": "ok", "reduced": true, "reference_ti": 13.0662, "current_ti": 11.6144,
            "regular_ti": 14.518, "start": "2026-11-30 11:35:38", "window_from": "2026-10-31 00:00:00",
            "real": true, "percent": 11, "anchor_unknown": false, ... },
"text": "Lowest price in the last 30 days: 13.07 EUR"
  • In the product page of the back office, the panel of the module shows the same prior price (section 3.6).
  • With the chart on, open the product page of a product whose price changed within the longest period you offer: under the Omnibus line the chart shows the steps, the shaded window and the dot with the same amount as the line. If you do not see a chart, read the question Why is there no chart on a product? in section 8.
  • Put a reduction on a product whose price has not changed in the last 30 days, and open its product page: the line shows the price before the reduction. In the first 30 days after the installation the line says “since” and the date of the installation, because the history is shorter than the window.

8. FAQ

I installed the module while some products were already reduced.

For these products the start of the reduction is not known, so by default they show no line (No history before the reduction in the Display tab). If you choose to show it, the line gives the lowest price observed since the installation, today's price included (“Lowest price since {date}”). In both cases the crossed out price of the theme is not replaced and the Tools tab lists them as “reduction began before the collection started or while it was stopped”. If the discount has a start date earlier than the installation, Rebuild from discounts with dates can complete their history.

Why does the line say “Lowest price since” and a date?

Because the history of that item is shorter than the window: after the installation, for a new product, or for a reduction that started after a gap of observation (section 4.7). The date says from when the prior price is known. If you prefer, choose Do not show the line in History shorter than the window.

How are new products handled?

A product on sale for less than the window shows the lowest price since the date it was added to the shop, with the text for a partial history or a new product. You can also treat new products like any partial history (New products in the Display tab).

My shop has more currencies.

The history is kept in the default currency of the shop. A visitor who uses another currency sees the prior price converted with today's rate of that currency, as long as the price they see is the recorded price converted. If a specific price is set for that currency, the line is not shown.

I sell to business customers, with other groups and prices without tax.

The line is shown to the customers whose price is the one of the reference visitor: for a group that sees prices without tax the prior price is shown without tax, like the rest of the page. Customer groups with their own prices or discounts do not see the line, because the history does not describe their prices.

My theme does not show the line.

Your theme may not print the standard price block of the product page. Use the widget or the hook of the module in the template of your theme (section 6), or try the other Position on the product page.

My ERP writes the prices directly in the database.

The next complete run finds them through the fingerprints of the price data (section 4.4). To record them at once, use one of the ways in of section 5, or run cron.php right after the import.

Will the history table grow too much?

A row is written only when a price changes, not every day. A shop with 20,000 items whose prices change once a month writes about 240,000 rows a year. Rows older than the retention period (400 days by default) are deleted once a day, keeping the last price before the limit; the items reduced today keep their whole history as long as the reduction lasts.

Does it slow down my shop?

On the product page of a reduced product the module reads the history of the combination shown with one query (in product lists, one query for the whole list), and on the other pages the pseudo-cron reads one value. The collection runs at the end of a request, in a cron job or in the back office. No external service is called while the pages of your shop are displayed.

Does the chart replace the Omnibus line?

No. The line stays the element that the rule asks for, and the chart is information in addition to it, drawn under it; you can leave the chart off. The price the customer pays does not change in any case. Which elements and texts your country asks for is for you to assess: this guide is not legal advice.

Why is the chart off by default?

Because it shows to your customers, and to your competitors, all the past prices of a product, up to a year, and not only the lowest one of the line. Whether to show them is a choice of the shop, and the module does not make it for you: turn the chart on in the Appearance tab when you want it.

Why is there no chart on a product?

The chart is not shown, and nothing is printed, in these cases:

  • the chart is off, or its position is Only where the theme places it (widget) and the theme does not print it (section 6);
  • the price never changed in the longest period offered: a product that always had the same price has no chart (the back office draws it as a flat line);
  • the default category of the product is excluded in the Display tab;
  • the visitor is not in the situation of the reference visitor: another customer group, another country or a rule that gives that visitor a price different from the recorded one;
  • the price of today is zero;
  • the shop does not show prices to that visitor (catalog mode, a group without prices, a product with its price hidden).

The chart is drawn on the product page only, never in product lists.

What does a missing stretch in the chart mean?

The collection had stopped (section 4.7): nobody looked at the price in those days, so the chart does not draw it and does not join the two ends with a line. The table says Prices not recorded. It does not mean that the price was zero, nor that it changed. The Status tab tells you whether the collection works today.

Does the chart slow down the product page?

With the chart off, nothing: the module reads and loads nothing for it and prints nothing. With the chart on, there is no external library and no call to other sites: the module reads the history of the combination shown only, and loads one style sheet and one script, only where the chart is shown.

Are vouchers and cart rules recorded?

No. The module records the price of the product as a visitor sees it on the product page: the price of the product, its specific prices and the catalog price rules. Vouchers and cart rules are not part of that price.

Two campaigns in a row, for example Black Friday and then Christmas.

With Progressive reductions on (the default), the prior price stays the price before the first step as long as the reduced price only goes down, without interruption. The module sees prices, not campaigns: when a second campaign follows the first one with a lower price and no pause, the module treats the two as one progressive reduction and keeps the prior price from before the first one. According to the Commission guidelines the rule of progressive reductions applies within one campaign without interruption, while a new campaign follows the general rule: its prior price can be the reduced price of the first campaign. If you run distinct campaigns one after the other, consider switching the option off for that period, or leaving a pause with the regular price between them. This is not legal advice: what counts as one campaign depends on how the authority of your country reads it.

A product shows the sale flag of the theme, but no line.

The line follows real price reductions. A product with only the “On sale!” flag of PrestaShop switched on, and no reduction of its price, gets no line, because there is no reduction to calculate a prior price for. Only with When set to Always does it show the line, with the text without a reduction. The Commission guidelines count wording such as “sale” as an announcement of a reduction too: if you use the flag without a reduction, check what your rules ask.

Logged in customers do not see the line.

The line is calculated for the Reference visitor of the Collection tab (by default the Visitor group and the default country of the shop) and is shown only to visitors whose price is the recorded one. Customers of groups with other prices, for example a group with its own discount, do not see it. If you give a discount to the group of all registered customers, your customers do not see the line once they are logged in. Discounts “for members only” are also mentioned in section 2.

What changes or restarts the history of an item?

  • Changing the Customer group or the Country of the reference visitor rewrites the base of the history: the next runs record the prices as the new visitor sees them, and rows appear that look like price changes.
  • Disabled products are not recorded: when a product is enabled again, the period it was disabled counts at the price it had before.
  • Regenerating the combinations of a product (they get new ids), or adding the first combination to a product without combinations, starts the history of those items again from zero.
  • In a second currency the prior price is the recorded history converted at today's rate.
  • A discount that starts and ends within a stop of the collection shorter than Gap of observation after (hours) leaves no trace in the history, and such a stop leaves no mark.

What happens when I uninstall the module?

Settings and hooks are removed. The price history stays in the database, unless you chose Yes, delete it in Delete all data on uninstall: a deleted history cannot be rebuilt. When the history stays, the token stays with it, so after a new installation the cron job and the external software keep working.

Does the module make my shop compliant?

It records your prices and shows the prior price calculated from them, with the options described here. Whether your texts, your reductions and your settings meet the rules of your country is for you to assess, ideally with your legal advisor.

Loading...
Back to top