Bienvenido, Invitado
Recordarme

TEMA:

NEW RULE FOR BreezingForms Prices 9 meses 2 semanas antes #243388

  • Autor del tema
  • Sol Olmedo
  • Fuera de línea
  • Junior Breezer
  • Junior Breezer
  • Mensajes: 34
  • Gracias recibidas: 1
Ey guys, pretty simple request, i wish to create a NEW type of rule for the BFPrices Pluggin, Identical to the VALUE RULE, but that SUBSTRACTS THE VALUE instead of ADDING THE VALUE..

Por favor, Identificarse o Crear cuenta para unirse a la conversación.

NEW RULE FOR BreezingForms Prices 9 meses 2 semanas antes #243391

  • Avatar de TheMuffinMan
  • TheMuffinMan
  • Fuera de línea
  • Developer
  • Developer
  • Mensajes: 10064
  • Karma: 167
  • Gracias recibidas: 808
Hi,

I think you mean BreezingCommerce combined with BreezingForms, right?

Because this option is available already using the "Price Rule", where you can perform basic math on the desired BF field:



Please let me know if this is what you mean.

Regards,
Markus
Adjuntos:

Por favor, Identificarse o Crear cuenta para unirse a la conversación.

NEW RULE FOR BreezingForms Prices 9 meses 2 semanas antes #243397

  • Autor del tema
  • Sol Olmedo
  • Fuera de línea
  • Junior Breezer
  • Junior Breezer
  • Mensajes: 34
  • Gracias recibidas: 1
Hi, YES is BC + BFPrices pluggin..... BUT here`s the catch, im using a custom version of your BF coupons app (form) to generate DISCOUNT coupons, what im looking for, is to implement it in a DisplayPluggin Form into my product, and generate a discount acording to the Coupon Setting.

So, i alrredy have all setup, but all rules in the BFPricePluggin, ADD the amount of my result field. And I need to SUBSTRAC so i can generate the discount according to the coupon in the final order.

Thank a lot guys.
Adjuntos:

Por favor, Identificarse o Crear cuenta para unirse a la conversación.

NEW RULE FOR BreezingForms Prices 9 meses 2 semanas antes #243399

  • Avatar de TheMuffinMan
  • TheMuffinMan
  • Fuera de línea
  • Developer
  • Developer
  • Mensajes: 10064
  • Karma: 167
  • Gracias recibidas: 808
What about the code option then?
$price = $current_price - floatval( $field_values->value );

Just an example, but based on what you got, you have full control here.

Por favor, Identificarse o Crear cuenta para unirse a la conversación.

Última Edición: Post by TheMuffinMan.

NEW RULE FOR BreezingForms Prices 9 meses 2 semanas antes #243400

  • Autor del tema
  • Sol Olmedo
  • Fuera de línea
  • Junior Breezer
  • Junior Breezer
  • Mensajes: 34
  • Gracias recibidas: 1
This is great, i´m givint it a try. Please one more question,

$price = $current_price - floatval( $field_values->value );

$current_price // variable is my PRODUCT price?

$field_values // variable should i replace it by the field name in the form?

floatval // variable should i replace it by the field name in the form?

I´m sorry for the constant questioning, and again thanks for the support

Por favor, Identificarse o Crear cuenta para unirse a la conversación.

NEW RULE FOR BreezingForms Prices 9 meses 2 semanas antes #243401

  • Avatar de TheMuffinMan
  • TheMuffinMan
  • Fuera de línea
  • Developer
  • Developer
  • Mensajes: 10064
  • Karma: 167
  • Gracias recibidas: 808
$current_price // this is the currently calculated price. If another field before this one changed it, it is passed to the next field (so the field order is important)

$field_values // this is the actual "value" of the field. It could also be a group (separated by comma), that's why it is plural. You can also access "$fields" which holds all the fields of the form in their current states

floatval // this just makes sure that the string in the value is a float number and calculatable through a math operation

Por favor, Identificarse o Crear cuenta para unirse a la conversación.

Última Edición: Post by TheMuffinMan.
  • Página:
  • 1
  • 2
Tiempo de carga de la página: 0.079 segundos