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.
yanzong_qianduan/pages/news/rules/rulesList.vue

58 lines
1.0 KiB

10 months ago
<template>
<view class="pages">
<view class="header">
10 months ago
<u-navbar is-back="false" :title="title"></u-navbar>
10 months ago
</view>
<view class="content">
9 months ago
<view v-for="(item,index) in list" :key="index" class="item">
<view class="title" @click="goRules(item)">
{{item.title}}
</view>
<u-line v-if="item.title" />
10 months ago
</view>
10 months ago
10 months ago
</view>
</view>
</template>
<script>
10 months ago
export default {
data() {
return {
title: '',
list: [],
itemInfo: {}
10 months ago
}
},
10 months ago
onLoad(options) {
9 months ago
this.itemInfo = JSON.parse(decodeURIComponent(options.itemInfo))
console.log(this.itemInfo )
10 months ago
this.title = this.itemInfo.name
this.list = this.itemInfo.child
},
10 months ago
methods: {
goRules(item) {
10 months ago
uni.navigateTo({
9 months ago
url: '/pages/news/rules/index?itemInfo=' + encodeURIComponent(JSON.stringify(item))
10 months ago
})
}
}
}
</script>
<style scoped lang="scss">
10 months ago
.pages {
10 months ago
width: 100%;
height: 100%;
9 months ago
padding: 30rpx;
box-sizing: border-box;
10 months ago
}
10 months ago
.item {
10 months ago
margin-bottom: 28rpx;
}
10 months ago
.title {
10 months ago
margin-bottom: 28rpx;
}
</style>