ms.brands

This widget provides the brands of the product for a particular website. 


Attributes

page_sizeThis attribute is used to define the page size i.e the number of records that you want to show on a single page.
sortfieldsThis attribute is used to sort the record on the basis of any field. Example: ms-data-sortfields='name'
resolveThis attribute is used to resolve the data from a particular entity from the field whose typeof is select.

Variables

brandsReturns an array containing all the brands in the store. Each brand contains a series of details such as name, alias and etc.

Examples

Display all brands

<div ms-widget="ms.brands">
    <div ng-if="brands.length">
        <h3 ng-repeat="brand in brands">
            <a ng-href="/brand/{{brand.alias}}" title="{{brand.name}}">
                {{brand.name}}
            </a>
        </h3>
    </div>
    <div ng-if="!brands.length">
        <p>No brand exist!</p>
    </div>
</div>