• Resolved Isabel Pinhel

    (@isabelpinhel)


    Hi there,

    I am using this plugin to try to create wishlists for bookable products (using Woocommerce Bookings plugin).
    I am having a bug when saving original_price (defined as decimal (9,3) ) to the yith_wcwl database in that if original product price is eg. 9.99, it will save it as 9.00. The price is obtained via the function get_product_price() which ultimately uses $product->get_price() which will fetch the data from post_meta database where it is stored as text. I have researched and tried several ways to convert string to decimal but no matter what I do, the decimal places are always gone when writting to yith_wcwl database. Any idea why this is happening?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author YITHEMES

    (@yithemes)

    Hi there

    You’re totally right, thank you for your report!
    Issue will be fixed in next version of the plugin

    Meanwhile, if you want to test our solution, you can download this file, and upload it on your server, under wp-content/plugins/yith-woocommerce-wishlist-premium/includes/data-stores/, overwriting previous version (please, make sure to test this on a development environment before deploying on a production server)

    Thread Starter Isabel Pinhel

    (@isabelpinhel)

    Worked beautifully! Thank you so much!

    Plugin Author YITHEMES

    (@yithemes)

    Hi there

    You’re welcome! Just a quick note to let you know that latest plugin update contains the fix that we discussed ??

    We are doing our best to improve our plugins. Our target is to develop and release the best free plugins for WooCommerce, but to achieve this we need your help. Please leave a good review to support us and help our growth ??

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘original_price not saving decimal places in database’ is closed to new replies.