Try our conversational search powered by Generative AI!

Where did AssociationTypeDefinition go, and why!?

Vote:
 

A while back, we had the following code in our solution:

var associationTypeRepository = context.Locate.Advanced.GetInstance>();

associationTypeRepository.Add(new AssociationGroupDefinition()() { Name = Constants.AssociationTypes.RecommendedProducts });
associationTypeRepository.Add(new AssociationGroupDefinition()() { Name = Constants.AssociationTypes.Accessory });

...which added associationTypes to product relations. When importing a bunch of products, these were used. Also, we created stuff manually to set them. Worked fine.

Then, a few versions ago, this class (AssociationGroupDefinition) was marked as obsolete with the message "This is no longer in use.". No explanation to what, where, why and how to proceed. Nothing is explained in documentation as far as I and Google can find out either.

Changed to "RelationGroupDefinition", wich kindof seems to work, but on new products/variants now I only get "Default" in the dropdown list. On products that have one of the two others already, I can still choose between them.

http://world.episerver.com/Documentation/Items/Developers-Guide/EPiServer-Commerce/75/Catalogs/Product-associations-relations/ <= this article says ">You can define association keys in Commerce Manager." in one of the code examples. But where? I can't find it, at least...

This is limiting our client in his getting-ready for launch, and with only two weeks left and plenty to do, this is the last kind of bug we need. When doing such changes, mark classes as Obsolete with the second parameter set to true so we cant avoid it, and tell us how to replace things in the obsolete-message.

...so now what?

#91379
Oct 03, 2014 14:17
Vote:
 

..and when I ask for associationTypeRepository.List() I do get all three (Default + RecommendedProduct+ Accessory) back. So they are obviously stored. But it doesn't seem like the editing GUI gets it's values from the right place...

#91382
Oct 03, 2014 14:31
Vote:
 

Allright, I found where: When editing a product => Associations => Add an association => save the product.

That adds the new Association group to that specific product's choice of relation types, but only to that one product - essentially making it a completely useless option.

#91384
Oct 03, 2014 15:12
Vote:
 

Hi,

I'm sorry to say the change related to what you're seeing (AssociationGroupDefinition marked as obsoleted, etc ...) was from a bad bug fix, which we decided to revert and introduced a better one.

The fix is now under testing and should be released after 8.0 release.

Regards.

/Q

#91402
Oct 03, 2014 17:47
Vote:
 

Soooeh...when will that be? We're two weeks away from launching a new site now, and this is something that is in use. And will be needed for new product creations these last remaining days...

#91436
Oct 05, 2014 20:05
Vote:
 

The bug itself is fixed, and will be under testing after we release 8.0 (which should happen very soon!). I would expect it to be released in two weeks.

For your site, it's less than optiomal but you might use Commerce Manager for the association edit in the meantime.

Regards.

/Q

#91440
Oct 06, 2014 3:54
Vote:
 

I have installed Commerce 8 now - what are the new APIs I need to use to add my AssociationGroupTypes?

#91502
Oct 07, 2014 18:28
Vote:
 

As I mentioned, we'll release a proper bug fix after Commerce 8 - which should be 8.0.1 (under testing right now).

This fix will bring back AssociationGroupDefinition which proper behavior in Catalog UI.

Regards.

/Q

#91513
Oct 08, 2014 5:13
Vote:
 

Ah, allright.

#91519
Oct 08, 2014 8:26
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.