Developer forum

Forum » Dynamicweb 9.0 Upgrade issues » Where did Group.Item go?

Where did Group.Item go?

Imar Spaanjaars Dynamicweb Employee
Imar Spaanjaars
Reply

Hi there,

In Dynamicweb 8.x we had Dynamicweb.Modules.UserManagement.Group.Item. However, the Item property is no longer present on Dynamicweb.Security.UserManagement.Group in Dynamicweb 9. I can see the ItemType and ItemId properties, but not an Item. Is that an omission or is there an alternative way to get the data?

Thanks!


Replies

 
Nicolai Pedersen
Reply
This post has been marked as an answer

Hi Imar

In Dynamicweb 9, the Groups and Users are placed in the Dynamicweb.Security.dll which is one of the lower level application services seperated from the Dynamicweb.dll where the items resides. Therefore the Dynamicweb.Security.dll does not have a reference to Dynamicweb where the items are located and cannot return things from there. This is an architectual issue. Of course Item should be of a lower level abstraction with the actual implementation higher in the stack (i.e. an IItem interface). But it is not...

So for now, do this:

Dynamicweb.Content.Items.ItemManager.Storage.GetById(type, id)

So that is how you need to do it for now.

BR Nicolai

Votes for this answer: 2

 

You must be logged in to post in the forum