Donation feature does not override the price

  • Posts: 58
  • Thank you received: 2
8 years 4 weeks ago #269718

-- HikaShop version -- : 3.0.1
-- Joomla version -- : 3.7
-- PHP version -- : 5.6

Hi

Want to make a custom field where a user can put in the value of the voucher he wants to buy (and let it be sent as e-ticket with the support of attach serial plugin).
Example: User puts in "300" for a voucher which should be worth 300 Euros.

I activated the donation plugin, created a custom field of the table "item" with the column name "amount".
Like it is in the demo.

The field is there, but when adding to the product to the cart ....the value of the custom field does not override the price.
(no difference if there is a price for the product or not / "free")
No overwriting at all.

What did I miss?

Attachments:

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

  • Posts: 83986
  • Thank you received: 13603
  • MODERATOR
8 years 4 weeks ago #269740

Hi,

If the value in the field is not taken into account even though you see it attached to the product in the cart, then there must be a problem with the settings of the plugin.
Could you provide a screenshot of its settings ?

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

  • Posts: 58
  • Thank you received: 2
8 years 4 weeks ago #269749

Hi

I tried with all 3 possible settings in the plugin - same result, no overriding of the price.
-No taxes
-On top of the amount
-already included in the amount

Screenshot:




I am using HikaMarket and HikaSerial, too. Any settings there?

Attachments:

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

  • Posts: 83986
  • Thank you received: 13603
  • MODERATOR
8 years 4 weeks ago #269751

Hi,

Well, the issue is indeed with the settings of that plugin.
In the field "Column name of the field", you're supposed to enter the column name of the custom field. Since the column name of your custom field is "amount", you should have "amount" written in that setting.
That's why it doesn't work since the plugin doesn't find any custom field with the column name you entered.

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

  • Posts: 58
  • Thank you received: 2
8 years 4 weeks ago #269856

Hi,
thank you, this should have been obvious.:)

Another questions:

- Can I restrict the field to digits (123...0)?

- How could I prescribe a minimum (user shall fill in more than for example 100)? Is this possible?


thanks
Walter

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

  • Posts: 83986
  • Thank you received: 13603
  • MODERATOR
8 years 4 weeks ago #269858

Hi,

Yes. You can use the regex check setting of the custom field for that.
You enter for example:

[0-9]{3,9}
That will only allow numbers from 100 to 999999999
You can learn more about regex here:
www.regular-expressions.info/tutorial.html

The following user(s) said Thank You: woidl

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

Time to create page: 0.072 seconds
Powered by Kunena Forum