Can't Add Multiple Items with Different Options

For general questions and discussions specific to the AbleCommerce GOLD ASP.Net shopping cart software.
kwikstand
Commodore (COMO)
Commodore (COMO)
Posts: 410
Joined: Mon Feb 19, 2007 8:12 pm
Contact:

Can't Add Multiple Items with Different Options

Post by kwikstand » Tue Jul 22, 2014 7:02 am

I am currently having problems being able to add items with different option selections to the cart. For example; two pair of pants of different sizes. If a pair of pants http://www.contractors-solutions.net/br ... pants.aspx are added to the cart, then when the user tries adding another pair of a different size, it replaces the first ones. Only the most recent size selection remains in the cart. A customer alerted me to this problem and another one this morning is having problems. These are just the users I am aware of.

Does anybody have any idea why this problem would suddenly appear? I have made no changes to the website recently at all.
Contractor's Solutions
www. contractors-solutions.net

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: Can't Add Multiple Items with Different Options

Post by Katie » Tue Jul 22, 2014 10:01 am

Have you tried testing this yourself? I was able to added different sizes (same color) to the cart and they registered as separate items. I also tried different colors (same size) and that worked as well. Testing with the latest version of Firefox
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

kwikstand
Commodore (COMO)
Commodore (COMO)
Posts: 410
Joined: Mon Feb 19, 2007 8:12 pm
Contact:

Re: Can't Add Multiple Items with Different Options

Post by kwikstand » Tue Jul 22, 2014 10:09 am

Yes, I tried in two different computers, IE, Chrome and Firefox, deleted all history and cookies. Customers are having problems too. I haven't had an order with multiple items of various sizes since 7/15, except for the one I had to place manually from the admin. because the customer couldn't do it.
Contractor's Solutions
www. contractors-solutions.net

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: Can't Add Multiple Items with Different Options

Post by Katie » Tue Jul 22, 2014 10:14 am

What options are you selecting? It worked for me every time. Sometimes, it can be helpful to provide some screenshots showing the issue.
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

kwikstand
Commodore (COMO)
Commodore (COMO)
Posts: 410
Joined: Mon Feb 19, 2007 8:12 pm
Contact:

Re: Can't Add Multiple Items with Different Options

Post by kwikstand » Tue Jul 22, 2014 10:31 am

I am simply adding a pair of pants to the cart and then adding another pair of a different size. The first selection gets booted and the new selection is retained. There are no screen shots. I would need to show you a video of adding the second selection and then the cart coming up with only the last selection showing and the first one missing. I can't show a shot of the cart and then try explaining that there should be 2 selections instead of one.
Contractor's Solutions
www. contractors-solutions.net

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: Can't Add Multiple Items with Different Options

Post by Katie » Tue Jul 22, 2014 11:03 am

In my last post, I asked "What options are you selecting?"

Here is a screenshot showing that it works for me.Image
This time I used IE.
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

kwikstand
Commodore (COMO)
Commodore (COMO)
Posts: 410
Joined: Mon Feb 19, 2007 8:12 pm
Contact:

Re: Can't Add Multiple Items with Different Options

Post by kwikstand » Tue Jul 22, 2014 11:08 am

Like I said, I was "simply adding a pair of pants to the cart and then adding another pair of a different size". So it would be the size option. I see it works for you, but for some reason it doesn't work for me in any browser or computer and customers are having problems too. They were who told me of the problem. I don't understand why this is, but it is getting frustrating.
Contractor's Solutions
www. contractors-solutions.net

kwikstand
Commodore (COMO)
Commodore (COMO)
Posts: 410
Joined: Mon Feb 19, 2007 8:12 pm
Contact:

Re: Can't Add Multiple Items with Different Options

Post by kwikstand » Tue Jul 22, 2014 11:20 am

OK, I see that I CAN add different COLORS and sizes, but if I try to add another pair of the same color but a different size, it will delete the previous selection of the same color
Contractor's Solutions
www. contractors-solutions.net

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: Can't Add Multiple Items with Different Options

Post by Katie » Tue Jul 22, 2014 1:13 pm

But if I try to add another pair of the same color but a different size
I don't know what to say. You can see in my screenshot that the basket has the same color but different size.
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

User avatar
AbleMods
Master Yoda
Master Yoda
Posts: 5170
Joined: Wed Sep 26, 2007 5:47 am
Location: Fort Myers, Florida USA

Re: Can't Add Multiple Items with Different Options

Post by AbleMods » Wed Jul 23, 2014 5:17 am

kwikstand wrote:OK, I see that I CAN add different COLORS and sizes, but if I try to add another pair of the same color but a different size, it will delete the previous selection of the same color
By chance are you reaching the product page via the link in the basket AFTER you add the first pair of pants?

In other words, are you following this sequence:
Go to product page
Make choices
Add to basket
From the basket page, click product link to return to product page
Try to add second pair of pants, but it just changes existing item

The reason I ask is the product page has a "update" feature built into it now that didn't exist in Able 7.x So if you return to the product page via the basket item, Able thinks your intent is to "update" the item in your basket, not add another item.

The workaround is simply to navigate to the product via the store menus the 2nd time rather than reach the product page via the basket link. The product page will see that as a new attempt at purchase of the same item and will allow a second pair of pants.

The clue will be the Add-to-Cart button on the product page. It will either say "Add To Cart" or "Update Cart". If it says "Update Cart", it's going to edit the existing basket item.
Joe Payne
AbleCommerce Custom Programming and Modules http://www.AbleMods.com/
AbleCommerce Hosting http://www.AbleModsHosting.com/
Precise Fishing and Hunting Time Tables http://www.Solunar.com

User avatar
jmestep
AbleCommerce Angel
Posts: 8164
Joined: Sun Feb 29, 2004 8:04 pm
Location: Dayton, OH
Contact:

Re: Can't Add Multiple Items with Different Options

Post by jmestep » Wed Jul 23, 2014 5:41 am

What Joe is explaining can be confusing to a customer in some senses. It is nice to have a product in the basket and be able to change option selections without having to delete that product from the basket and start over, especially if there are a lot of options/kits/template fields that go with it. Then again, it can be a nuisance if you want to add a new one with a different configuration. I don't know if the following code has always been in Gold and I didn't notice it before or if it is new. In R8 the BuyProductDialog.ascx.cs has the following code and it looks like you can configure whether you want to add a new item or update the existing one. I don't think it was in older versions of Gold because I remember having to hack around the update feature.

Code: Select all

protected BasketItem GetBasketItem(bool alwaysCreateNew = false)
        {
...
Then in later lines of code, it applies the logic of whether to create a new item or not.
Judy Estep
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx

abradley
Lieutenant Commander (LCDR)
Lieutenant Commander (LCDR)
Posts: 101
Joined: Wed Feb 12, 2014 4:46 pm

Re: Can't Add Multiple Items with Different Options

Post by abradley » Wed Jul 23, 2014 6:12 am

The reason I ask is the product page has a "update" feature built into it now that didn't exist in Able 7.x So if you return to the product page via the basket item, Able thinks your intent is to "update" the item in your basket, not add another item.

The workaround is simply to navigate to the product via the store menus the 2nd time rather than reach the product page via the basket link. The product page will see that as a new attempt at purchase of the same item and will allow a second pair of pants.

The clue will be the Add-to-Cart button on the product page. It will either say "Add To Cart" or "Update Cart". If it says "Update Cart", it's going to edit the existing basket item.
May I suggest that maybe we should remove this "feature." Customers in general are stupid and anything that is not intuitive impedes sales. I suggest that you can only update the cart from the cart page. "Update Cart" would slip through the cracks for a lot of users so I vote lets make the product page always Add to Cart instead of Update.
Austin

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: Can't Add Multiple Items with Different Options

Post by Katie » Wed Jul 23, 2014 6:51 am

It is nice to have a product in the basket and be able to change option selections without having to delete that product from the basket and start over, especially if there are a lot of options/kits/template fields that go with it
This is why the feature was added. If you use the product link to navigate back to the product page, then the button changes from '+Add to Cart' to 'Update Cart'. If you use the Keep shopping button, then you can add the same product with different options.

Any suggestions on how we can improve the UI without removing the feature? Perhaps we can add a pop-up that requires the customer to confirm the change, and if they did not really want to update, by clicking cancel, it would bring them back to the product page so they could add the same product with different options.

If you want a quick work-around for now, then simply remove the link from the baskets.
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

User avatar
jmestep
AbleCommerce Angel
Posts: 8164
Joined: Sun Feb 29, 2004 8:04 pm
Location: Dayton, OH
Contact:

Re: Can't Add Multiple Items with Different Options

Post by jmestep » Wed Jul 23, 2014 8:50 am

Katie, I know the feature was in Able 5 Ablenet version and we had customers upgrading to Able 7 who were not happy because it was not in Able 7.
What about leaving the update button visible, but show the add to cart also? Maybe with a small explanation or additional words on the button. Like "Update Basket Item" and "Add a new item"?
That way if a customer wants to select a different configuration for a second product, they could do that and still leave the original one in the basket. If they just want to change something like quantity on the product page, they could use the update button.

I just looked at an apparel product on Amazon and if you add a dress of a particular size to the cart then click the basket item to go back to the product page, it pre-selects to the options of the one in the basket, just like Able does and you could select a different size. On the cart page, it does have a message that the quantity has been updated if that is the case. I also saw a message that showed the following info.
2014-07-23_12-35-20.jpg
Judy Estep
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: Can't Add Multiple Items with Different Options

Post by Katie » Wed Jul 23, 2014 3:20 pm

Judy,

I like the idea of another button on the product page. That way, the customer has to make a conscious choice about whether he/she is adding a new item or updating an existing one.

Anyone else have comments or thoughts about this feature??
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

User avatar
AbleMods
Master Yoda
Master Yoda
Posts: 5170
Joined: Wed Sep 26, 2007 5:47 am
Location: Fort Myers, Florida USA

Re: Can't Add Multiple Items with Different Options

Post by AbleMods » Thu Jul 24, 2014 4:09 am

Maybe another button is the way to go. But I think the whole update-versus-add feature creates more confusion than it resolves.
Joe Payne
AbleCommerce Custom Programming and Modules http://www.AbleMods.com/
AbleCommerce Hosting http://www.AbleModsHosting.com/
Precise Fishing and Hunting Time Tables http://www.Solunar.com

rmaweb
Commander (CMDR)
Commander (CMDR)
Posts: 118
Joined: Fri Sep 10, 2010 9:41 am

Re: Can't Add Multiple Items with Different Options

Post by rmaweb » Thu Jul 24, 2014 7:45 am

I like the extra button idea. I don't think it will get too crowded having "Add to Cart" "Update Basket Item" "Add to Wishlist".

This way your right, they will have to consciously select the button they want as opposed to thinking that they will be adding a new item when in fact they are updating an existing item.
Ryan A.
Scott's Bait and Tackle
http://store.scottsbt.com
Work In Progress
Able Gold R10
Bootstrap 3.3

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: Can't Add Multiple Items with Different Options

Post by Katie » Thu Jul 24, 2014 8:20 am

I tracked this feature request back to Gold R3. It's somewhat interesting...

The first request was to have a feature where the merchant could create a link that had the pre-configured options in the URL. So, for example, I want to email a customer a link to a product that had all the options and/or kit configurations pre-selected. This was requested by a long time customer and active forum user (but I won't say who). It's actually a feature that makes sense. So, when we were making the changes for this issue, it sort of morphed into a new feature where the customer would have the ability to edit the basket which is the actual problem we are discussing here. That feature was added in R4, and was something we had back in the earliest version of AC. So, as far as I know, we haven't had any complaints until now, but that doesn't mean customer's aren't confused by the update -vs- add buttons. If we add the extra button, it will be a very easy solution and I can sneak it into this next release. I will also try to get the code change and post it here.
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

abradley
Lieutenant Commander (LCDR)
Lieutenant Commander (LCDR)
Posts: 101
Joined: Wed Feb 12, 2014 4:46 pm

Re: Can't Add Multiple Items with Different Options

Post by abradley » Thu Jul 24, 2014 11:26 am

I like the second button as well! This way at least the user will realize that there is a choice to make.

Because they might not understand why there are two buttons, I also like the idea of adding a little notice to the product page explaining these choices similar to Amazon's notice. Of course this notice will only show on the product page when navigated to from the cart.
Austin

nadeem
Captain (CAPT)
Captain (CAPT)
Posts: 258
Joined: Tue Jul 31, 2012 7:23 pm

Re: Can't Add Multiple Items with Different Options

Post by nadeem » Sat Jul 26, 2014 2:35 am

To enable second button i.e. Add to Cart button, you people need to do the following updates in Website/Conlib/BuyProductDialog.ascx.cs:

Locate the following line of code inside AddToBasketButton_Click event

Code: Select all

BasketItem basketItem = GetBasketItem();
and replace with:

Code: Select all

var existingItem = GetExistingBasketItem();
bool alwaysCreateNew = false;
if (existingItem != null)
{
    string optionList = ProductVariantDataSource.GetOptionList(_ProductId, _SelectedOptionChoices, false);
    string existingOptions = existingItem.OptionList;
    string existingKits = existingItem.KitList;
    if (!string.IsNullOrEmpty(existingOptions) || !string.IsNullOrEmpty(existingKits))
    {
        alwaysCreateNew = optionList != existingOptions || AlwaysConvert.ToList(",", _SelectedKitProducts) != existingKits;
    }
    else
    {
       alwaysCreateNew = true;
    }
}
BasketItem basketItem = GetBasketItem(alwaysCreateNew);
Similarly, locate the following code inside Page_PreRender method

Code: Select all

// check if we need to initialize dialog from existing item
if (existingItem != null)
{
   AddToBasketButton.Visible = false;
   UpdateBasketButton.Visible = true;
   Quantity.Text = existingItem.Quantity.ToString();
   if (_Product.UseVariablePrice && !_Product.IsSubscription) VariablePrice.Text = existingItem.Price.ToString("F2");
}
and replace with:

Code: Select all

// check if we need to initialize dialog from existing item
if (existingItem != null)
{
   UpdateBasketButton.Visible = true;
   Quantity.Text = existingItem.Quantity.ToString();
   if (_Product.UseVariablePrice && !_Product.IsSubscription) VariablePrice.Text = existingItem.Price.ToString("F2");
}

CGrouse
Lieutenant (LT)
Lieutenant (LT)
Posts: 59
Joined: Tue Jun 10, 2008 12:44 pm

Re: Can't Add Multiple Items with Different Options

Post by CGrouse » Fri Aug 01, 2014 4:28 am

This fix did not work for me. Would really appreciate an alternative to the edit cart button. We don't even use options because we're afraid it will confuse our customers too much.

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: Can't Add Multiple Items with Different Options

Post by Katie » Fri Aug 01, 2014 8:55 am

There isn't an edit cart button. It's a link on each product in the basket which you are welcome to remove.
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

CGrouse
Lieutenant (LT)
Lieutenant (LT)
Posts: 59
Joined: Tue Jun 10, 2008 12:44 pm

Re: Can't Add Multiple Items with Different Options

Post by CGrouse » Mon Aug 04, 2014 3:28 am

I guess we're not referring to the same thing then, because I'm referring to the fact that after an item with options is added, when you return to the product page, you only have the option to edit what is in the cart. There is no add to cart button for adding new variants of the product.

User avatar
jmestep
AbleCommerce Angel
Posts: 8164
Joined: Sun Feb 29, 2004 8:04 pm
Location: Dayton, OH
Contact:

Re: Can't Add Multiple Items with Different Options

Post by jmestep » Mon Aug 04, 2014 4:05 am

Nadeem's code did work for me (R8). I put a tee shirt into the cart with size and gender options, then clicked on the product in the cart and when I was directed to the product page, both the update and add to cart buttons were showing, instead of just the update button. I selected different options and was able to add the tee shirt with those options to the cart.
Judy Estep
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx

User avatar
AbleMods
Master Yoda
Master Yoda
Posts: 5170
Joined: Wed Sep 26, 2007 5:47 am
Location: Fort Myers, Florida USA

Re: Can't Add Multiple Items with Different Options

Post by AbleMods » Tue Aug 05, 2014 6:56 am

The code provided by Nadeem will not work in older Gold installs. For Gold R5, you must make the following additional changes.

In your BuyProductDialog.ascx.cs file, locate:

Code: Select all

        protected BasketItem GetBasketItem()
and change it to:

Code: Select all

        protected BasketItem GetBasketItem(bool alwaysCreateNew = false)
further down in the GetBasketItem method, locate this code:

Code: Select all

            //CREATE THE BASKET ITEM WITH GIVEN OPTIONS
            Basket basket = AbleContext.Current.User.Basket;
            BasketItem basketItem = GetExistingBasketItem();
And replace it with this code:

Code: Select all

            //CREATE THE BASKET ITEM WITH GIVEN OPTIONS
            BasketItem basketItem = null;
            Basket basket = AbleContext.Current.User.Basket;
            if (!alwaysCreateNew)
            {
                basketItem = GetExistingBasketItem();
            }
Now the GetBasketItem method accepts and processes the optional flag for AlwaysCreateNew. Enjoy ! :D
Joe Payne
AbleCommerce Custom Programming and Modules http://www.AbleMods.com/
AbleCommerce Hosting http://www.AbleModsHosting.com/
Precise Fishing and Hunting Time Tables http://www.Solunar.com

Post Reply