123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263 |
- <template>
- <view class="common_contant" :style="{padding: isBig ? '' : '24rpx'}">
- <tui-skeleton
- v-if="skeletonShow"
- backgroundColor="#fafafa"
- borderRadius="10rpx"
- :isLoading="true"
- :loadingType="5"
- ></tui-skeleton>
- <view class="" v-else>
- <view class="img_big" v-if="isBig">
- <image src="" mode="aspectFill"></image>
- </view>
- <view class="special_all" v-else>
- <SpecialItem v-for='item in 3' :key="item"/>
- </view>
- </view>
- </view>
- </template>
- <script>
- import SpecialItem from './components/special.vue'
- export default {
- components: {
- SpecialItem
- },
- data() {
- return {
- isBig: false,
- skeletonShow: true,
- specialList: [], // 活动数据
- }
- },
- mounted() {},
- onLoad(options) {
- this.network().SpecialService(options)
- },
- methods: {
- // 网络请求
- network() {
- return {
- SpecialService: async (options) => {
- try {
- const data = await this.SpecialService.specialInfo(options)
- if (data.code === 0) {
- this.specialList = data.data
- this.skeletonShow = false
- }
- } catch(e) {
- }
- }
- }
- }
- }
- }
- </script>
- <style scoped lang="scss">
- .common_contant {
- background-color: #FFFFFF;
- padding: 24rpx;
- }
- </style>
|