修改样式:课程目标>课程标题

master
significative 7 months ago
parent d948aaca3d
commit 3f9738733b
  1. 156
      teaching_integration_platform_admin_template/src/views/configurationPage/index.vue
  2. 37
      teaching_integration_platform_template/src/views/course/index.vue
  3. 4
      teaching_integration_platform_template/src/views/knowledge/index.vue
  4. 75
      teaching_integration_platform_template/src/views/roadbedRecommendation/components/mountNode.vue

@ -1,96 +1,100 @@
<template> <template>
<div class="configuration-page"> <div class="configuration-page">
<el-form :model="form" label-width="auto" style="max-width: 600px"> <el-form :model="form" label-width="auto" style="max-width: 600px">
<el-form-item label="LOGO"> <el-form-item label="LOGO">
<my-update v-model="form.logo"></my-update> <my-update v-model="form.logo"></my-update>
</el-form-item> </el-form-item>
<el-form-item label="项目名称"> <el-form-item label="项目名称">
<el-input v-model="form.name" /> <el-input v-model="form.name" />
</el-form-item> </el-form-item>
<el-form-item label="门户头部宣传大图"> <el-form-item label="门户头部宣传大图">
<my-update v-model="form.promotionalImages"></my-update> <my-update v-model="form.promotionalImages"></my-update>
</el-form-item> </el-form-item>
<el-form-item label="门户首页"> <el-form-item label="门户首页">
<el-input v-model="form.home" /> <el-input v-model="form.home" />
</el-form-item> </el-form-item>
<el-form-item label="后台登陆首页地址"> <el-form-item label="后台登陆首页地址">
<el-input v-model="form.loginAddress" /> <el-input v-model="form.loginAddress" />
</el-form-item> </el-form-item>
<el-form-item label="系统标题"> <el-form-item label="系统标题">
<el-input v-model="form.title" /> <el-input v-model="form.title" />
</el-form-item> </el-form-item>
<el-form-item label="版权信息"> <el-form-item label="版权信息">
<el-input v-model="form.copyrightInformation" /> <el-input v-model="form.copyrightInformation" />
</el-form-item> </el-form-item>
<el-form-item label="备案号"> <el-form-item label="备案号">
<el-input v-model="form.recordNumber" /> <el-input v-model="form.recordNumber" />
</el-form-item> </el-form-item>
<el-form-item label="备案号信息"> <el-form-item label="备案号信息">
<el-input v-model="form.recordInformation" type="textarea" /> <el-input v-model="form.recordInformation" type="textarea" />
</el-form-item> </el-form-item>
<el-form-item label="qq"> <el-form-item label="qq">
<el-input v-model="form.qqNumber" /> <el-input v-model="form.qqNumber" />
</el-form-item> </el-form-item>
<el-form-item label="邮箱"> <el-form-item label="邮箱">
<el-input v-model="form.mailbox" /> <el-input v-model="form.mailbox" />
</el-form-item> </el-form-item>
<el-form-item label="电话"> <el-form-item label="电话">
<el-input v-model="form.phone" /> <el-input v-model="form.phone" />
</el-form-item> </el-form-item>
<el-form-item label="联系地址"> <el-form-item label="联系地址">
<el-input v-model="form.address" /> <el-input v-model="form.address" />
</el-form-item> </el-form-item>
<el-form-item label="二维码"> <el-form-item label="二维码">
<my-update v-model="form.qrCode"></my-update> <my-update v-model="form.qrCode"></my-update>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button type="primary" @click="onSubmit">保存</el-button> <el-button type="primary" @click="onSubmit">保存</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
</div> </div>
</template> </template>
<script lang="ts" setup> <script lang="ts" setup>
import { getSysSettingApi, proxPutSysSettingApi, uploadApi } from '@/api/configuration'; import {
getSysSettingApi,
proxPutSysSettingApi,
uploadApi,
} from '@/api/configuration'
import { ref, reactive } from 'vue' import { ref, reactive } from 'vue'
import MyUpdate from './MyUpdate.vue'; import MyUpdate from './MyUpdate.vue'
import useUserStore from '@/store/modules/user'; import useUserStore from '@/store/modules/user'
const userStore = useUserStore() const userStore = useUserStore()
// do not use same name with ref // do not use same name with ref
const form = reactive({ const form = reactive({
address: '', address: '',
copyrightInformation: '', copyrightInformation: '',
id: userStore.data.id, id: userStore.data.id,
loginAddress: '', loginAddress: '',
logo: '', logo: '',
name: '', name: '',
phone: '', phone: '',
promotionalImages: '', promotionalImages: '',
qqNumber: '', qqNumber: '',
qrCode: '', qrCode: '',
recordNumber: '', recordNumber: '',
title: '', title: '',
mailbox: '', mailbox: '',
home: '', home: '',
recordInformation: '' recordInformation: '',
}) })
const ran = ref(false) const ran = ref(false)
getSysSettingApi().then((res) => { getSysSettingApi().then((res) => {
Object.assign(form, res.data) Object.assign(form, res.data)
ran.value = true ran.value = true
}) })
const onSubmit = async () => { const onSubmit = async () => {
form.logo = await uploadApi(form.logo) form.logo = await uploadApi(form.logo)
form.promotionalImages = await uploadApi(form.promotionalImages) form.promotionalImages = await uploadApi(form.promotionalImages)
form.qrCode = await uploadApi(form.qrCode) form.qrCode = await uploadApi(form.qrCode)
await proxPutSysSettingApi(form) await proxPutSysSettingApi(form)
} }
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.configuration-page { .configuration-page {
width: 600px; width: 600px;
margin: auto; margin: auto;
} }
</style> </style>

@ -92,7 +92,9 @@
</div> </div>
<div class="description"> <div class="description">
<div class="description-box"> <div class="description-box">
{{ Route.query.name }}这个课程的简介{{ learn.description }} <!-- 课程简介 -->
<div class="title">{{ Route.query.name }}</div>
<div style="text-indent: 2em;">{{ learn.description }}</div>
<!-- Vues 设计与实现这本书的简介 Vues 设计与实现是一本深入剖析 <!-- Vues 设计与实现这本书的简介 Vues 设计与实现是一本深入剖析
Vues 框架核心原理的权威著作 Vues 框架核心原理的权威著作
本书首先会为读者搭建起一个坚实的知识基础详细介绍 Vues 本书首先会为读者搭建起一个坚实的知识基础详细介绍 Vues
@ -568,12 +570,39 @@ getCourseObjectivesListEvent()
overflow-y: auto; overflow-y: auto;
height: 260px; height: 260px;
padding: 10px 20px; padding: 10px 20px;
text-indent: 2em; // text-indent: 2em;
/* 2em 约等于两个汉字的宽度 */ /* 2em 约等于两个汉字的宽度 */
font-size: 18px; font-size: 18px;
line-height: 40px; line-height: 40px;
position: relative;
.description-box {}
.description-box {
.title {
border-radius: 16px;
border: 1px solid #e8e9fb;
box-shadow: 0 0 10px #e8e9fb;
text-align: center;
color: #12a3f5;
width: fit-content;
min-width: 80px;
padding: 0 10px;
position: relative;
left: 50%;
translate: -50%;
margin-bottom: 6px;
&:before {
content: "";
width: 300%;
height: 2px;
background: #e8e9fb;
position: absolute;
bottom: -6px;
left: 50%;
translate: -50%;
background: linear-gradient(to right, rgba(255, 255, 255, 0) ,#e8e9fb,rgba(255, 255, 255, 0));
}
}
}
} }
.hours { .hours {

@ -1,5 +1,5 @@
<template> <template>
<div class="title">xxx知识点 <div class="title">{{ Route.query.title }}
<div class="back" @click="router.go(-1)">返回</div> <div class="back" @click="router.go(-1)">返回</div>
</div> </div>
<div class="container" v-if="loading"> <div class="container" v-if="loading">
@ -99,7 +99,7 @@ import VueOfficeDocx from '@vue-office/docx'
const Route = useRoute() const Route = useRoute()
const router = useRouter() const router = useRouter()
// const courseId: string = Route.query.id as string // const courseId: string = Route.query.id as string
console.log(Route.query.id) // console.log(Route.query.id)
const loading = ref(false) const loading = ref(false)
const activeName = ref<string>('1') const activeName = ref<string>('1')

@ -8,7 +8,7 @@ import { getCoursePath } from '@/api/course'
import { useRouter } from 'vue-router' import { useRouter } from 'vue-router'
import { proxrequest } from '@/api/configuration'; import { proxrequest } from '@/api/configuration';
const Router = useRouter() const Router = useRouter()
const props = defineProps(['corseId']); const props = defineProps(['corseId','options']);
const nodeList = ref({ nodes: [], edges: [] }) const nodeList = ref({ nodes: [], edges: [] })
watch(() => props.corseId, () => getCoursePathEvent()); watch(() => props.corseId, () => getCoursePathEvent());
let prOpt: any; let prOpt: any;
@ -36,7 +36,39 @@ const getCoursePathEvent = async () => {
console.log(nodeList.value) console.log(nodeList.value)
init() init()
} }
var graph:any;
onMounted(()=>{
graph = new G6.Graph({
container: 'mountNode',
width: window.innerWidth - 19,
height: 600,
layout: {
type: 'dagre',
rankdir: 'LR',
nodesep: 30,
ranksep: 100,
},
modes: {
default: ['drag-canvas'],
},
defaultNode: {
shape: 'round-rect',
labelCfg: {
style: {
fill: '#000000A6',
fontSize: 10,
},
},
style: {
stroke: '#72CC4A',
width: 150,
},
},
defaultEdge: {
shape: 'polyline',
},
})
})
const init = () => { const init = () => {
var colorMap = { var colorMap = {
凭证开立: '#72CC4A', 凭证开立: '#72CC4A',
@ -46,6 +78,8 @@ const init = () => {
第二阶段: '#1A91FF', 第二阶段: '#1A91FF',
第三阶段: '#FFAA15', 第三阶段: '#FFAA15',
} }
// #region
// var data = { // var data = {
// nodes: [ // nodes: [
// { // {
@ -186,6 +220,7 @@ const init = () => {
// }, // },
// ], // ],
// } // }
// #endregion
G6.registerNode( G6.registerNode(
'round-rect', 'round-rect',
@ -357,46 +392,14 @@ const init = () => {
}, },
}) })
var graph = new G6.Graph({
container: 'mountNode',
width: window.innerWidth - 19,
height: 600,
layout: {
type: 'dagre',
rankdir: 'LR',
nodesep: 30,
ranksep: 100,
},
modes: {
default: ['drag-canvas'],
},
defaultNode: {
shape: 'round-rect',
labelCfg: {
style: {
fill: '#000000A6',
fontSize: 10,
},
},
style: {
stroke: '#72CC4A',
width: 150,
},
},
defaultEdge: {
shape: 'polyline',
},
})
graph.data(nodeList.value) graph.data(nodeList.value)
graph.render() graph.render()
graph.on('node:click', ev => { graph.on('node:click', ev => {
console.log(ev.item._cfg.id); console.log(ev, ev.item._cfg.id);
Router.push({ Router.push({
path: '/knowledge', path: '/knowledge',
query: { id: ev.item._cfg.id } query: { id: ev.item._cfg.id,title:ev.item._cfg.model.label }
}) })
}); });
var edges = graph.getEdges() var edges = graph.getEdges()
edges.forEach(function (edge: any) { edges.forEach(function (edge: any) {

Loading…
Cancel
Save