12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697 |
- <template>
- <view class="container">
- <!-- 返回按钮 -->
- <back text="详情列表"></back>
- <view style="margin: 20rpx;">
- <u-skeleton :rows="detailList.length" :rowsHeight="height" :loading="loading">
- </u-skeleton>
- </view>
- <view class="detail-box" v-if="!loading">
- <view class="detail-item" v-for="(item,index) in detailList" :key="index" @click="navSingleData(item)">
- <view class="flex" style="width: 100%;height: 90rpx;">
- <view class="flex" style="margin: -30rpx 0 0 10rpx;">
- <view class="index"
- :style="{backgroundColor: item.examInfo.progress === 'finish'? '#23b46c': '#4169E1' }">
- </view>
- <view class="name">{{item.examInfo.name}}</view>
- </view>
- <view
- :class="item.examInfo.progress === 'finish'?'t-icon t-icon-yiwancheng1':'t-icon t-icon-jinhangzhong'"
- style="margin-left: auto; width: 90rpx; height: 90rpx;"></view>
- </view>
- <!-- 正文 -->
- <view class="content-box">
- <view style="display:flex;flex-direction: column;padding: 0 30rpx;">
- <view class="flex" style="margin-bottom: 15rpx;">
- <view class="block-tag-box">
- <view class="block-tag">{{item.examInfo.subjects[0].name}}</view>
- </view>
- <view class="block-tag-box" style="margin-left: 20rpx;">
- <view class="block-tag">{{item.examInfo.examType.name}}</view>
- </view>
- </view>
- <view class="flex">
- <view class="subtitle">布置老师:</view>
- <view class="subtitle-info" style="margin-left: 10rpx;">{{item.examInfo.creatorId}}</view>
- <view class="subtitle" style="margin-left: 20rpx;">截止时间:</view>
- <view class="subtitle-info" style="margin-left: 10rpx;">
- {{$timestampToTime(item.examInfo.endTime)}}</view>
- </view>
- </view>
- <view class="content-detail-box">
- <view class="title-box" :style="{backgroundColor: item.examInfo.progress === 'finish'? '#23b46c': '#4169E1' }">
- <view class="content-subtitle">{{item.examInfo.papers[0].name}}</view>
- </view>
- <view class="content-detail"></view>
- </view>
- </view>
- </view>
- </view>
- </view>
- </template>
- <script>
- import {
- mapState,
- mapMutations
- } from 'vuex'
- export default {
- computed: {
- ...mapState('m_children', ['detailList'])
- },
- data() {
- return {
- //骨架页配置
- loading: true,
- height: ['200px', '200px', '200px', '200px', '200px', '200px', '200px', '200px', '200px', '200px'],
- };
- },
- onLoad(options) {
- uni.$u.sleep(1500).then(() => {
- this.loading = false
- })
- },
- methods: {
- ...mapMutations('m_children', ['updateDetail']),
- //导航到详情页面
- navSingleData(item){
- this.updateDetail(item)
- uni.navigateTo({
- url: `/subpkg/detail/exam`
- })
- },
-
- }
- }
- </script>
- <style lang="scss">
- @import '@/subpkg/common/detaillistpage.scss';
- </style>
|