Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Martin Pawollek 17 posts 148 karma points
    Jun 28, 2022 @ 14:13
    Martin Pawollek
    0

    Cart details in backoffice displaying prices mutliplied by 100 (instead of the actual price)

    Hi Matt,

    we've noticed some strange behaviour in the cart details view located in the backoffice.

    The product prices inside of a cart are sometimes displayed with a much higher value, than the actual product price.

    To be more specific: the value is always multiplied by 100. For example when a product has a price of 135,00 €, then it's shown with the value of 13.500,00 € in the cart details (regardless of the use of discounts/tax or the cart status).

    This has no impact on the orders and the payments though, only when it comes to displaying the price in the cart detail view. This happens to like 85% of our cart views and I have currently no way to replicate it.

    Umbraco version: 9.5.0 Vendr version: 2.2.0

    Kind regards, Martin

  • Matt Brailsford 4124 posts 22215 karma points MVP 9x c-trib
    Jun 28, 2022 @ 14:46
    Matt Brailsford
    0

    Hi Martin,

    Hmm, I wonder if it's a culture thing. Maybe the comma is being translated as a thousand seperator and is thus being formated incorrectly.

    I'll do some testing and see if I can replicate it 🤔

    Matt

  • Matt Brailsford 4124 posts 22215 karma points MVP 9x c-trib
    Jun 29, 2022 @ 08:53
    Matt Brailsford
    0

    Hmm, I don't really seem to be able to replicate this 🤔

    I've setup some prices in Euro with a similar value, and tried various combinations of products. I've also tried switching my browser culture to see if that has an effect but again, I'm unable to replicate.

    Are you able to invetigate this further your end?

    Are the prices incorrect on first load of the cart? Or is it only after modifying it? If the prices are wrong on first load, does modifying the cart in some way via the back end correct it? or does it continue to be wrong?

  • Martin Pawollek 17 posts 148 karma points
    Jun 29, 2022 @ 11:29
    Martin Pawollek
    0

    Hi Matt,

    yeah I'm also having trouble to replicate that issue. I will try to investigate if some manipulation is triggering a culture change or something similiar.

    The prices are incorrect on first cart load, yes. No updates are being made in the backoffice cart view.

  • Matt Brailsford 4124 posts 22215 karma points MVP 9x c-trib
    Jun 29, 2022 @ 12:38
    Matt Brailsford
    0

    Hmmm, maybe there is something different if the order is created on the front end compared to the back end 🤔

    I'll see if I can investigate that aspect, but if you do find anything further, please do let me know.

  • Martin Pawollek 17 posts 148 karma points
    Jul 08, 2022 @ 07:36
    Martin Pawollek
    100

    Hi Matt,

    I was able to find the issue on this topic. We've got a custom OrderLineCalculator implementation, where prices are overwritten by external values (which we also save in the order property).

    So in this calculator we parse a string value to a decimal without defining a culture explicitly. When we view the Cart in the backoffice, this Calculator is using the backoffice user culture set in the profile (in our case "en-GB"). The incoming string value has a german price format though and this is causing the display error.

    Basically a parsing error on our side.

    Thanks for your help regardless!

    Martin

  • Matt Brailsford 4124 posts 22215 karma points MVP 9x c-trib
    Jul 08, 2022 @ 07:42
    Matt Brailsford
    0

    Ahhhhhh, phew!

    Really glad you were able to find the issue and put a fix in place.

    Best of the luck with the rest of the project 👍

Please Sign in or register to post replies

Write your reply to:

Draft