Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
confucius
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
罗超
confucius
Commits
e3506c0f
Commit
e3506c0f
authored
Jul 01, 2021
by
罗超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新增版章节
parent
58a79dac
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
1105 additions
and
79 deletions
+1105
-79
quasar.conf.js
quasar.conf.js
+6
-5
App.vue
src/App.vue
+4
-1
index.js
src/api/course/index.js
+72
-0
UeEditor.vue
src/components/editor/UeEditor.vue
+6
-1
chapter.vue
src/pages/course/chapter.vue
+377
-66
chapterEditor.vue
src/pages/course/chapterEditor.vue
+584
-0
course.vue
src/pages/course/course.vue
+1
-1
courseinfo.vue
src/pages/course/courseinfo.vue
+4
-4
routes.js
src/router/routes.js
+6
-1
validate.js
src/utils/validate.js
+45
-0
No files found.
quasar.conf.js
View file @
e3506c0f
...
...
@@ -32,13 +32,12 @@ module.exports = function (ctx) {
// https://github.com/quasarframework/quasar/tree/dev/extras
extras
:
[
// 'ionicons-v4',
//
'mdi-v5',
'mdi-v5'
,
// 'fontawesome-v5',
// 'eva-icons',
// 'themify',
// 'line-awesome',
// 'roboto-font-latin-ext', // this or either 'roboto-font', NEVER both!
'roboto-font'
,
// optional, you are not bound to it
'material-icons'
// optional, you are not bound to it
],
...
...
@@ -49,8 +48,8 @@ module.exports = function (ctx) {
env
:
ctx
.
dev
?
{
//API: 'http://192.168.1.36:8300/api'
API
:
'https://localhost:5001/api'
,
// API: 'http://192.168.20.24:8300
/api',
//
API: 'https://localhost:5001/api',
API
:
'http://192.168.20.51:8088
/api'
,
// API: 'http://testeduapi.oytour.com/api',
// API: 'http://192.168.20.9:8085/api',
// API: 'http://192.168.20.17:8017/api',
...
...
@@ -158,7 +157,9 @@ module.exports = function (ctx) {
'QRadio'
,
'QBtnGroup'
],
// directives: [],
directives
:
[
'ClosePopup'
],
// Quasar plugins
plugins
:
[
...
...
src/App.vue
View file @
e3506c0f
...
...
@@ -12,7 +12,7 @@ export default {
<
style
>
@import
url('~assets/css/font.css')
;
@import
url('//at.alicdn.com/t/font_2077629_
1jbxfhyh7ir
.css')
;
@import
url('//at.alicdn.com/t/font_2077629_
lgl3u1kdk1a
.css')
;
html
,
body
,
...
...
@@ -23,6 +23,9 @@ body,
font-family
:
-apple-system
,
BlinkMacSystemFont
,
'pingfang'
,
' Microsoft YaHei'
,
"Segoe UI"
,
Roboto
,
"Helvetica Neue"
,
Arial
,
"Noto Sans"
,
sans-serif
,
"Apple Color Emoji"
,
"Segoe UI Emoji"
,
"Segoe UI Symbol"
,
"Noto Color Emoji"
;
color
:
#3f4254
;
}
.fullscreen
{
z-index
:
99999
;
}
.q-position-engine
{
z-index
:
9999
;
}
...
...
src/api/course/index.js
View file @
e3506c0f
...
...
@@ -203,6 +203,78 @@ export function queryChapterTree(data) {
})
}
/**
* 保存课程章节
* @param {JSON参数} data
*/
export
function
saveChapter
(
data
)
{
return
request
({
url
:
"/Course/SetChapter"
,
method
:
'post'
,
data
})
}
/**
* 保存课程章节
* @param {JSON参数} data
*/
export
function
getCourseRate
(
data
)
{
return
request
({
url
:
"/Course/GetCourseRateEnumList"
,
method
:
'post'
,
data
})
}
/**
* 保存课程章节
* @param {JSON参数} data
*/
export
function
deleteChapters
(
data
)
{
return
request
({
url
:
"/Course/BatchRemoveChapter"
,
method
:
'post'
,
data
})
}
/**
* 保存课程章节
* @param {JSON参数} data
*/
export
function
setChaptersRate
(
data
)
{
return
request
({
url
:
"/Course/BatchSetChapterRate"
,
method
:
'post'
,
data
})
}
/**
* 批量更新章节编号和ID
* @param {JSON参数} data
*/
export
function
batchUpdateChapterNo
(
data
)
{
return
request
({
url
:
"/Course/SetBatchChapterNo"
,
method
:
'post'
,
data
})
}
/**
* 修改章节名称
* @param {JSON参数} data
*/
export
function
updateChapterName
(
data
)
{
return
request
({
url
:
"/Course/SetChapterName"
,
method
:
'post'
,
data
})
}
/**
* 获取课程销售端口
*/
...
...
src/components/editor/UeEditor.vue
View file @
e3506c0f
...
...
@@ -69,7 +69,8 @@
},
watch
:
{
value
(
newVal
,
oldVal
)
{
if
(
!
this
.
isInputChange
&&
newVal
)
{
console
.
log
(
"监听到变化1"
,
newVal
,
this
.
ue
.
isReady
,
this
.
isInputChange
)
if
(
!
this
.
isInputChange
)
{
if
(
this
.
ue
)
{
if
(
this
.
ue
.
isReady
!==
1
)
{
let
self
=
this
;
...
...
@@ -84,6 +85,7 @@
},
100
);
return
;
}
console
.
log
(
"监听到变化"
,
newVal
)
this
.
ue
.
setContent
(
newVal
);
}
else
{
this
.
tempContent
=
newVal
;
...
...
@@ -222,6 +224,9 @@
fileType
+
'" class="ans-insertaudio-module" module="_insertaudio">'
+
' </iframe></p>'
;
},
reloadNewValue
(){
this
.
isInputChange
=
false
},
loadUe
()
{
const
_this
=
this
;
//上传附件
...
...
src/pages/course/chapter.vue
View file @
e3506c0f
This diff is collapsed.
Click to expand it.
src/pages/course/chapterEditor.vue
0 → 100644
View file @
e3506c0f
This diff is collapsed.
Click to expand it.
src/pages/course/course.vue
View file @
e3506c0f
...
...
@@ -144,7 +144,7 @@
<q-item-label>
恢复
</q-item-label>
</q-item-section>
</q-item>
<q-item
style=
"display:none;"
clickable
v-close-popup
@
click=
"goMycourse(props.row)"
>
<q-item
clickable
v-close-popup
@
click=
"goMycourse(props.row)"
>
<q-item-section>
<q-item-label>
详情
</q-item-label>
</q-item-section>
...
...
src/pages/course/courseinfo.vue
View file @
e3506c0f
...
...
@@ -84,15 +84,15 @@
<!--
<li
:class=
"
{'checkedLi':commonIndex==1}" @click="gotoPage('question',1)">
<i
class=
"iconfont icon-tiku"
></i>
题库
</li>
-->
<li
:class=
"
{'checkedLi':commonIndex==2}" @click="gotoPage('teachplan',2)">
<
!--
<
li
:class=
"
{'checkedLi':commonIndex==2}" @click="gotoPage('teachplan',2)">
<i
style=
"font-size:20px;"
class=
"iconfont icon-PPT"
></i>
教案
</li>
</li>
-->
<li
:class=
"
{'checkedLi':commonIndex==3}" @click="gotoPage('chapter',3)">
<i
class=
"iconfont icon-icon_zhangjielianxi"
></i>
章节
</li>
<li
:class=
"
{'checkedLi':commonIndex==4}" @click="gotoPage('coursejob',4)">
<
!--
<
li
:class=
"
{'checkedLi':commonIndex==4}" @click="gotoPage('coursejob',4)">
<i
class=
"iconfont icon-icon_zhangjielianxi"
></i>
作业
</li>
</li>
-->
</ul>
</div>
</q-list>
...
...
src/router/routes.js
View file @
e3506c0f
...
...
@@ -698,6 +698,7 @@ const routes = [{
component
:
()
=>
import
(
"pages/course/chapter.vue"
)
},
{
path
:
"/course/coursejob"
,
//作业管理
component
:
()
=>
...
...
@@ -845,7 +846,11 @@ const routes = [{
title
:
'资产管理'
},
},
{
path
:
"/course/chapter-editor"
,
//章节管理
component
:
()
=>
import
(
"pages/course/chapterEditor.vue"
)
},
{
path
:
"*"
,
component
:
()
=>
...
...
src/utils/validate.js
View file @
e3506c0f
...
...
@@ -24,4 +24,49 @@ export function validateUpperCase(str) {
export
function
validatAlphabets
(
str
)
{
const
reg
=
/^
[
A-Za-z
]
+$/
return
reg
.
test
(
str
)
}
/** 比对数组是否相同 */
export
function
compareArray
(
arrA
,
arrB
)
{
let
isSame
=
true
if
(
arrA
.
length
!==
arrB
.
length
)
{
return
false
}
else
{
arrA
.
some
((
el
,
idx
)
=>
{
if
(
el
!==
arrB
[
idx
])
{
isSame
=
false
return
true
}
})
}
return
isSame
}
/** 比对对象是否相同 */
export
function
compareObject
(
objA
,
objB
,
ignoreArray
,
endLoop
)
{
let
isSame
=
true
let
isArray
=
'[object Array]'
let
isObject
=
'[object Object]'
for
(
var
key
in
objA
)
{
if
(
objB
[
key
]
!==
''
&&
!
objB
[
key
]
&&
typeof
objB
[
key
]
!==
'number'
)
{
isSame
=
false
break
}
let
type
=
Object
.
prototype
.
toString
.
call
(
objA
[
key
])
if
(
type
===
isArray
&&
ignoreArray
)
{
isSame
=
compareArray
(
objA
[
key
],
objB
[
key
])
}
else
if
(
type
===
isObject
)
{
isSame
=
compareObject
(
objA
[
key
],
objB
[
key
],
ignoreArray
)
}
else
if
(
objA
[
key
]
!==
objB
[
key
])
{
isSame
=
false
}
if
(
!
isSame
)
{
return
isSame
}
}
if
(
isSame
&&
!
endLoop
)
{
isSame
=
compareObject
(
objB
,
objA
,
ignoreArray
,
true
)
}
return
isSame
}
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment