By Bernt-Uwe Berwing & Markus Berwing GbR on Thursday, 15 September 2022
Posted in General Issues
Replies 5
Likes 0
Views 1K
Votes 0
In PayPlans - Settings - General:
Decimal Separator is Comma (,)


Plans:

New Plan

Regular Price: If I use comma (let's say 24,99) I do get error:

An error has occurred.
0 round(): Argument #1 ($num) must be of type int|float, string given
Return To Dashboard


And if I navigate back to the Plans, I always get same error and I am not longer able
to access any of my existing plans and cannot bypass the error being stucked in the application.


The only solution to fix the issue is to connect to MySQL DB and table xyz_payplans_plan
and manually delete the row for the problematic plan in question.


While the price for the plans in the plan overview are correctly listed in format decimal separator with comma,
the same field for regular price in detail view is showing the dot (.)


Bottom line:
I am expecting to use comma based on Settings in General and also see the comma in the corresponding field

To me this is a bug.
Hey Markus,

In PayPlans - Settings - General:
Decimal Separator is Comma (,)

Right now this "Decimal Separator" setting will only be affected the plan price display on the frontend and backend parts.

While creating the plan you must use price as a dot(.) decimal separator (for example 23.99).

The reason why the plan creation part has to use a dot(.) decimal separator for the price is that the PHP function we used only supports dot(.) to round the value of the price you set.

By the way, thanks for your report, we will probably add an alert to the end user shouldn't change the decimal separator to other symbols to prevent this PHP 8 error in the next version.

Let me know if you will have any confusion.
·
Thursday, 15 September 2022 11:43
·
0 Likes
·
0 Votes
·
0 Comments
·
Hi Manisha,

thanks for the fast reply......appreciated.

I fully understand the technical part of your answer.

But it is very important that there is an alert on this field so that site administrators are not taking the comma by mistake which is causing this situation being stucked and not able to access any of the plans anymore.
No everyone has direct access to the DB and can manually delete data.

This should be implemented quite quickly in next release please.

Thanks
Markus
·
Thursday, 15 September 2022 20:32
·
0 Likes
·
0 Votes
·
0 Comments
·
Hey Markus,

I am really sorry for the delayed response.
We have already added this to our issue tracker and will include this in the coming release.

Thank you for understanding!
·
Tuesday, 20 September 2022 10:37
·
0 Likes
·
0 Votes
·
0 Comments
·
Thanks a lot.
Regards
Markus
·
Tuesday, 20 September 2022 16:41
·
0 Likes
·
0 Votes
·
0 Comments
·
you're most welcome.
·
Tuesday, 20 September 2022 17:04
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post