1,wxml代码
<block wx:for="{{dedBlock}}" wx:key="key" wx:for-index="groupindex">
<view class="ded-list">
<text class="ded-name">{{item.names}}</text>
<block wx:for="{{item.list}}" wx:for-item="cell" wx:for-index="cellIndex">
<navigator class="ded-navi" hover-class="none">
<text class="ded-name2">{{cell.name}}</text>
<text class="ded-time">{{cell.time}}</text>
<view style="clear:both;"></view>
</navigator>
</block>
</view>
</block>
2,js代码
data:{
dedBlock:[
{
"names":"汽车感知系统 激光雷达",
"list":[
{
name: "激光雷达相关情报01",
time: "2019-01-01"
},
{
name: "激光雷达相关情报02",
time: "2019-01-01"
},
]
},
{
"names": "Quanergey",
"list": [
{
name: "Quanergey相关情报",
time: "2019-01-02"
},
]
},
{
"names": "奇瑞汽车",
"list": [
{
name: "奇瑞汽车相关情报01",
time: "2019-01-03"
},
]
},
]
}
3,展示结果