接口初始化 第一版

This commit is contained in:
yuping
2022-11-16 01:28:42 +08:00
parent c2f02a33e5
commit f9ae1c0027
27 changed files with 13054 additions and 550 deletions

View File

@@ -11,21 +11,21 @@
<!-- 基本信息 -->
<div class="bascinfo">
<div style="margin-left: 46px">
<div class="title">其他活动核心项目面授课</div>
<div class="title">其他活动{{ data.offCourseInfo?.name }}</div>
<div class="time" style="margin-top: 26px">
<img width="15px" height="17px" src="../../assets/image/time.png" />
<div style="margin-left: 8px">2022-07-20 20:00-21:00</div>
<img width="15px" height="17px" src="../../assets/image/time.png"/>
<div style="margin-left: 8px">{{ data.offCoursePlanInfo.beginTime }}</div>
</div>
<div class="time" style="margin-top: 23px">
<img
width="16px"
height="18px"
src="../../assets/image/position.png"
width="16px"
height="18px"
src="../../assets/image/position.png"
/>
<div style="margin-left: 8px">大族广场</div>
<div style="margin-left: 8px">{{ data.offCoursePlanInfo.address }}</div>
</div>
</div>
<div class="btn">评估</div>
<div class="btn" v-if="data.offCoursePlanInfo.evalFlag && !data.evalFlag">评估</div>
</div>
<!-- 基本信息 -->
@@ -36,20 +36,15 @@
<div class="" style="margin-left: 48px; margin-right: 48px">
<div class="title">
<img
width="20px"
height="20px"
src="../../assets/image/course.png"
width="20px"
height="20px"
src="../../assets/image/course.png"
/>
<div class="text">课程详情</div>
<div class="box"></div>
</div>
<div style="display: flex; align-items: center">
<div class="content">
通过对各级人员的软件平台培训使其能够了解如何运用乾元坤和智能信息管理系统来提升企业管理水平最大限度发挥软件产品在企业中的作用<br />
1.使企业不同部门人员掌握便捷有效的系统平台操作方法;<br />
2.通过系统平台的培训提高员工对企业的管理理念认识与提升<br />
3.通过系统平台培训加强沟通统一部署协同工作提高效率<br />
</div>
<div class="content" v-html="data.offCourseInfo?.intro"></div>
</div>
</div>
</div>
@@ -57,10 +52,10 @@
<el-tabs v-model="activeName" @tab-click="handleClick">
<el-tab-pane label="课程附件" name="first">
<div
v-for="(el, index) in enclosure"
:key="el.id"
class="enclosure"
:style="{
v-for="(el, index) in data.offCoursePlanInfo?.attach.split(',')"
:key="index"
class="enclosure"
:style="{
'border-bottom':
index === enclosure.length - 1
? null
@@ -69,44 +64,44 @@
>
<div class="enclosureL">
<img
style="width: 22px; height: 26px; margin-left: 10px"
:src="el.img"
style="width: 22px; height: 26px; margin-left: 10px"
:src="{pdf,word,ppt,zip,excel}[el.split('.').slice(-1)]"
/>
<div style="margin-left: 20px">{{ el.name }}</div>
<div style="margin-left: 20px">{{ el }}</div>
</div>
<div class="download">
<img
style="width: 16px; height: 15px"
src="../../assets/image/download.png"
style="width: 16px; height: 15px"
src="../../assets/image/download.png"
/>
<div style="margin-left: 5px">下载</div>
<div style="margin-left: 5px" @click="download(el)">下载</div>
</div>
</div>
</el-tab-pane>
<el-tab-pane label="课程作业" name="second">
<div class="work">
<div>
<div class="question">社交产品如何做好模块化处理</div>
<div class="question">{{data.workItem.name}}</div>
<div style="margin-top: 16px; display: flex">
<div class="tag1">必修</div>
<div class="tag3" style="margin-left: 11px">作业</div>
</div>
</div>
<div class="submit">提交</div>
<div class="submit" @click="toWork" v-if="!data.workFlag">提交</div>
</div>
</el-tab-pane>
<el-tab-pane label="课程考试" name="third">
<div class="work">
<div>
<div class="question">
模块化产品展示相关案例与展示如何自由组合你的思考
{{data.examItem.name}}
</div>
<div style="margin-top: 16px; display: flex">
<div class="tag1">必修</div>
<div class="tag3" style="margin-left: 11px">考试</div>
</div>
</div>
<div class="submit">去考试</div>
<div class="submit" @click="toExamItem" v-if="!data.examFlag">去考试</div>
</div>
</el-tab-pane>
</el-tabs>
@@ -115,24 +110,25 @@
<div class="teacher">
<div class="title">
<img
style="width: 21px; height: 23px"
src="../../assets/image/livelecturer.png"
style="width: 21px; height: 23px"
src="../../assets/image/livelecturer.png"
/>
<div class="text">直播讲师</div>
<div class="box"></div>
</div>
<!-- todo #面授课接口 讲师缺少img和介绍-->
<div
v-for="(el, index) in teacher"
:key="el.id"
class="teacheritem"
:style="{
v-for="(el, index) in teacher"
:key="el.id"
class="teacheritem"
:style="{
'border-bottom':
index === teacher.length - 1
? null
: '1px solid rgba(56, 125, 247, 0.2)',
}"
>
<img class="peopleimg" :src="el.peopleimg" />
<img class="peopleimg" :src="el.peopleimg"/>
<div style="margin-left: 17px; width: 190px">
<div class="teacherName" style="margin-right: 5px">
{{ el.name }}
@@ -148,27 +144,41 @@
</template>
<script>
import { reactive, toRefs } from "vue";
import {reactive, toRefs, watch} from "vue";
import word from '@/assets/image/file/word.png'
import ppt from '@/assets/image/file/ppt.png'
import pdf from '@/assets/image/file/pdf.png'
import zip from '@/assets/image/file/zip.png'
import md from '@/assets/image/file/md.png'
import excel from '@/assets/image/file/excel.png'
import medal1 from '@/assets/image/file/medal1.png'
import medal2 from '@/assets/image/file/medal2.png'
import medal3 from '@/assets/image/file/medal3.png'
import img from '@/assets/image/file/img.png'
import {request, useRequest} from "@/api/request";
import {STU_OFFCOURSE_DETAIL} from "@/api/api";
export default {
name: "FaceTeach",
setup() {
const {data} = useRequest(STU_OFFCOURSE_DETAIL, {})
const state = reactive({
activeName: "first",
enclosure: [
{
id: 1,
name: "项目参考文档.doc",
img: require("../../assets/image/file/word.png"),
img: word,
},
{
id: 2,
name: "人工智能启蒙讲解讲义.pptx",
img: require("../../assets/image/file/ppt.png"),
img: ppt,
},
{
id: 3,
name: "人工智能启蒙讲解讲义.xlsx",
img: require("../../assets/image/file/excel.png"),
img: excel,
},
],
teacher: [
@@ -176,43 +186,63 @@ export default {
id: 1,
name: "王星天(显示事业)",
introduce: "教师是学生的镜子,学生是老师的影子。",
peopleimg: require("../../assets/image/img.jpg"),
peopleimg: img,
medal: [
require("../../assets/image/medal/medal1.png"),
require("../../assets/image/medal/medal2.png"),
require("../../assets/image/medal/medal3.png"),
medal1,
medal2,
medal3,
],
},
{
id: 2,
name: "王星天(显示事业)",
introduce: "教师是学生的镜子,学生是老师的影子。",
peopleimg: require("../../assets/image/img.jpg"),
peopleimg: img,
medal: [
require("../../assets/image/medal/medal1.png"),
require("../../assets/image/medal/medal2.png"),
medal1,
medal2,
],
},
{
id: 3,
name: "王星天(显示事业)",
introduce:
"教师是学生的镜子,学生是老师的影子。教师是学生的镜子,学生是老师的影子。教师是学生的镜子,学生是老师的影子。教师是学生的镜子,学生是老师的影子。",
peopleimg: require("../../assets/image/img.jpg"),
"教师是学生的镜子,学生是老师的影子。教师是学生的镜子,学生是老师的影子。教师是学生的镜子,学生是老师的影子。教师是学生的镜子,学生是老师的影子。",
peopleimg: img,
medal: [
require("../../assets/image/medal/medal1.png"),
require("../../assets/image/medal/medal2.png"),
require("../../assets/image/medal/medal3.png"),
medal1,
medal2,
medal3,
],
},
],
});
workers: [],
examinations: [],
})
const handleClick = (tab, event) => {
console.log(tab, event);
};
const download=(url)=>{
window.open(url)
}
function toWork(){
}
function toExamItem(){
}
return {
...toRefs(state),
handleClick,
download,
toExamItem,
toWork,
data,
pdf,
word,
ppt,
zip,
excel,
};
},
};
@@ -227,6 +257,7 @@ export default {
font-size: 14px;
line-height: 24px;
}
.bascinfo {
width: 100%;
height: 180px;
@@ -236,6 +267,7 @@ export default {
display: flex;
justify-content: space-between;
align-items: center;
.btn {
width: 146px;
height: 46px;
@@ -252,6 +284,7 @@ export default {
cursor: pointer;
margin-right: 96px;
}
.title {
font-size: 20px;
font-weight: 800;
@@ -259,6 +292,7 @@ export default {
line-height: 24px;
margin-left: -9px;
}
.time {
font-size: 14px;
color: #6e7b84;
@@ -267,31 +301,37 @@ export default {
align-items: center;
}
}
.detailinfo {
width: 100%;
margin-top: 20px;
display: flex;
align-items: flex-start;
.detail {
flex: 1;
margin-right: 20px;
.detailT {
min-height: 263px;
background: #ffffff;
border-radius: 8px;
color: rgba(51, 51, 51, 1);
.title {
display: flex;
align-items: center;
padding-top: 39px;
position: relative;
}
.title .text {
margin-left: 8px;
font-size: 16px;
color: rgba(51, 51, 51, 1);
font-weight: 800;
}
.title .box {
width: 75px;
height: 10px;
@@ -300,6 +340,7 @@ export default {
left: 23px;
top: 53px;
}
.content {
margin-left: 8px;
font-size: 14px;
@@ -310,20 +351,24 @@ export default {
padding-bottom: 30px;
}
}
.detailB {
min-height: 363px;
background: #ffffff;
border-radius: 8px;
margin-top: 20px;
.el-tabs__item {
height: 69px;
padding: 25px 7px 0px 52px;
font-size: 14px;
font-weight: 500;
}
.el-tabs__nav-wrap::after {
background-color: rgba(56, 125, 247, 0.2);
}
.enclosure {
height: 89px;
margin-left: 51px;
@@ -332,6 +377,7 @@ export default {
display: flex;
justify-content: space-between;
align-items: center;
.enclosureL {
display: flex;
align-items: center;
@@ -340,6 +386,7 @@ export default {
color: #677d86;
line-height: 24px;
}
.download {
display: flex;
align-items: center;
@@ -350,6 +397,7 @@ export default {
cursor: pointer;
}
}
.work {
margin-left: 51px;
margin-right: 40px;
@@ -358,6 +406,7 @@ export default {
align-items: center;
margin-top: 37px;
}
.work .question {
font-size: 14px;
font-weight: 500;
@@ -382,12 +431,14 @@ export default {
}
}
}
.teacher {
width: 434px;
min-height: 500px;
// height: 10%;
background-color: rgba(255, 255, 255, 1);
border-radius: 8px;
.title {
display: flex;
align-items: center;
@@ -395,12 +446,14 @@ export default {
position: relative;
margin-left: 48px;
}
.title .text {
margin-left: 8px;
font-size: 16px;
color: rgba(51, 51, 51, 1);
font-weight: 800;
}
.title .box {
width: 75px;
height: 10px;
@@ -409,6 +462,7 @@ export default {
left: 23px;
top: 53px;
}
.teacheritem {
margin-left: 48px;
margin-right: 48px;
@@ -418,11 +472,13 @@ export default {
position: relative;
// align-items: center;
}
.teacheritem .peopleimg {
width: 60px;
height: 60px;
border-radius: 30px;
}
.teacheritem .teacherName {
font-size: 14px;
font-weight: bold;
@@ -430,12 +486,14 @@ export default {
display: flex;
align-items: center;
}
.teacheritem .introduce {
font-size: 14px;
font-weight: 500;
color: #394145;
margin-top: 14px;
}
.teacheritem .follow {
width: 80px;
height: 30px;