显示ng-repeat之外的值

时间:2013-12-10 12:05:57

标签: angularjs angularjs-ng-repeat

我想在{{Brand.BrandDetails.Text}}之外只显示一次ng-repeat ..我怎么能这样做(重复也想要)。

<li ng-repeat="Brand in Brands">
      <a href="#">
          <img src="~/Images/{{Brand.BrandDetails.Image}}" class="topBrandsBrandContentImage">
          <p class="darkGray fontsize13 fontWeightLight">{{Brand.BrandDetails.Presentage}}% {{Brand.BrandDetails.Text}}</p>
      </a>
</li>

1 个答案:

答案 0 :(得分:1)

{{ Brands[0].BrandDetails.Text }}
<li ng-repeat="Brand in Brands">
      <a href="#">
          <img src="~/Images/{{Brand.BrandDetails.Image}}" class="topBrandsBrandContentImage">
          <p class="darkGray fontsize13 fontWeightLight">{{Brand.BrandDetails.Presentage}}% {{Brand.BrandDetails.Text}}</p>
      </a>
</li>