<template> <view> <status-container titlet="我的课程" returnc="#FFFFFF"> <view slot="content" style="margin-top: -20rpx;"> <view class="pad-zy30 bacf pad-x30"> <view class="pad-sx30 disac fon24 bbot" v-for="(item,index) in dataList" :key="index"> <image class="flexs" :src="item.imgsrc" mode="aspectFill" style="width: 228rpx;height: 160rpx;"></image> <view class="disjbac fc width100 mar-z20" style="height: 160rpx;"> <view class="fon26 col26 width100"> <view class="clips2">{{item.title}}</view> <view class="fon20 mar-s10" style="color: #7f7f7f;">{{item.time}}</view> </view> <view class="disjbac width100"> <view class="fon24">¥{{item.price}}</view> <view class="disjcac fon22 radius26" style="width: 144rpx;height: 52rpx;color: #f37717;border: 2rpx solid #f37717;">点击学习</view> </view> </view> </view> </view> <view class="pad-zy20"> <pitera textStr="上滑加载更多/到底了~~" textColor="#b0aaa9" paddingStr="40rpx 0 20rpx 0"></pitera> </view> </view> </status-container> </view> </template> <script> import swiperTab from '@/components/swiper-tab/swiper-tab.vue'; import pitera from '@/components/nothing/pitera.vue'; export default { components:{ swiperTab, pitera }, data() { return { dataList:[ {imgsrc:'https://s6.jpg.cm/2022/02/14/L4oDhy.jpg',title:'思通造化随通而行为术基础动作教学思通造化随通而行为术基础动作教学',time:'2022.07.20 12:12:12',price:'199.00'}, {imgsrc:'https://s6.jpg.cm/2022/02/14/L4oDhy.jpg',title:'思通造化随通而行为术基础动作教学思通造化随通而行为术基础动作教学',time:'2022.07.20 12:12:12',price:'199.00'}, {imgsrc:'https://s6.jpg.cm/2022/02/14/L4oDhy.jpg',title:'思通造化随通而行为术基础动作教学思通造化随通而行为术基础动作教学',time:'2022.07.20 12:12:12',price:'199.00'}, {imgsrc:'https://s6.jpg.cm/2022/02/14/L4oDhy.jpg',title:'思通造化随通而行为术基础动作教学思通造化随通而行为术基础动作教学',time:'2022.07.20 12:12:12',price:'199.00'}, ] } }, onShow() { // 获取课程列表 this.getCouresList(); }, methods: { // 获取课程列表 getCouresList(){ uni.showLoading({ title:'加载中' }); this.$requst.get('/api/spu/course').then(res=>{ console.log(res,'课程列表') if(res.code==0) { this.userInfo = res.data; } uni.hideLoading(); this.isLoading = true; }) }, } } </script> <style> .used-item{ border-top: 2rpx solid ; } .noshow{ transform: rotate(-90deg); transition: all .3s linear; } .isshow{ transform: rotate(90deg); transition: all .3s linear; } </style>