You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
35 lines
1.5 KiB
35 lines
1.5 KiB
<van-cell clickable bind:click="lookItem">
|
|
<view class="flex" slot="title">
|
|
<van-image use-loading-slot width="160rpx" height="160rpx" radius="4" lazy-load src="{{item.factoryAvatarUrl}}">
|
|
<image class="image-load" slot="loading" src="/assets/image/def_image.png"></image>
|
|
</van-image>
|
|
<view style="flex:1;margin-left: 20rpx;">
|
|
<view class="flex flex-justify">
|
|
<view class="text-xl text-black text-bold">{{item.name}}</view>
|
|
<view class="text-black text-sm">{{item.distance}}km</view>
|
|
</view>
|
|
<view class="flex flex-center text-cut" style="justify-content: flex-start;">
|
|
<image style="height:24rpx;width:24rpx" src="/assets/icon/address.png"></image>
|
|
<text class="text-gray text-sm" style="margin-left: 8rpx;">{{item.locDetail}}</text>
|
|
</view>
|
|
<view class="text-df" wx:if="{{item.categoryProductionCapacityPerMonth}}">月出货量:{{item.categoryProductionCapacityPerMonth}}吨</view>
|
|
<view class="text-df" wx:if="{{item.mainCategoryList}}">出货品类:{{categoryString(item.mainCategoryList)}}</view>
|
|
<view class="text-df" wx:if="{{item.recentlyShipmentsPaperMill}}">最近出货:{{item.recentlyShipmentsPaperMill}}</view>
|
|
</view>
|
|
</view>
|
|
</van-cell>
|
|
|
|
<wxs module="categoryString">
|
|
function categoryString(mainCategoryList) {
|
|
var cate = ''
|
|
for (var index = 0; index < mainCategoryList.length; index++) {
|
|
if(index == 0){
|
|
cate = mainCategoryList[index]
|
|
} else {
|
|
cate += '、' + mainCategoryList[index]
|
|
}
|
|
}
|
|
return cate
|
|
}
|
|
module.exports = categoryString
|
|
</wxs>
|