Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
C
center-resource
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
EzijingWeb
center-resource
Commits
b3e669b7
提交
b3e669b7
authored
7月 01, 2022
作者:
matian
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
updates
上级
ef69fe8c
隐藏空白字符变更
内嵌
并排
正在显示
4 个修改的文件
包含
22 行增加
和
14 行删除
+22
-14
AddExamDialog.vue
...rse/create/components/stepTwoComponents/AddExamDialog.vue
+3
-1
AddLiveDialog.vue
...rse/create/components/stepTwoComponents/AddLiveDialog.vue
+3
-4
AddVideoDialog.vue
...se/create/components/stepTwoComponents/AddVideoDialog.vue
+3
-1
StepTwo.vue
src/modules/course/create/views/StepTwo.vue
+13
-8
没有找到文件。
src/modules/course/create/components/stepTwoComponents/AddExamDialog.vue
浏览文件 @
b3e669b7
...
...
@@ -143,7 +143,9 @@ const title = computed(() => {
/>
</
template
>
</AppList>
<el-button
type=
"primary"
@
click=
"handleSave"
>
保存
</el-button>
<div
class=
"btn-box"
style=
"display: flex; justify-content: center"
>
<el-button
type=
"primary"
@
click=
"handleSave"
>
保存
</el-button>
</div>
</el-drawer>
</template>
<
style
lang=
"scss"
>
...
...
src/modules/course/create/components/stepTwoComponents/AddLiveDialog.vue
浏览文件 @
b3e669b7
...
...
@@ -76,14 +76,13 @@ const loading = ref(false)
const
lecturerValue
=
ref
([])
// 所有被搜索出来的值
const
allLecturers
:
any
=
ref
([])
const
handleLiveList
=
(
query
:
string
)
=>
{
if
(
query
)
{
loading
.
value
=
true
getLiveList
({
name
:
query
}).
then
((
res
:
any
)
=>
{
loading
.
value
=
false
liveList
.
value
=
res
.
data
.
list
.
filter
((
item
:
any
)
=>
{
return
!
lecturerValue
.
value
.
find
((
id
:
string
)
=>
id
===
item
.
id
)
})
liveList
.
value
=
res
.
data
.
list
liveList
.
value
.
forEach
((
item
:
any
)
=>
{
const
findItem
=
allLecturers
.
value
.
find
((
cItem
:
any
)
=>
cItem
.
id
===
item
.
id
)
if
(
!
findItem
)
{
...
...
@@ -99,7 +98,7 @@ const handleLiveList = (query: string) => {
<
template
>
<el-dialog
:model-value=
"isShowLiveDialog"
draggable
:before-close=
"handleCancel"
width=
"30%"
title=
"添加直播"
>
<el-form
:model=
"form"
:rules=
"rules"
ref=
"ruleFormRef"
label-width=
"120px"
>
<el-form-item
props=
"
resource_id
"
label=
"直播名称:"
>
<el-form-item
props=
"
lecturerValue
"
label=
"直播名称:"
>
<el-select
v-model=
"lecturerValue"
filterable
...
...
src/modules/course/create/components/stepTwoComponents/AddVideoDialog.vue
浏览文件 @
b3e669b7
...
...
@@ -143,7 +143,9 @@ const handleSave = () => {
<el-empty
v-else
description=
"暂无数据"
/>
</
template
>
</AppList>
<el-button
type=
"primary"
@
click=
"handleSave"
>
保存
</el-button>
<div
class=
"btn-box"
style=
"display: flex; justify-content: center"
>
<el-button
type=
"primary"
@
click=
"handleSave"
>
保存
</el-button>
</div>
</el-drawer>
</template>
<
style
lang=
"scss"
>
...
...
src/modules/course/create/views/StepTwo.vue
浏览文件 @
b3e669b7
<
script
lang=
"ts"
setup
>
import
{
Plus
}
from
'@element-plus/icons-vue'
import
{
ElMessage
}
from
'element-plus'
import
AddSectionDialog
from
'../components/stepTwoComponents/AddSectionDialog.vue'
import
AddLiveDialog
from
'../components/stepTwoComponents/AddLiveDialog.vue'
import
AddVideoDialog
from
'../components/stepTwoComponents/AddVideoDialog.vue'
import
AddExamDialog
from
'../components/stepTwoComponents/AddExamDialog.vue'
import
VideoPlayDialog
from
'../components/stepTwoComponents/VideoPlayDialog.vue'
import
{
getCharacter
,
...
...
@@ -16,7 +11,15 @@ import {
dragChapterList
,
getOtherDetails
}
from
'../api'
import
AddSectionDialog
from
'../components/stepTwoComponents/AddSectionDialog.vue'
import
AddLiveDialog
from
'../components/stepTwoComponents/AddLiveDialog.vue'
import
AddVideoDialog
from
'../components/stepTwoComponents/AddVideoDialog.vue'
import
AddExamDialog
from
'../components/stepTwoComponents/AddExamDialog.vue'
import
VideoPlayDialog
from
'../components/stepTwoComponents/VideoPlayDialog.vue'
import
AddChapterDialog
from
'../components/stepTwoComponents/AddChapterDialog.vue'
const
route
=
useRoute
()
const
router
=
useRouter
()
const
isEditCourse
=
route
.
query
.
isEditCourse
as
string
const
id
=
route
.
query
.
id
as
string
const
dataSource
=
ref
([])
...
...
@@ -74,13 +77,14 @@ onMounted(() => {
})
const
handleChapterList
=
()
=>
{
getCharacter
({
course_id
:
id
,
type
:
'tree'
}).
then
((
res
:
any
)
=>
{
dataSource
.
value
=
res
.
data
[
0
].
children
dataSource
.
value
=
res
.
data
[
0
]
?
.
children
})
}
// 新增章节
const
handleAddChapter
=
()
=>
{
isShowDialog
.
value
=
true
console
.
log
(
isShowDialog
.
value
)
isEdit
.
value
=
false
}
// 页面刷新
...
...
@@ -97,7 +101,6 @@ const handleAddSection = (node: any) => {
}
//编辑章节
const
handleEdit
=
(
node
:
any
)
=>
{
console
.
log
(
node
)
chapterID
.
value
=
node
.
key
isEdit
.
value
=
true
chapterName
.
value
=
node
.
label
...
...
@@ -119,7 +122,6 @@ const handleDel = (node: any) => {
// 添加
const
handleAddDialog
=
(
node
:
any
,
item
:
any
)
=>
{
console
.
log
(
node
,
'----'
,
item
)
chapterID
.
value
=
node
.
key
chapterName
.
value
=
node
.
label
btnInfo
.
value
=
item
...
...
@@ -252,6 +254,9 @@ const handleDrop = (startNode: any, endNode: any, position: any, event: any) =>
</span>
</template>
</el-tree>
<div
class=
"btn-box"
style=
"display: flex; justify-content: center"
>
<el-button
type=
"primary"
@
click=
"router.push('/course/my')"
>
保存
</el-button>
</div>
</AppCard>
<!-- 添加章 -->
<AddChapterDialog
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论