Commit bc68eba6 authored by 罗超's avatar 罗超

1

parent d2e7fc56
...@@ -73,6 +73,14 @@ ...@@ -73,6 +73,14 @@
"navigationStyle": "custom" "navigationStyle": "custom"
} }
}] }]
},
{
"root": "pages/learningGarden", //学习园地
"pages": [{
"path": "learningGardenList" //学习园地列表
}, {
"path": "learningGardenDetails" //学习园地详情
}]
} }
], ],
"tabBar": { "tabBar": {
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
</van-nav-bar> </van-nav-bar>
<view class="examScoreMain"> <view class="examScoreMain">
<view class="exam_Progress"> <view class="exam_Progress">
<van-circle <!-- <van-circle
:value="dataList.TotalScore" :value="dataList.TotalScore"
:rate="dataList.Publish.ExamScore" :rate="dataList.Publish.ExamScore"
:speed="100" :speed="100"
...@@ -34,7 +34,17 @@ ...@@ -34,7 +34,17 @@
<template> <template>
<view class="score">{{ dataList.TotalScore }}</view> <view class="score">{{ dataList.TotalScore }}</view>
</template> </template>
</van-circle> </van-circle> -->
<image
src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Static/educationStu/Dashboard.png"
style="width: 360rpx; position: absolute; top: 10px; left: 11px"
mode="widthFix"
/>
<canvas
style="width: 400rpx; height: 400rpx"
canvas-id="firstCanvas"
id="firstCanvas"
></canvas>
</view> </view>
<view> <view>
<img <img
...@@ -118,6 +128,26 @@ export default { ...@@ -118,6 +128,26 @@ export default {
data.dataList.ExamStatus, data.dataList.ExamStatus,
}); });
}, },
initCanvas(score, comment, tatalScore) {
let end = (score / tatalScore) * (2.25 - 0.75) + 0.75;
console.log(133, end);
let ctx = uni.createCanvasContext("firstCanvas");
ctx.beginPath();
console.log(130, ctx);
ctx.arc(110, 110, 95, 0.75 * Math.PI, end * Math.PI);
ctx.lineWidth = 7;
ctx.lineCap = "round";
ctx.textAlign = "center";
ctx.strokeStyle = "#fff";
ctx.font = "50px bold Arial";
ctx.fillStyle = "#fff";
ctx.fillText(score, 110, 110);
ctx.font = "20px Arial";
ctx.fillStyle = "#FFF";
ctx.fillText(comment, 110, 150);
ctx.stroke();
ctx.draw();
},
}; };
return { return {
...toRefs(data), ...toRefs(data),
...@@ -138,6 +168,7 @@ export default { ...@@ -138,6 +168,7 @@ export default {
this.Exam_Student_Id = options.Exam_Student_Id; this.Exam_Student_Id = options.Exam_Student_Id;
} }
this.getPaperDetail(); this.getPaperDetail();
this.initCanvas(100, "再接再厉", 100);
}, },
}; };
</script> </script>
......
...@@ -54,18 +54,19 @@ ...@@ -54,18 +54,19 @@
<van-image width="58rpx" height="66rpx" fit="cover" :src="item.img" /> <van-image width="58rpx" height="66rpx" fit="cover" :src="item.img" />
</view> </view>
</view> </view>
<!-- <view class="LearningGarden flex flex_wrap"> <view class="LearningGarden flex flex_wrap">
<view <view
v-for="(item, index) in learnList" v-for="(item, index) in learnList"
:key="index" :key="index"
class="LearningGarden-item" class="LearningGarden-item"
:style="{ backgroundColor: item.bgcolor }" :style="{ backgroundColor: item.bgcolor }"
@click="jumpPage(item.jumpUrl)"
> >
<view class="LearningGarden-item-name">{{ item.name }}</view> <view class="LearningGarden-item-name">{{ item.name }}</view>
<view class="LearningGarden-item-desc">{{ item.desc }}</view> <view class="LearningGarden-item-desc">{{ item.desc }}</view>
<image :src="item.img" class="LearningGarden-item-img" /> <image :src="item.img" class="LearningGarden-item-img" />
</view> </view>
</view> --> </view>
<view class="timetable"> <view class="timetable">
<view class="timetable_item flex flex_between_center"> <view class="timetable_item flex flex_between_center">
<text class="timetable_title">我的课表</text> <text class="timetable_title">我的课表</text>
...@@ -246,12 +247,14 @@ export default { ...@@ -246,12 +247,14 @@ export default {
desc: "日本語の勉強", desc: "日本語の勉強",
bgcolor: "#F6E5FE", bgcolor: "#F6E5FE",
img: "https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Static/educationStu/garden1.png", img: "https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Static/educationStu/garden1.png",
jumpUrl: "/pages/learningGarden/learningGardenList",
}, },
{ {
name: "韩语学习园地", name: "韩语学习园地",
desc: "정원", desc: "정원",
bgcolor: "#FEF5D6", bgcolor: "#FEF5D6",
img: "https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Static/educationStu/garden2.png", img: "https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Static/educationStu/garden2.png",
jumpUrl: "/pages/exam/examScore",
}, },
], ],
}); });
...@@ -292,7 +295,7 @@ export default { ...@@ -292,7 +295,7 @@ export default {
`/pages/exam/examPaper?GuestId=${item.GuestId}&&PaperId=${item.PaperId}&&Id=${item.Id}&&Exam_Student_Id=${item.Exam_Student_Id}&&ExamStatus=${item.ExamStatus}` `/pages/exam/examPaper?GuestId=${item.GuestId}&&PaperId=${item.PaperId}&&Id=${item.Id}&&Exam_Student_Id=${item.Exam_Student_Id}&&ExamStatus=${item.ExamStatus}`
); );
} }
} },
}; };
onMounted(() => { onMounted(() => {
...@@ -313,7 +316,7 @@ export default { ...@@ -313,7 +316,7 @@ export default {
}; };
}, },
onShow() { onShow() {
this.getIndexdata(); this.getIndexdata();
}, },
onLoad() { onLoad() {
uni.setNavigationBarTitle({ uni.setNavigationBarTitle({
......
<template>
<view class="">
<van-toast id="van-toast" />
</view>
</template>
<script>
import { reactive, toRefs, getCurrentInstance, onMounted } from "vue";
export default {
setup(props, context) {
let data = reactive({
Account: "",
Password: "",
});
let methods = {
back() {
uni.navigateBack();
},
jumpPage() {
uni.reLaunch({
url: "/pages/index/index",
});
},
};
onMounted(() => {});
let that = methods;
return {
...toRefs(data),
...methods,
};
},
};
</script>
<style scoped>
</style>
<template>
<view class="">
<van-toast id="van-toast" />
<view class="dataList">
<view
v-for="(item, index) in dataList"
:key="index"
class="dataList-item"
>
<view class="left"> </view>
<view class="right one_line">
<view>{{ item.title }}</view>
<view>{{ item.desc }}</view>
</view>
</view>
</view>
</view>
</template>
<script>
import { reactive, toRefs, getCurrentInstance, onMounted } from "vue";
export default {
setup(props, context) {
let data = reactive({
pageTitle: "学习园地",
dataList: [
{
img: "",
title: "日语学习园地的课程名称",
desc: "课程的一些小简介课程的一些小简介课...",
},
],
});
let methods = {
back() {
uni.navigateBack();
},
jumpPage() {
uni.reLaunch({
url: "/pages/index/index",
});
},
};
onMounted(() => {});
let that = methods;
return {
...toRefs(data),
...methods,
};
},
onLoad() {
uni.setNavigationBarTitle({
title: "日语学习园地",
});
},
};
</script>
<style scoped>
.dataList-item {
}
</style>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment