• Resolved Rimas

    (@erku)


    Product weight and measurement fields (and perhaps some others) may need unit conversion for some providers. For example, eMAG requires measurements in millimeters, while WooCommerce stores them in centimeters. Please consider implementing such filters.

Viewing 6 replies - 1 through 6 (of 6 total)
  • Thread Starter Rimas

    (@erku)

    Also on somewhat related note: when I set suffix to 0 in an of a lazy conversion of cm to mm, that suffix was ignored, because "0" is an empty value in PHP, and both the prefix and suffix are tested for being empty here. Instead of checking for these values being empty, may I suggest you to just cast them to strings before using?

    Thread Starter Rimas

    (@erku)

    To add to my initial suggestion: instead of creating multiple unit conversion filters, it would probably be better to allow specifying a multiplier when configuring a field (similarly to setting prefix and suffix), which should be applied if the value in the field is numeric. This way, a single option would cover conversion between all units of the same type as well as any other cases where multiplication or division would be necessary (I can’t currently think of any, but that doesn’t mean there are none).

    For example, a multiplier of 10 would effectively convert centimeters to millimeters, and a multiplier of 0.1 would convert the other way around.

    • This reply was modified 2 weeks, 1 day ago by Rimas.
    Thread Starter Rimas

    (@erku)

    By the way, eMAG appears to expect weights in grams, whereas WooCommerce stores them in kilograms. Again, multiplication is needed, and this time it can’t be solved by a suffix without sacrificing ability to specify weights in fractions of kg.

    Plugin Support Md Monir Hossain

    (@monircoderex)

    Hi,

    Thank you for reaching out!

    This functionality can be achieved using one of our Pro features. As this platform is designated for our free users, we’re unable to discuss Pro features in detail here. To assist you further, please contact us through our official support channel at [email protected], where we’ll be glad to help you implement this solution.

    Best regards,

    Thread Starter Rimas

    (@erku)

    Fair enough, I guess. Thanks for the clarification! ??

    Plugin Support Md Monir Hossain

    (@monircoderex)

    You’re very welcome! ??

    If you’re satisfied with our plugin, we would greatly appreciate it if you could leave us a 5-star rating here.

    Your kind act would make a significant difference for us in the long run. Please see if it’s possible to consider our humble request. It would truly mean the world to our team!

    Thank you so much for your support!

    Best regards,

Viewing 6 replies - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.