提交 94f8b721 authored 作者: matian's avatar matian

updates

上级 700210fd
...@@ -106,7 +106,7 @@ export const menus: IMenuItem[] = [ ...@@ -106,7 +106,7 @@ export const menus: IMenuItem[] = [
path: '/admin/student' path: '/admin/student'
}, },
{ {
tag: 'v1-backend-lecturer-list', tag: 'v1-backend-specialty-list',
icon: Promotion, icon: Promotion,
name: '专业管理', name: '专业管理',
path: '/admin/pro' path: '/admin/pro'
......
...@@ -66,7 +66,7 @@ const bytesToSize = (bytes: number) => { ...@@ -66,7 +66,7 @@ const bytesToSize = (bytes: number) => {
</template> </template>
<style lang="scss" scoped> <style lang="scss" scoped>
.card-item { .card-item {
width: 265px; width: 17%;
border-radius: 6px; border-radius: 6px;
overflow: hidden; overflow: hidden;
margin-right: 20px; margin-right: 20px;
......
...@@ -51,7 +51,7 @@ if (props.url?.indexOf('.pdf') !== -1 || props.url?.indexOf('.txt') !== -1) { ...@@ -51,7 +51,7 @@ if (props.url?.indexOf('.pdf') !== -1 || props.url?.indexOf('.txt') !== -1) {
</template> </template>
<style lang="scss" scoped> <style lang="scss" scoped>
.max-w-h { .max-w-h {
max-width: 1200px; // max-width: 1200px;
width: 100%; width: 100%;
height: 500px; height: 500px;
margin: 0 auto; margin: 0 auto;
......
...@@ -8,13 +8,11 @@ export function useProjectList(id?: string, projectId?: string) { ...@@ -8,13 +8,11 @@ export function useProjectList(id?: string, projectId?: string) {
list.value = res.data.departments list.value = res.data.departments
members.value = res.data.members members.value = res.data.members
departmentList.value = res.data.departments.reduce((a: any, b: any) => { departmentList.value = res.data.departments.reduce((a: any, b: any) => {
console.log(a, b)
if (b.organizations.length) { if (b.organizations.length) {
a.push(b.organizations) a.push(b.organizations)
} }
return a.flat(Infinity) return a.flat(Infinity)
}, []) }, [])
console.log(departmentList)
}) })
return { list, members, departmentList } return { list, members, departmentList }
} }
...@@ -107,7 +107,6 @@ let loading = $ref<boolean>(false) ...@@ -107,7 +107,6 @@ let loading = $ref<boolean>(false)
function fetchDetail() { function fetchDetail() {
loading = true loading = true
getCourseDetails({ id }).then((res: any) => { getCourseDetails({ id }).then((res: any) => {
console.log(res.data)
Object.assign(form, res.data) Object.assign(form, res.data)
examList.value = res.data.examinations examList.value = res.data.examinations
form.exam_id = res.data.examinations.map((item: any) => item.id).toString() form.exam_id = res.data.examinations.map((item: any) => item.id).toString()
...@@ -175,22 +174,15 @@ function handleUpdate() { ...@@ -175,22 +174,15 @@ function handleUpdate() {
}) })
} }
// const handleMajorList = (query: string) => {
// if (query) {
getMajorList({ name: '', 'per-page': '100' }).then((res: any) => { getMajorList({ name: '', 'per-page': '100' }).then((res: any) => {
majorList.value = res.data.list.filter((item: any) => item.status === '1') majorList.value = res.data.list.filter((item: any) => item.status === '1')
majorList.value.forEach((item: any) => { majorList.value.forEach((item: any) => {
console.log(item, 'ppp')
const findItem = allMajorList.value.find((cItem: any) => cItem.id === item.id) const findItem = allMajorList.value.find((cItem: any) => cItem.id === item.id)
if (!findItem) { if (!findItem) {
allMajorList.value.push(item) allMajorList.value.push(item)
} }
}) })
}) })
// } else {
// majorList.value = []
// }
// }
</script> </script>
<template> <template>
......
...@@ -20,7 +20,7 @@ const copyCourse = () => { ...@@ -20,7 +20,7 @@ const copyCourse = () => {
<div class="card-item"> <div class="card-item">
<div class="card-item-top"> <div class="card-item-top">
<div class="title">{{ props.data.name }}</div> <div class="title">{{ props.data.name }}</div>
<div class="cover-img" :style="`background-image:url(${props.data.cover})`"></div> <div class="cover-img" :style="`background-image:url(${props.data.cover}) `"></div>
<div class="tool-pop-btn"> <div class="tool-pop-btn">
<div style="min-width: 100%"> <div style="min-width: 100%">
<router-link v-if="props.data.auth_edit" :to="`/course/update-course?id=${props.data.id}`"> <router-link v-if="props.data.auth_edit" :to="`/course/update-course?id=${props.data.id}`">
...@@ -52,7 +52,7 @@ const copyCourse = () => { ...@@ -52,7 +52,7 @@ const copyCourse = () => {
</template> </template>
<style lang="scss" scoped> <style lang="scss" scoped>
.card-item { .card-item {
width: 265px; width: 17%;
border-radius: 6px; border-radius: 6px;
overflow: hidden; overflow: hidden;
margin-right: 20px; margin-right: 20px;
......
...@@ -65,7 +65,6 @@ const videoWidth = (h: number) => { ...@@ -65,7 +65,6 @@ const videoWidth = (h: number) => {
} }
</script> </script>
<template> <template>
<el-card>
<div class="main_content"> <div class="main_content">
<div class="content_top"> <div class="content_top">
<AppVideoPlayer <AppVideoPlayer
...@@ -84,7 +83,7 @@ const videoWidth = (h: number) => { ...@@ -84,7 +83,7 @@ const videoWidth = (h: number) => {
</div> </div>
</div> </div>
<div class="content_bottom" :style="{ width: chapterWidth + 300 + 'px' }"> <div class="content_bottom" :style="{ width: chapterWidth + 300 + 'px' }">
<div style="margin-top: 20px">本小节视频资源:</div> <div style="margin: 30px 0 0 10px">本小节视频资源:</div>
<div class="cover-list"> <div class="cover-list">
<div class="cover-box"> <div class="cover-box">
<div <div
...@@ -101,7 +100,6 @@ const videoWidth = (h: number) => { ...@@ -101,7 +100,6 @@ const videoWidth = (h: number) => {
</div> </div>
</div> </div>
</div> </div>
</el-card>
</template> </template>
<style lang="scss" scoped> <style lang="scss" scoped>
.main_content { .main_content {
...@@ -110,14 +108,20 @@ const videoWidth = (h: number) => { ...@@ -110,14 +108,20 @@ const videoWidth = (h: number) => {
.content_top { .content_top {
display: flex; display: flex;
.video_con { .video_con {
width: 75%; width: 85%;
} }
} }
} }
.content_bottom { .content_bottom {
border-bottom-left-radius: 10px;
border-bottom-right-radius: 10px;
box-sizing: border-box;
border-left: 1px solid #e6e8eb;
border-right: 1px solid #e6e8eb;
border-bottom: 1px solid #e6e8eb;
padding: 10px 0 20px 20px;
.cover-list { .cover-list {
overflow-x: auto; overflow-x: auto;
.cover-box { .cover-box {
display: flex; display: flex;
justify-content: flex-start; justify-content: flex-start;
......
...@@ -279,5 +279,14 @@ const handleExamDetail = (row: any) => { ...@@ -279,5 +279,14 @@ const handleExamDetail = (row: any) => {
font-weight: 500; font-weight: 500;
color: #333333; color: #333333;
} }
.content-bottom {
margin-top: 70px;
.demo-tabs {
margin-bottom: 20px;
}
}
}
:deep(.el-tabs__content) {
margin-top: 40px;
} }
</style> </style>
<script setup lang="ts"> <script setup lang="ts">
import * as echarts from "echarts" import * as echarts from 'echarts'
const echartsRef = ref() const echartsRef = ref()
onMounted(() => { onMounted(() => {
const myEcharts = echarts.init(echartsRef.value) const myEcharts = echarts.init(echartsRef.value)
...@@ -23,7 +23,7 @@ onMounted(() => { ...@@ -23,7 +23,7 @@ onMounted(() => {
barWidth: '18', barWidth: '18',
data: [5, 20, 36, 10, 10, 20] data: [5, 20, 36, 10, 10, 20]
} }
], ]
} }
//设置配置 //设置配置
myEcharts.setOption(option) myEcharts.setOption(option)
...@@ -40,32 +40,32 @@ const listOptions = { ...@@ -40,32 +40,32 @@ const listOptions = {
duration: '120分钟', duration: '120分钟',
date: '2022-06-15', date: '2022-06-15',
name: '王重阳', name: '王重阳',
project: '资源管理系统', project: '资源管理系统'
}, },
{ {
duration: '120分钟', duration: '120分钟',
date: '2022-06-15', date: '2022-06-15',
name: '王重阳', name: '王重阳',
project: '资源管理系统', project: '资源管理系统'
}, },
{ {
duration: '120分钟', duration: '120分钟',
date: '2022-06-15', date: '2022-06-15',
name: '王重阳', name: '王重阳',
project: '资源管理系统', project: '资源管理系统'
}, },
{ {
duration: '120分钟', duration: '120分钟',
date: '2022-06-15', date: '2022-06-15',
name: '王重阳', name: '王重阳',
project: '资源管理系统', project: '资源管理系统'
} }
] ]
} }
</script> </script>
<template> <template>
<div class="data-box"> <div class="data-box">
<div class="echart"> <div class="echart">
<div class="name">访问量/关联量一周走势图</div> <div class="name">访问量/关联量一周走势图</div>
<div <div
...@@ -81,8 +81,8 @@ const listOptions = { ...@@ -81,8 +81,8 @@ const listOptions = {
<div class="name">最近访问</div> <div class="name">最近访问</div>
<AppList v-bind="listOptions" ref="appList" stripe></AppList> <AppList v-bind="listOptions" ref="appList" stripe></AppList>
</div> </div>
</div> </div>
<!-- <div <!-- <div
class="echarts" class="echarts"
ref="echartsRef" ref="echartsRef"
:style="{ :style="{
...@@ -92,31 +92,34 @@ const listOptions = { ...@@ -92,31 +92,34 @@ const listOptions = {
></div> --> ></div> -->
</template> </template>
<style lang="scss" scoped> <style lang="scss" scoped>
.data-box{ .data-box {
display: flex; display: flex;
.echart{ .echart {
width: 65%;
flex: 1; flex: 1;
height: 369px; height: 369px;
box-sizing: border-box; box-sizing: border-box;
border: 1px solid #E0E0E0; border: 1px solid #e0e0e0;
border-radius: 10px; border-radius: 10px;
margin-right: 10px; margin-right: 10px;
padding: 20px; padding: 20px;
.name{ .name {
font-size: 16px; font-size: 16px;
line-height: 100%; line-height: 100%;
color: #333333; color: #333333;
} }
} }
.label-box{ .label-box {
width: 25%;
box-sizing: border-box; box-sizing: border-box;
flex: 1; flex: 1;
height: 369px; height: 369px;
border: 1px solid #E0E0E0; border: 1px solid #e0e0e0;
border-radius: 10px; border-radius: 10px;
margin-left: 10px; margin-left: 10px;
padding: 20px; padding: 20px;
.name{ .name {
font-size: 16px; font-size: 16px;
line-height: 100%; line-height: 100%;
color: #333333; color: #333333;
......
...@@ -40,7 +40,7 @@ const props = defineProps({ ...@@ -40,7 +40,7 @@ const props = defineProps({
</div> </div>
</div> </div>
<div class="file-box"> <div class="file-box">
<PreviewFiles :url="props.data?.url"></PreviewFiles> <PreviewFiles :url="props.data?.url" ></PreviewFiles>
</div> </div>
</div> </div>
</template> </template>
...@@ -51,12 +51,11 @@ const props = defineProps({ ...@@ -51,12 +51,11 @@ const props = defineProps({
.right-statistics { .right-statistics {
// flex: 1; // flex: 1;
display: flex; display: flex;
max-width: 1200px;
justify-content: space-between; justify-content: space-between;
padding-top: 15px; padding-top: 15px;
margin: 0 auto; margin: 0 auto;
.stat-item { .stat-item {
width: 210px; width: 24%;
height: 85px; height: 85px;
background: #b41e47; background: #b41e47;
border-radius: 6px; border-radius: 6px;
......
<script setup lang="ts"> <script setup lang="ts">
import * as echarts from "echarts" import * as echarts from 'echarts'
const echartsRef = ref() const echartsRef = ref()
onMounted(() => { onMounted(() => {
const myEcharts = echarts.init(echartsRef.value) const myEcharts = echarts.init(echartsRef.value)
...@@ -23,7 +23,7 @@ onMounted(() => { ...@@ -23,7 +23,7 @@ onMounted(() => {
barWidth: '18', barWidth: '18',
data: [5, 20, 36, 10, 10, 20] data: [5, 20, 36, 10, 10, 20]
} }
], ]
} }
//设置配置 //设置配置
myEcharts.setOption(option) myEcharts.setOption(option)
...@@ -40,32 +40,32 @@ const listOptions = { ...@@ -40,32 +40,32 @@ const listOptions = {
duration: '120分钟', duration: '120分钟',
date: '2022-06-15', date: '2022-06-15',
name: '王重阳', name: '王重阳',
project: '资源管理系统', project: '资源管理系统'
}, },
{ {
duration: '120分钟', duration: '120分钟',
date: '2022-06-15', date: '2022-06-15',
name: '王重阳', name: '王重阳',
project: '资源管理系统', project: '资源管理系统'
}, },
{ {
duration: '120分钟', duration: '120分钟',
date: '2022-06-15', date: '2022-06-15',
name: '王重阳', name: '王重阳',
project: '资源管理系统', project: '资源管理系统'
}, },
{ {
duration: '120分钟', duration: '120分钟',
date: '2022-06-15', date: '2022-06-15',
name: '王重阳', name: '王重阳',
project: '资源管理系统', project: '资源管理系统'
} }
] ]
} }
</script> </script>
<template> <template>
<div class="data-box"> <div class="data-box">
<div class="echart"> <div class="echart">
<div class="name">访问量/关联量一周走势图</div> <div class="name">访问量/关联量一周走势图</div>
<div <div
...@@ -81,8 +81,8 @@ const listOptions = { ...@@ -81,8 +81,8 @@ const listOptions = {
<div class="name">最近访问</div> <div class="name">最近访问</div>
<AppList v-bind="listOptions" ref="appList" stripe></AppList> <AppList v-bind="listOptions" ref="appList" stripe></AppList>
</div> </div>
</div> </div>
<!-- <div <!-- <div
class="echarts" class="echarts"
ref="echartsRef" ref="echartsRef"
:style="{ :style="{
...@@ -92,31 +92,33 @@ const listOptions = { ...@@ -92,31 +92,33 @@ const listOptions = {
></div> --> ></div> -->
</template> </template>
<style lang="scss" scoped> <style lang="scss" scoped>
.data-box{ .data-box {
display: flex; display: flex;
.echart{ .echart {
flex: 1; flex: 1;
width: 65%;
height: 369px; height: 369px;
box-sizing: border-box; box-sizing: border-box;
border: 1px solid #E0E0E0; border: 1px solid #e0e0e0;
border-radius: 10px; border-radius: 10px;
margin-right: 10px; margin-right: 10px;
padding: 20px; padding: 20px;
.name{ .name {
font-size: 16px; font-size: 16px;
line-height: 100%; line-height: 100%;
color: #333333; color: #333333;
} }
} }
.label-box{ .label-box {
box-sizing: border-box; box-sizing: border-box;
width: 25%;
flex: 1; flex: 1;
height: 369px; height: 369px;
border: 1px solid #E0E0E0; border: 1px solid #e0e0e0;
border-radius: 10px; border-radius: 10px;
margin-left: 10px; margin-left: 10px;
padding: 20px; padding: 20px;
.name{ .name {
font-size: 16px; font-size: 16px;
line-height: 100%; line-height: 100%;
color: #333333; color: #333333;
......
...@@ -52,11 +52,11 @@ const props = defineProps({ ...@@ -52,11 +52,11 @@ const props = defineProps({
// flex: 1; // flex: 1;
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
max-width: 1200px; // max-width: 1200px;
margin: 0 auto; margin: 0 auto;
padding-top: 15px; padding-top: 15px;
.stat-item { .stat-item {
width: 210px; width: 24%;
height: 85px; height: 85px;
background: #b41e47; background: #b41e47;
border-radius: 6px; border-radius: 6px;
......
<script setup lang="ts"> <script setup lang="ts">
import * as echarts from "echarts" import * as echarts from 'echarts'
const echartsRef = ref() const echartsRef = ref()
onMounted(() => { onMounted(() => {
const myEcharts = echarts.init(echartsRef.value) const myEcharts = echarts.init(echartsRef.value)
...@@ -23,7 +23,7 @@ onMounted(() => { ...@@ -23,7 +23,7 @@ onMounted(() => {
barWidth: '18', barWidth: '18',
data: [5, 20, 36, 10, 10, 20] data: [5, 20, 36, 10, 10, 20]
} }
], ]
} }
//设置配置 //设置配置
myEcharts.setOption(option) myEcharts.setOption(option)
...@@ -40,32 +40,32 @@ const listOptions = { ...@@ -40,32 +40,32 @@ const listOptions = {
duration: '120分钟', duration: '120分钟',
date: '2022-06-15', date: '2022-06-15',
name: '王重阳', name: '王重阳',
project: '资源管理系统', project: '资源管理系统'
}, },
{ {
duration: '120分钟', duration: '120分钟',
date: '2022-06-15', date: '2022-06-15',
name: '王重阳', name: '王重阳',
project: '资源管理系统', project: '资源管理系统'
}, },
{ {
duration: '120分钟', duration: '120分钟',
date: '2022-06-15', date: '2022-06-15',
name: '王重阳', name: '王重阳',
project: '资源管理系统', project: '资源管理系统'
}, },
{ {
duration: '120分钟', duration: '120分钟',
date: '2022-06-15', date: '2022-06-15',
name: '王重阳', name: '王重阳',
project: '资源管理系统', project: '资源管理系统'
} }
] ]
} }
</script> </script>
<template> <template>
<div class="data-box"> <div class="data-box">
<div class="echart"> <div class="echart">
<div class="name">访问量/关联量一周走势图</div> <div class="name">访问量/关联量一周走势图</div>
<div <div
...@@ -81,8 +81,8 @@ const listOptions = { ...@@ -81,8 +81,8 @@ const listOptions = {
<div class="name">最近访问</div> <div class="name">最近访问</div>
<AppList v-bind="listOptions" ref="appList" stripe></AppList> <AppList v-bind="listOptions" ref="appList" stripe></AppList>
</div> </div>
</div> </div>
<!-- <div <!-- <div
class="echarts" class="echarts"
ref="echartsRef" ref="echartsRef"
:style="{ :style="{
...@@ -92,31 +92,34 @@ const listOptions = { ...@@ -92,31 +92,34 @@ const listOptions = {
></div> --> ></div> -->
</template> </template>
<style lang="scss" scoped> <style lang="scss" scoped>
.data-box{ .data-box {
display: flex; display: flex;
.echart{ .echart {
flex: 1; flex: 1;
width: 65%;
height: 369px; height: 369px;
box-sizing: border-box; box-sizing: border-box;
border: 1px solid #E0E0E0; border: 1px solid #e0e0e0;
border-radius: 10px; border-radius: 10px;
margin-right: 10px; margin-right: 10px;
padding: 20px; padding: 20px;
.name{ .name {
font-size: 16px; font-size: 16px;
line-height: 100%; line-height: 100%;
color: #333333; color: #333333;
} }
} }
.label-box{ .label-box {
box-sizing: border-box; box-sizing: border-box;
width: 25%;
flex: 1; flex: 1;
height: 369px; height: 369px;
border: 1px solid #E0E0E0; border: 1px solid #e0e0e0;
border-radius: 10px; border-radius: 10px;
margin-left: 10px; margin-left: 10px;
padding: 20px; padding: 20px;
.name{ .name {
font-size: 16px; font-size: 16px;
line-height: 100%; line-height: 100%;
color: #333333; color: #333333;
......
...@@ -52,11 +52,11 @@ const props = defineProps({ ...@@ -52,11 +52,11 @@ const props = defineProps({
// flex: 1; // flex: 1;
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
max-width: 1200px; // max-width: 1200px;
margin: 0 auto; margin: 0 auto;
padding-top: 15px; padding-top: 15px;
.stat-item { .stat-item {
width: 210px; width: 24%;
height: 85px; height: 85px;
background: #b41e47; background: #b41e47;
border-radius: 6px; border-radius: 6px;
......
...@@ -40,7 +40,7 @@ const props: any = defineProps<{ data: object; tabIndex: string }>() ...@@ -40,7 +40,7 @@ const props: any = defineProps<{ data: object; tabIndex: string }>()
</template> </template>
<style lang="scss" scoped> <style lang="scss" scoped>
.card-item { .card-item {
width: 265px; width: 17%;
border-radius: 6px; border-radius: 6px;
overflow: hidden; overflow: hidden;
margin-right: 20px; margin-right: 20px;
......
...@@ -40,25 +40,25 @@ const listOptions = { ...@@ -40,25 +40,25 @@ const listOptions = {
duration: '120分钟', duration: '120分钟',
date: '2022-06-15', date: '2022-06-15',
name: '王重阳', name: '王重阳',
project: '资源管理系统', project: '资源管理系统'
}, },
{ {
duration: '120分钟', duration: '120分钟',
date: '2022-06-15', date: '2022-06-15',
name: '王重阳', name: '王重阳',
project: '资源管理系统', project: '资源管理系统'
}, },
{ {
duration: '120分钟', duration: '120分钟',
date: '2022-06-15', date: '2022-06-15',
name: '王重阳', name: '王重阳',
project: '资源管理系统', project: '资源管理系统'
}, },
{ {
duration: '120分钟', duration: '120分钟',
date: '2022-06-15', date: '2022-06-15',
name: '王重阳', name: '王重阳',
project: '资源管理系统', project: '资源管理系统'
} }
] ]
} }
...@@ -88,6 +88,7 @@ const listOptions = { ...@@ -88,6 +88,7 @@ const listOptions = {
display: flex; display: flex;
.echart { .echart {
flex: 1; flex: 1;
width: 65%;
height: 369px; height: 369px;
box-sizing: border-box; box-sizing: border-box;
border: 1px solid #e0e0e0; border: 1px solid #e0e0e0;
...@@ -101,6 +102,7 @@ const listOptions = { ...@@ -101,6 +102,7 @@ const listOptions = {
} }
} }
.label-box { .label-box {
width: 25%;
box-sizing: border-box; box-sizing: border-box;
flex: 1; flex: 1;
height: 369px; height: 369px;
......
...@@ -2,90 +2,98 @@ ...@@ -2,90 +2,98 @@
import AppVideoPlayer from '@/components/base/AppVideoPlayer.vue' import AppVideoPlayer from '@/components/base/AppVideoPlayer.vue'
const props = defineProps(['data']) const props = defineProps(['data'])
const videoOptions = $computed(() => { const videoOptions = $computed(() => {
return { sources: [{ src: props.data.play_auth.play_info_list.find((item: any) => { return item.Definition === 'SD' }).PlayURL }] } return {
sources: [
{
src: props.data.play_auth.play_info_list.find((item: any) => {
return item.Definition === 'SD'
}).PlayURL
}
]
}
}) })
</script> </script>
<template> <template>
<div class="center-video-box"> <div class="center-video-box">
<div class="right-statistics"> <div class="right-statistics">
<div class="stat-item"> <div class="stat-item">
<img src="https://webapp-pub.oss-cn-beijing.aliyuncs.com/center_resource/view-vicon1.png"> <img src="https://webapp-pub.oss-cn-beijing.aliyuncs.com/center_resource/view-vicon1.png" />
<div class="content"> <div class="content">
<div class="unit">{{ data.project_count }}<span></span></div> <div class="unit">{{ data.project_count }}<span></span></div>
<div class="tag">使用项目/学校</div> <div class="tag">使用项目/学校</div>
</div> </div>
</div> </div>
<div class="stat-item"> <div class="stat-item">
<img src="https://webapp-pub.oss-cn-beijing.aliyuncs.com/center_resource/view-vicon2.png"> <img src="https://webapp-pub.oss-cn-beijing.aliyuncs.com/center_resource/view-vicon2.png" />
<div class="content"> <div class="content">
<div class="unit">{{ data.course_count }}<span></span></div> <div class="unit">{{ data.course_count }}<span></span></div>
<div class="tag">使用课程</div> <div class="tag">使用课程</div>
</div> </div>
</div> </div>
<div class="stat-item"> <div class="stat-item">
<img src="https://webapp-pub.oss-cn-beijing.aliyuncs.com/center_resource/view-vicon3.png"> <img src="https://webapp-pub.oss-cn-beijing.aliyuncs.com/center_resource/view-vicon3.png" />
<div class="content"> <div class="content">
<div class="unit">{{ data.learn_count }}<span>人次</span></div> <div class="unit">{{ data.learn_count }}<span>人次</span></div>
<div class="tag">累计学习人次</div> <div class="tag">累计学习人次</div>
</div> </div>
</div> </div>
<div class="stat-item"> <div class="stat-item">
<img src="https://webapp-pub.oss-cn-beijing.aliyuncs.com/center_resource/view-vicon4.png"> <img src="https://webapp-pub.oss-cn-beijing.aliyuncs.com/center_resource/view-vicon4.png" />
<div class="content"> <div class="content">
<div class="unit">{{ data.learn_time_count }}<span>分钟</span></div> <div class="unit">{{ data.learn_time_count }}<span>分钟</span></div>
<div class="tag">累计学习时长</div> <div class="tag">累计学习时长</div>
</div> </div>
</div> </div>
</div> </div>
<div style="max-width:1200px; padding-bottom: 20px; margin:0 auto;"> <div style="padding-bottom: 20px; margin: 0 auto">
<AppVideoPlayer :isAdd="true" :options="videoOptions"></AppVideoPlayer> <AppVideoPlayer :isAdd="true" :options="videoOptions"></AppVideoPlayer>
</div> </div>
</div> </div>
</template> </template>
<style lang="scss" scoped> <style lang="scss" scoped>
.center-video-box{ .center-video-box {
padding: 20px 0; padding: 20px 0;
// display: flex; // display: flex;
.right-statistics{ .right-statistics {
max-width: 1200px; // max-width: 1200px;
margin: 0 auto; margin: 0 auto;
// flex: 1; // flex: 1;
display: flex; display: flex;
padding-top: 15px; padding-top: 15px;
justify-content: space-between; justify-content: space-between;
.stat-item{ .stat-item {
width: 210px; width: 24%;
height: 85px; height: 85px;
background: #B41E47; background: #b41e47;
border-radius: 6px; border-radius: 6px;
display: flex; display: flex;
align-items: center; align-items: center;
// margin: 0 auto 20px; // margin: 0 auto 20px;
margin-bottom: 20px; margin-bottom: 20px;
&:nth-child(even){ &:nth-child(even) {
background: #BF9D6B; background: #bf9d6b;
} }
img{ img {
width: 52px; width: 52px;
height: 52px; height: 52px;
display: block; display: block;
margin-left: 18px; margin-left: 18px;
} }
.content{ .content {
margin-left: 18px; margin-left: 18px;
.unit{ .unit {
font-size: 26px; font-size: 26px;
line-height: 100%; line-height: 100%;
color: #FFFFFF; color: #ffffff;
span{ span {
font-size: 12px; font-size: 12px;
line-height: 100%; line-height: 100%;
} }
} }
.tag{ .tag {
font-size: 14px; font-size: 14px;
line-height: 100%; line-height: 100%;
color: #FFFFFF; color: #ffffff;
margin-top: 10px; margin-top: 10px;
} }
} }
......
...@@ -23,6 +23,7 @@ const listOptions = $computed(() => { ...@@ -23,6 +23,7 @@ const listOptions = $computed(() => {
if (params.class_id !== '') { if (params.class_id !== '') {
classId.value = params.class_id classId.value = params.class_id
} }
return params return params
} }
}, },
...@@ -67,24 +68,30 @@ const handleCheckPaper = (row: any) => { ...@@ -67,24 +68,30 @@ const handleCheckPaper = (row: any) => {
router.push({ path: '/teach/view', query: { eid: row.exam_id, sid: row.student_id } }) router.push({ path: '/teach/view', query: { eid: row.exam_id, sid: row.student_id } })
} }
onMounted(() => { onMounted(() => {
checkPermission('v1-teaching-paper-search-list') && handleGetSearchList() checkPermission('v1-teaching-paper-search-list') && handleGetClassList()
}) })
const handleGetSearchList = () => { // 获取学生搜索列表
const params: any = { type: 'class', search_id: classId } const handleGetStuList = () => {
const params: any = { type: 'class', search_id: classId.value }
getSearchList(params).then((res: any) => { getSearchList(params).then((res: any) => {
stuList.value = res.data stuList.value = res.data
}) })
} }
// 获取学生列表 // 获取班级搜索列表
const handleGetStuList = () => { const handleGetClassList = () => {
const params: any = { type: 'class', search_id: classId.value } const params: any = { type: 'class', search_id: route.query.course_id }
getSearchList(params).then((res: any) => { getSearchList(params).then((res: any) => {
classList.value = res.data classList.value = res.data
}) })
} }
if (classId.value !== '') { watch(
() => classId.value,
() => {
if (classId.value !== '') {
checkPermission('v1-teaching-paper-search-list') && handleGetStuList() checkPermission('v1-teaching-paper-search-list') && handleGetStuList()
} }
}
)
</script> </script>
<template> <template>
......
import httpRequest from '@/utils/axios' import httpRequest from '@/utils/axios'
// 获取大作业列表 // 获取大作业列表
export function getWorkList(params?: { course_id: string; title?: string; page?: string; page_size?: string }) { export function getWorkList(params?: {
course_id: string
title?: string
class_id?: string
page?: string
page_size?: string
}) {
return httpRequest.get('/api/resource/v1/teaching/job/list', { params }) return httpRequest.get('/api/resource/v1/teaching/job/list', { params })
} }
// 搜索条件 // 搜索条件
......
...@@ -7,18 +7,45 @@ import { getWorkList, getSearchList } from '../api' ...@@ -7,18 +7,45 @@ import { getWorkList, getSearchList } from '../api'
const appList = ref() const appList = ref()
const isShowCheckDialog = ref(false) const isShowCheckDialog = ref(false)
const id = ref('') const id = ref('')
const searchList: any = ref([]) const course_id = ref('')
const searchCourseList: any = ref([])
const searchClassList: any = ref([])
const listOptions = $computed(() => { const listOptions = $computed(() => {
return { return {
remote: { httpRequest: getWorkList, params: { course_id: '', title: '' } }, remote: {
httpRequest: getWorkList,
params: {
course_id: '',
class_id: ''
},
beforeRequest(params: any) {
if (params.course_id !== '') {
course_id.value = params.course_id
return params
}
return params
}
},
filters: [ filters: [
{ {
type: 'select', type: 'select',
prop: 'course_id', prop: 'course_id',
label: '所属课程:', label: '所属课程:',
placeholder: '所属课程', placeholder: '所属课程',
options: searchList.value, options: searchCourseList.value,
labelKey: 'name',
valueKey: 'id',
filterable: true,
remote: true
},
{
type: 'select',
prop: 'class_id',
label: '班级名称:',
placeholder: '班级名称',
options: searchClassList.value,
labelKey: 'name', labelKey: 'name',
valueKey: 'id', valueKey: 'id',
filterable: true, filterable: true,
...@@ -72,18 +99,31 @@ const handleCheckPaper = (row: any) => { ...@@ -72,18 +99,31 @@ const handleCheckPaper = (row: any) => {
isShowCheckDialog.value = true isShowCheckDialog.value = true
} }
onMounted(() => { onMounted(() => {
checkPermission('v1-teaching-job-search-list') && handleGetSearchList() checkPermission('v1-teaching-job-search-list') && handleGetSearchCourseList()
// checkPermission('v1-teaching-job-search-list') && handleGetSearchClassList()
}) })
const handleGetSearchList = () => { const handleGetSearchCourseList = () => {
getSearchList({ type: 'course', search_id: '' }).then(res => { getSearchList({ type: 'course', search_id: '' }).then(res => {
searchList.value = res.data searchCourseList.value = res.data
})
}
const handleGetSearchClassList = () => {
getSearchList({ type: 'class', search_id: course_id.value }).then(res => {
searchClassList.value = res.data
}) })
} }
const handleFresh = () => { const handleFresh = () => {
appList.value.refetch() appList.value.refetch()
} }
watch(
() => course_id.value,
() => {
if (course_id.value !== '') {
checkPermission('v1-teaching-job-search-list') && handleGetSearchClassList()
}
}
)
</script> </script>
<template> <template>
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论