Hikashop - Plugin Price Calculations

  • Posts: 343
  • Thank you received: 10
  • Hikashop Business
12 hours 3 minutes ago #368020

Hello.
I’m using your HikaShop - Price Calculations plugin to customize product prices based on custom fields and conditional formulas. So far, it works great with simple conditions like:
{etiqueta_001}=="SI" && {cant_etiquetas}=="1" && {grupoetiquetas}=="20u"
and formulas such as:
{price} + 1.5
Now, I need to apply around 216 unique combinations of three parameters:

ancho_etiqueta (label width)

alto_etiqueta (label height)

grupoetiquetas (quantity group)

Each combination requires setting a fixed final price (not an addition to {price}), which I have pre-calculated and organized in a spreadsheet.

For example, one condition and formula would look like this:

Condition:
{etiqueta_001}=="SI" && {ancho_etiqueta}=="3" && {alto_etiqueta}=="4" && {grupoetiquetas}=="500u"
Formula:
49.25
Additionally, please note that ancho_etiqueta and alto_etiqueta are custom fields I created to store label width and height.

My questions are:

Is there any way to bulk import or batch load all these 216 condition + formula rules, for example by CSV, JSON, or another method, instead of adding them manually one by one?

If bulk import is not possible, is there a way to add them directly via configuration files or code?

If neither is possible, are there any performance or technical limitations with having this many rules created manually?

Thank you very much for your help. I really want to maximize the potential of your plugin.

Please Log in or Create an account to join the conversation.

  • Posts: 84146
  • Thank you received: 13649
  • MODERATOR
6 hours 16 minutes ago #368024

Hi,

You can go in your PHPMyAdmin and open the extensions table of Joomla. There, search for the entry for the calculations plugin. One of the last entries, I suppose.
Edit it, and in the "params" column, you'll find the JSON with all the formulas and conditions of the plugin. So you can follow this structure to generate a new JSON with all the entries you need and update it there and you'll then see all the formulas and conditions when you edit the plugin settings via the Joomla plugins manager.

A few hundred rules won't be a problem.

Please Log in or Create an account to join the conversation.

Time to create page: 0.047 seconds
Powered by Kunena Forum