Authored by xuhongyun

build

@@ -38,12 +38,14 @@ webpackJsonp([14],[ @@ -38,12 +38,14 @@ webpackJsonp([14],[
38 render: function(item) { 38 render: function(item) {
39 console.log(item); 39 console.log(item);
40 if (item.brands instanceof Array && item.brands.length > 0) { 40 if (item.brands instanceof Array && item.brands.length > 0) {
41 - var html = ''; 41 + var brandArr = [];
42 $.each(item.brands, function(i, value) { 42 $.each(item.brands, function(i, value) {
43 - html += value.brandName + '<br>'; 43 + if($.inArray(value.brandName, brandArr) === -1) {
  44 + brandArr.push(value.brandName);
  45 + }
44 }); 46 });
45 47
46 - return html; 48 + return '<p>' + brandArr.join('</p><p>') + '</p>';
47 } else { 49 } else {
48 return ''; 50 return '';
49 } 51 }