Table of Contents

Class ProductGroupFieldValueCollection

Namespace
Dynamicweb.Ecommerce.Products
Assembly
Dynamicweb.Ecommerce.dll

Represents collection of ProductGroupFieldValue objects.

[Serializable]
public class ProductGroupFieldValueCollection : Collection<ProductGroupFieldValue>, IList<ProductGroupFieldValue>, ICollection<ProductGroupFieldValue>, IReadOnlyList<ProductGroupFieldValue>, IReadOnlyCollection<ProductGroupFieldValue>, IEnumerable<ProductGroupFieldValue>, IList, ICollection, IEnumerable
Inheritance
ProductGroupFieldValueCollection
Implements
Inherited Members
Extension Methods

Examples

using Dynamicweb.Ecommerce.Products;

namespace Dynamicweb.Ecommerce.Examples.Products
{
    public class ProductGroupCustomFieldsRendererSample
    {
        public void RenderProductGroupCustomFields(ProductGroupFieldValueCollection productGroupFieldValues)
        {
            var values = new ProductFieldValueCollection();

            foreach (var value in productGroupFieldValues)
            {
                var field = new ProductField();
                var fieldValue = new ProductFieldValue(field, value.Value)
                {
                    ProductField =
                    {
                        Types = value.ProductGroupField.Types,
                        TemplateName = value.ProductGroupField.TemplateName,
                        SystemName = value.ProductGroupField.SystemName
                    },
                    Value = value.Value
                };


                values.Add(fieldValue);
            }

            if (values.Count > 0)
            {
                //TODO: insert your code here
            }
        }
    }
}

Constructors

ProductGroupFieldValueCollection()

Initializes a new instance of the ProductGroupFieldValueCollection class.

public ProductGroupFieldValueCollection()

ProductGroupFieldValueCollection(IDataReader)

Initializes a new instance of the ProductGroupFieldValueCollection class.

public ProductGroupFieldValueCollection(IDataReader dataReader)

Parameters

dataReader IDataReader

DataReader.

Methods

GetProductGroupFieldValue(string)

Gets the ProductGroupFieldValue.

public ProductGroupFieldValue GetProductGroupFieldValue(string systemName)

Parameters

systemName string

System name.

Returns

ProductGroupFieldValue

Save(DataRow)

Saves the specified data row.

public void Save(DataRow dataRow)

Parameters

dataRow DataRow

DataRow.

To top