Support

Home Forums Event Espresso Premium Deleted events not correctly calculating in cart

Deleted events not correctly calculating in cart

Posted: June 5, 2023 at 10:54 am

Viewing 10 reply threads


drkings1

June 5, 2023 at 10:54 am

Hi there,

I’m in the process of upgrading my website, and upgrading Event Espresso to version 5.

An error has arisen whereby when 3 events are added to the cart and a discount code added, when those events are then deleted the cart fails to show a zero balance.

You can see the error on the staging version of the website:

https://staging4.presencetraining.co.uk/courses/

If you add Foundation 1, Foundation 2 and the Club and then use the code FOUN1X2X1 this all works fine, but then if you delete these events from the cart it shows a balance of about £500, when it should show a balance of zero.

This doesn’t happen on the current live version of the site:

https://presencetraining.co.uk/courses/

When this procedure is applied the balance on the cart returns to zero as one would expect.

Is it possible that these errors have been caused by an upgrade of EE from 4.10.13 to EE 5.0.6?

Also, when adding an event to the cart, the confirmation message showing is “0 items have been successfully added for this event”, instead of (say) “1 items have been successfully added for this event”.

Could this bug also be caused by the upgrade?

As you may (or may not) be aware, I do have developers working on upgrading the user interface on the site, and it’s possible that they have caused one or both of these errors. But I’d like to eliminate the possibility of bugs in the new Event Espresso code before blaming them and telling them to fix these errors!

(They tell me that they are no longer altering the core code of EE, as they previously were, and have included all changes to the site via custom CSS and a custom plugin).

If there is any guidance you can give me to pass to my developers, I would be very grateful.

Thank you

Daniel


drkings1

June 6, 2023 at 4:00 am

Update: It seems that this error of failure to delete items properly from the total balance to pay is occurring even when there is a single item in the cart.

I put one item in the cart (on the staging site) for £750 inc VAT and then deleted it.

The cart is now showing:

Your cart is empty.

But the total is still showing £750 (instead of 0).


Tony

  • Support Staff

June 6, 2023 at 7:40 am

Hi Daniel,

An error has arisen whereby when 3 events are added to the cart and a discount code added, when those events are then deleted the cart fails to show a zero balance.

I have confirmed this and created a ticket for our developers to investigate.

Also, when adding an event to the cart, the confirmation message showing is “0 items have been successfully added for this event”, instead of (say) “1 items have been successfully added for this event”.

Could this bug also be caused by the upgrade?

That usually happens when the Ticket Selector template has been modified and now doesn’t match the format expected within Event Espresso.

The first thin I notice on your staging site is your using an older version of the Multi Event Registration add-on (MER for short), your site has 2.0.18.p and the latest version is 2.0.20.p

I’m not getting any issues with v2.0.20.p on my test sites so I’d recommend trying to update to the lastest version of MER first to confirm.

As you may (or may not) be aware, I do have developers working on upgrading the user interface on the site, and it’s possible that they have caused one or both of these errors. But I’d like to eliminate the possibility of bugs in the new Event Espresso code before blaming them and telling them to fix these errors!

(They tell me that they are no longer altering the core code of EE, as they previously were, and have included all changes to the site via custom CSS and a custom plugin).

The line item issue, isn’t from custom code.

The “0 items have been successfully added for this event” issue, likely is.


drkings1

June 6, 2023 at 7:45 am

Hi Tony,

I shall pass these comments and your suggestion to upgrade MER to the latest version.

Just for clarity (you may have already understood this), that when the message comes up “0 items have been successfully added for this event” the items are still added to the cart, but the feedback message is incorrect.

Was that your understanding as to the error we were experiencing?


drkings1

June 6, 2023 at 7:54 am

Also just for clarity, the issue with deleting items from the cart but the balance remaining seems to be occurring regardless of whether or not a discount code is used. And it seems to be coming up even when there was only 1 event in the cart.


drkings1

June 6, 2023 at 8:00 am

And please do let me know what the developers say especially on the line item issue.


Tony

  • Support Staff

June 6, 2023 at 8:03 am

Just for clarity (you may have already understood this), that when the message comes up “0 items have been successfully added for this event” the items are still added to the cart, but the feedback message is incorrect.

Yes, so that happens when we have field within the ticket selector using one format, update the template to use another and then if your using a custom template and don’t port those changes over the cart doesn’t know what Qty passed is as the format changed.

Are the developers loading a custom ticket selector template? (Not the pricing template from previous)

Also just for clarity, the issue with deleting items from the cart but the balance remaining seems to be occurring regardless of whether or not a discount code is used. And it seems to be coming up even when there was only 1 event in the cart.

Yeah, right now I suspect its just a call to update the cart total has changed and needs to be update to match. If you use the clear event cart button the total updates and if you add another ticket after removing another it fixes the total.

We’ll do some more digging into this.


drkings1

June 6, 2023 at 8:05 am

Thank you.

Let me know what you find!


drkings1

June 7, 2023 at 5:36 am

Hi Tony,

I’ve upgraded the MER plugin and this has fixed the 0 items added to cart issue.

And yes, with regard to this line item issue, I found (as you suggested) that updating the cart total or adding another event does indeed show the correct total.

My developers have run some tests on this line item issue and they have confirmed that this is an issue that is coming out of EE 5.0.6 and not from their code.

They say:

We have checked and found that current version of plugin is causing the issue.

We have role back to the old version [4.10.13] of plugin and not found any issues which you have mentioned.

We have updated the plugin to 5.0.6 and comment our code and check it and found the same issues.

Also, we have updated the plugin to latest version and still facing the same issue.

Am I correct in thinking that you have identified this as an issue and have passed it to your development team to look into?

Thanks

Daniel


Tony

  • Support Staff

June 7, 2023 at 6:17 am

I’ve upgraded the MER plugin and this has fixed the 0 items added to cart issue.

Awesome, MER just needed to update to work with the latest Ticket Selector format then.

Easy fix 🙂

Am I correct in thinking that you have identified this as an issue and have passed it to your development team to look into?

Yes, that’s correct, this is something within core that we ticket to investigate further.


drkings1

June 7, 2023 at 7:09 am

Great Tony! Please keep me posted as to what you discover.

Viewing 10 reply threads

The support post ‘Deleted events not correctly calculating in cart’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso