Authored by yyq

品牌简介node处理

... ... @@ -417,12 +417,18 @@ const setBrandIntro = brand => {
let barndIntro = {};
if (brand) {
let text = _.replace(brand.brandIntro, /<\/?[^>]*>|\s*|(\n)|(\t)|(\r)/g, ''),
more = `... <a href="/product/shop/${brand.brandDomain}?brandIntro=true" class="blue">了解更多>></a>`;
barndIntro = {
brand: {
titleEn: 'BRAND',
titleCn: '品牌介绍',
logo: brand.brandIco,
intro: brand.brandIntro
intro: _.truncate(text, {
length: 300,
omission: more
})
}
};
}
... ...
... ... @@ -265,8 +265,7 @@
}
.intro-text {
max-height: 100px;
overflow: hidden;
line-height: 2;
}
}
... ...