|
@@ -1,32 +1,20 @@
|
|
|
<template>
|
|
|
<view class="ezy-study-page">
|
|
|
- <!-- <view class="study-school-year">一年级上</view>
|
|
|
+ <view class="study-school-year">一年级上</view>
|
|
|
<view class="ezy-study-wrap">
|
|
|
- <view class="chapter-box"></view>
|
|
|
- <view class="chapter-title-box"></view>
|
|
|
- <view class="brand"></view>
|
|
|
- </view> -->
|
|
|
- <view @click="goBack">{{gradeTerm.text}}</view>
|
|
|
- <view>
|
|
|
- <view v-for="item in data.list" :key="item.index" @click="listClick"> {{item.index}} {{item.label}} </view>
|
|
|
- </view>
|
|
|
- <view>
|
|
|
- <uni-button @click="handleCheckCatalogue">go catalogue</uni-button>
|
|
|
- <uni-button @click="goKaoshi">goKaoshi</uni-button>
|
|
|
- <navigator :url="`/pages/study/catalogue?gradeId=1&termId=1&text=一年级上册`" hover-class="navigator-hover">
|
|
|
- <button type="default">学习计划</button>
|
|
|
- </navigator>
|
|
|
- <navigator url="/pages/unitTest/index" hover-class="navigator-hover">
|
|
|
- <button type="default">成长</button>
|
|
|
- </navigator>
|
|
|
- <navigator url="navigate/navigate?title=navigate" hover-class="navigator-hover">
|
|
|
- <button type="default">伙伴</button>
|
|
|
- </navigator>
|
|
|
- <navigator url="navigate/navigate?title=navigate" hover-class="navigator-hover">
|
|
|
- <button type="default">我的</button>
|
|
|
- </navigator>
|
|
|
- </view>
|
|
|
-
|
|
|
+ <view class="chapter-box" @click="handleCheckCatalogue">
|
|
|
+ 第二章
|
|
|
+ </view>
|
|
|
+ <view class="chapter-title-box">
|
|
|
+ 小标题
|
|
|
+ </view>
|
|
|
+ <view class="brand" v-for="(item,index) in infoData.jieList" :key="index" @click="listClick(item)">aaaaaaaa</view>
|
|
|
+ </view>
|
|
|
+
|
|
|
+ <!-- <uni-button style="margin-top: 200px;display: block;" @click="goKaoshi">goKaoshi</uni-button>
|
|
|
+ -->
|
|
|
+ <!-- <uni-button @click="handleCheckCatalogue">go catalogue</uni-button>
|
|
|
+ <uni-button @click="goKaoshi">goKaoshi</uni-button>
|
|
|
<!-- 蛋 -->
|
|
|
<egg-dialog ref="eggDialogRef" @eggBtn="eggBtn"></egg-dialog>
|
|
|
|
|
@@ -36,7 +24,12 @@
|
|
|
</view>
|
|
|
</template>
|
|
|
|
|
|
-<script setup>
|
|
|
+<script setup>
|
|
|
+ import {
|
|
|
+ userZhangFirstInfo,
|
|
|
+ userZhangInfo,
|
|
|
+ userLocate
|
|
|
+ } from "@/api/learnPlan.js"
|
|
|
import {
|
|
|
reactive,
|
|
|
ref,
|
|
@@ -52,39 +45,49 @@
|
|
|
|
|
|
const catalogueRef = ref(null);
|
|
|
const gradeTerm = ref('');
|
|
|
- const selectZhang = ref(null);
|
|
|
+ const selectZhang = ref(null);
|
|
|
+ let infoData = reactive({
|
|
|
+ jieList: [],
|
|
|
+ haveFlag:'',
|
|
|
+ nianji:'',
|
|
|
+ number:'',
|
|
|
+ xueqi:'',
|
|
|
+ zhangId:'',
|
|
|
+ zhangName:'',
|
|
|
+ });
|
|
|
// 来自单元测试的路由参数缓存
|
|
|
const routeParams = ref(null);
|
|
|
|
|
|
- onLoad((options) => {
|
|
|
+ onLoad((options) => {
|
|
|
+ console.log(options)
|
|
|
// 获取路由参数
|
|
|
- routeParams.value = options;
|
|
|
- // 赋值 ?
|
|
|
- gradeTerm.value = options;
|
|
|
+ routeParams.value = options;
|
|
|
+ // 选择年级进入调用此接口
|
|
|
+ if(options.flag =='selectGrades'){
|
|
|
+ getZhangFirst()
|
|
|
+ }else{
|
|
|
+
|
|
|
+ }
|
|
|
// 蛋
|
|
|
// eggDialogRef.value.eggShow();
|
|
|
})
|
|
|
-
|
|
|
- const data = reactive({
|
|
|
- list: [{
|
|
|
- label: '长度中的隐含条件问题',
|
|
|
- id: 1,
|
|
|
- },
|
|
|
- {
|
|
|
- label: '解决重叠问题',
|
|
|
- id: 2,
|
|
|
- },
|
|
|
- {
|
|
|
- label: '列表法解决方案问题',
|
|
|
- id: 3,
|
|
|
- },
|
|
|
- {
|
|
|
- label: '真题测试',
|
|
|
- id: 4,
|
|
|
- },
|
|
|
- ]
|
|
|
- })
|
|
|
-
|
|
|
+ function getZhangFirst(){
|
|
|
+ let req = {
|
|
|
+ nianji: routeParams.value.nianji,
|
|
|
+ xueqi: routeParams.value.xueqi,
|
|
|
+
|
|
|
+ }
|
|
|
+ userZhangFirstInfo(req).then(res => {
|
|
|
+ infoData.jieList = res.data.jieList
|
|
|
+ infoData.haveFlag = res.data.haveFlag
|
|
|
+ infoData.nianji = res.data.nianji
|
|
|
+ infoData.number = res.data.number
|
|
|
+ infoData.xueqi = res.data.xueqi
|
|
|
+ infoData.zhangId = res.data.zhangId
|
|
|
+ infoData.zhangName = res.data.zhangName
|
|
|
+ console.log(infoData)
|
|
|
+ })
|
|
|
+ }
|
|
|
function handleChangeZhang(data) {
|
|
|
console.log("章", data);
|
|
|
selectZhang.value = data;
|
|
@@ -99,9 +102,52 @@
|
|
|
})
|
|
|
}
|
|
|
|
|
|
- function listClick(data) {
|
|
|
+ function listClick(data) {
|
|
|
+
|
|
|
+
|
|
|
+ const pageData = {
|
|
|
+ // videoId:data.videoId,
|
|
|
+ videoId:'b997f16cb9cb474cb93526cff77d8801',
|
|
|
+ progressMarkers: [{
|
|
|
+ offset: 30,
|
|
|
+ isCustomized: true,
|
|
|
+ coverUrl: 'https://alivc-demo-vod.aliyuncs.com/image/cover/9A3F562E595E4764AD1DD546FA52C6E5-6-2.png',
|
|
|
+ title: 'test title',
|
|
|
+ describe: 'test string',
|
|
|
+ }, {
|
|
|
+ offset: 150,
|
|
|
+ isCustomized: true,
|
|
|
+ coverUrl: 'https://alivc-demo-vod.aliyuncs.com/image/cover/1E7F402241CD4C0F94AD2BBB5CCC3EC7-6-2.png',
|
|
|
+ title: 'test title',
|
|
|
+ describe: 'test string',
|
|
|
+ }, {
|
|
|
+ offset: 250,
|
|
|
+ isCustomized: true,
|
|
|
+ coverUrl: 'https://alivc-demo-vod.aliyuncs.com/image/cover/553AEA01161342C8A2B1756E83B69B5B-6-2.png',
|
|
|
+ title: 'test title',
|
|
|
+ describe: 'test string',
|
|
|
+ }, {
|
|
|
+ offset: 550,
|
|
|
+ isCustomized: true,
|
|
|
+ coverUrl: 'https://alivc-demo-vod.aliyuncs.com/image/cover/553AEA01161342C8A2B1756E83B69B5B-6-2.png',
|
|
|
+ title: 'test title',
|
|
|
+ describe: 'test string',
|
|
|
+ }, {
|
|
|
+ offset: 320,
|
|
|
+ isCustomized: true,
|
|
|
+ coverUrl: 'https://alivc-demo-vod.aliyuncs.com/image/cover/553AEA01161342C8A2B1756E83B69B5B-6-2.png',
|
|
|
+ title: 'test title',
|
|
|
+ describe: 'test string',
|
|
|
+ }, {
|
|
|
+ offset: 650,
|
|
|
+ isCustomized: true,
|
|
|
+ coverUrl: 'https://alivc-demo-vod.aliyuncs.com/image/cover/553AEA01161342C8A2B1756E83B69B5B-6-2.png',
|
|
|
+ title: 'test title',
|
|
|
+ describe: 'test string',
|
|
|
+ }],
|
|
|
+ }
|
|
|
uni.navigateTo({
|
|
|
- url: '/pages/study/lookShipin'
|
|
|
+ url: '/pages/study/lookShipin?studyData='+JSON.stringify(pageData)
|
|
|
})
|
|
|
}
|
|
|
|