Copied to clipboard

Flag this post as spam?

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


  • Amir Ahmed 5 posts 85 karma points
    May 04, 2021 @ 13:27
    Amir Ahmed
    0

    Order summary does not expand (mobile view)

    Vendr v1.5.1 Umbraco version 8.11.1

    Summary does not expand when clicked.

    I can fix it by calling initSm(); in the vendrcheckout.js but wondering if this this has been fixed in any subsequent versions or not.

    enter image description here

  • Matt Brailsford 4124 posts 22215 karma points MVP 9x c-trib
    May 04, 2021 @ 14:34
    Matt Brailsford
    0

    Hi Amir,

    I seem to recall this issue previously and am wondering if it's an issue with the simple state machine library not firing on breakpoint change. Are there any JS errors present in developer tools? And are you able to see if the breakpoint code ever runs correctly on breakpoint change?

    Matt

  • Amir Ahmed 5 posts 85 karma points
    May 04, 2021 @ 14:50
    Amir Ahmed
    0

    Hi Matt,

    No console errors

    I just noticed in the vendrcheckout.js that the initCommon() was called but but not the initSm() so I just added that as the fix.

  • Matt Brailsford 4124 posts 22215 karma points MVP 9x c-trib
    May 04, 2021 @ 15:08
    Matt Brailsford
    101

    Hi Amir,

    The call to that method shouldn't really be done manually. The point of the simple state machine library is that it responds to breakpoints and runs the relevant function call when a breakpoint is crossed, so the initSm method should ONLY be run when in a small breakpoint, and then the initLg should be run when you move to/start in the larger breakpoint.

    Maybe upgrading the simple state machine library in the master layout file to a newer version might fix it. This it the library in question https://github.com/jonathan-fielding/SimpleStateManager there appears to be a bunch of newer versions.

    Matt

  • Amir Ahmed 5 posts 85 karma points
    May 05, 2021 @ 08:34
    Amir Ahmed
    0

    That seem to do the trick.. I've upgraded to v4 and it's working fine now. Thanks

  • Matt Brailsford 4124 posts 22215 karma points MVP 9x c-trib
    May 05, 2021 @ 08:41
    Matt Brailsford
    0

    Excellent.

    I'll raise an issue on the Vendr Checkout repo to say we need to upgrade it.

    Glad you were able to get it working though

    Matt

  • Edgar Rasquin 326 posts 925 karma points
    Jan 11, 2022 @ 14:08
    Edgar Rasquin
    0

    Hi Amir,

    How did you go about upgrading the SimpleStateManager?

    Thanks, Edi

  • Matt Brailsford 4124 posts 22215 karma points MVP 9x c-trib
    Jan 11, 2022 @ 15:09
    Matt Brailsford
    1

    Hey Edgar,

    You should be able to update this line in the Vendr Checkout templates to point to the latest version https://github.com/vendrhub/vendr-checkout/blob/v2/dev/src/Vendr.Checkout/Web/UI/App_Plugins/VendrCheckout/views/VendrCheckoutMaster.cshtml#L213

    Though I believe 4.1.1 is the latest (unless you are on an old version of Vendr Checkout)

  • Edgar Rasquin 326 posts 925 karma points
    Jan 11, 2022 @ 15:13
    Edgar Rasquin
    1

    Thanks Matt,

    I actually just downloaded the latest version of SimpleStateManager (https://github.com/jonathan-fielding/SimpleStateManager/releases/tag/3.1.3) and integrated the ssm.min.js into the project and referenced it. Works for me.

    Regards, Edi

  • Amir Ahmed 5 posts 85 karma points
    May 04, 2021 @ 15:36
    Amir Ahmed
    0

    Ok thanks. I'll give that a try.

Please Sign in or register to post replies

Write your reply to:

Draft