样式优化

version/0412
wangdong 6 months ago
parent 8ab60a1bcc
commit 63bcce0dc6
  1. 6
      pages/squareDynamic/index.vue

@ -31,7 +31,7 @@
<view class="name">{{ item.goodsInfo.goods_name }}</view> <view class="name">{{ item.goodsInfo.goods_name }}</view>
<view class="price"> <view class="price">
<text>{{ item.goodsInfo.goods_price_min>0?Number(item.goodsInfo.goods_price_min):0.00 }}</text> <text>{{ item.goodsInfo.goods_price_min>0?Number(item.goodsInfo.goods_price_min):0.00 }}</text>
<text @click="toGoodsDetail(item)">加购</text> <text @click="toGoodsDetail(item)">立即购买</text>
</view> </view>
</view> </view>
</view> </view>
@ -212,14 +212,14 @@
} else { } else {
len += 10; len += 10;
} }
if (len > 714 && spliti === 0) { if (len > 710 && spliti === 0) {
spliti = i; spliti = i;
} }
} }
console.log(cont, cont.length, spliti, len); console.log(cont, cont.length, spliti, len);
return { return {
isSplit: len > 748, isSplit: len > 748,
splitStr: len > 714 ? `${cont.split('').splice(0, spliti).join('')}...` : cont, splitStr: len > 710 ? `${cont.split('').splice(0, spliti).join('')}...` : cont,
}; };
}, },
clipCont(cont) { clipCont(cont) {

Loading…
Cancel
Save