ContentLifecycleStatus on a Product - Ecommerce - Ecommerce - Progress Community

ContentLifecycleStatus on a Product

 Ecommerce

ContentLifecycleStatus on a Product

  • ContentLifecycleStatus on a Product
  • Hi,

    For as far as I know the following code should be run without problems?

    var manager = CatalogManager.GetManager();
                this.rptProductSlider.DataSource = manager.GetProducts().Where(p=>p.Status == ContentLifecycleStatus.Live).ToList();
                this.rptProductSlider.DataBind();

    I'm getting the following exception:
    "Identifier 'Status' is not a parameter or variable or field of 'Telerik.Sitefinity.Ecommerce.Catalog.Model.Product'. If 'Status' is a property please add the FieldAlias or Storage attribute to it or declare it as a field's alias."

    The problem is that I'm return product images, but I have multiple records. Every image is returned twice. Or should I do this check only on the ProductImage property?

    Regards,
    Daniel
  • Sorry, something wrong with my code. The method 'GetProducts()' returns the right count of products.