Class GroupRelation
- Namespace
- Dynamicweb.Ecommerce.Products
- Assembly
- Dynamicweb.Ecommerce.dll
Class for parent-child relations between product groups
- Inheritance
-
Group
Relation
- Inherited Members
Constructors
GroupRelation()
Empty constructor
GroupRelation(IDataReader)
Create relation object with data from given DataReader
Parameters
dataReader
IDataReader DataReader with selected relation
GroupRelation(string, string)
Create groups relation using group ID and parent group ID
Parameters
Properties
Id
Group ID.
Property Value
InheritCategories
Do inherit categories.
Property Value
IsPrimary
Is this group primary.
Property Value
ParentId
Parent group ID.
Property Value
Sorting
Sort order of current group inside parent group's children collection.
Property Value
Methods
ClearCache()
Clears the relations cache.
Clone()
Create in-memory copy of current relation
Returns
- Group
Relation Copied relation
Copy()
Create a copy of current relation and save it to database
Returns
- Group
Relation Copied relation
Delete()
Delete current relation
Delete(IEnumerable<Group>)
Delete all relations for groups from given collection
Parameters
groups
IEnumerable<Group>Groups collection to delete from group relations
Returns
- Command
Builder SQL statement used to delete relations
Delete(IEnumerable<Group>, bool)
Create SQL statement to delete all relations for groups from given collection and optionally execute it
Parameters
groups
IEnumerable<Group>Groups collection to delete from group relations
run
boolExecute prepared SQL statement or not
Returns
- Command
Builder SQL statement used to delete relations
Delete(string, string)
Delete relation between given group and parent group
Parameters
GetGroupRelationsByChildId(string)
Get all group relations for given child group ID
Parameters
childId
stringChild group ID
Returns
GetGroupRelationsByParentId(string)
Get all group relations for given parent group ID
Parameters
theParentId
stringParent group ID
Returns
Save(string, string)
Save relation object
Parameters
Remarks
Fires Notifications.eCommerce.Group.RelationUpdated event