Authored by Tao

add news && newsDetail none Data

... ... @@ -7,7 +7,6 @@
<div class="news-list-name">{{ item.content }}</div>
<div class="news-list-time">{{ item.createTime }}</div>
</LayoutLink>
</li>
</ul>
</div>
... ...
... ... @@ -7,8 +7,9 @@
@pulling-up="onPullingUp"
:data="newsList.list">
<div class="news-content">
<Tab :list="newsList.tabList"></Tab>
<List :list="newsList && newsList.list || []"></List>
<Tab v-if="newsList.tabList.length > 0" :list="newsList.tabList"></Tab>
<List v-if="newsList.list.length > 0" :list="newsList && newsList.list || []"></List>
<UfoNoItem v-else :tip="`暂无数据`"></UfoNoItem>
</div>
</Scroll>
</div>
... ... @@ -18,6 +19,7 @@
<script>
import { Style, Scroll } from 'cube-ui';
import { createNamespacedHelpers } from 'vuex';
import UfoNoItem from '../../../components/ufo-no-item';
import List from './components/list';
import Tab from './components/tab';
... ... @@ -28,9 +30,9 @@ export default {
data() {
return {
options: {
bounce: {
top: false
},
// bounce: {
// top: false
// },
pullUpLoad: true
},
msg: '消息',
... ... @@ -66,7 +68,8 @@ export default {
Style,
Scroll,
List,
Tab
Tab,
UfoNoItem
}
};
</script>
... ...
... ... @@ -8,7 +8,8 @@
:data="newsDeatilList.list">
<div class="news-content">
<Title :title="title"></Title>
<List :list="newsDeatilList && newsDeatilList.list || []" :isTitle="false"></List>
<List v-if="newsDeatilList.list.length > 0" :list="newsDeatilList && newsDeatilList.list || []" :isTitle="false"></List>
<UfoNoItem v-else :tip="`暂无数据`"></UfoNoItem>
</div>
</Scroll>
</div>
... ... @@ -18,6 +19,7 @@
<script>
import { Style, Scroll } from 'cube-ui'
import { createNamespacedHelpers } from 'vuex';
import UfoNoItem from '../../../components/ufo-no-item';
import Title from './components/title';
import List from './components/list';
const { mapState, mapActions } = createNamespacedHelpers('home/news');
... ... @@ -26,9 +28,9 @@ export default {
data() {
return {
options: {
bounce: {
top: false
},
// bounce: {
// top: false
// },
pullUpLoad: true
},
title: '',
... ... @@ -68,6 +70,7 @@ export default {
Scroll,
Title,
List,
UfoNoItem
}
};
</script>
... ...