Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mt-education-web
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
王旭
mt-education-web
Commits
7f9a8a5b
Commit
7f9a8a5b
authored
Nov 13, 2019
by
fanlin@91isoft.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
22172 新新建页面中,没有保存过的条件下,没有发布按钮,一旦保存成功,显示出【发布】【删除】按钮
parent
5254018d
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
137 additions
and
132 deletions
+137
-132
global.less
src/components/global.less
+1
-1
ChapterCatalog.vue
src/views/courseTrain/onlineCourseNew/ChapterCatalog.vue
+62
-61
ChapterListTea.vue
src/views/courseTrain/onlineCourseNew/ChapterListTea.vue
+0
-12
EduPdf.vue
src/views/courseTrain/onlineCourseNew/components/EduPdf.vue
+73
-57
sortManage.vue
src/views/courseTrain/sortManage.vue
+1
-1
No files found.
src/components/global.less
View file @
7f9a8a5b
...
@@ -427,7 +427,7 @@ body {
...
@@ -427,7 +427,7 @@ body {
}
}
// 侧边栏高度度
// 侧边栏高度度
.ant-layout-sider.sider.light {
.ant-layout-sider.sider.light {
height:
770px
;
height:
102%
;
}
}
// 外置的样式控制
// 外置的样式控制
.user-dropdown-menu {
.user-dropdown-menu {
...
...
src/views/courseTrain/onlineCourseNew/ChapterCatalog.vue
View file @
7f9a8a5b
This diff is collapsed.
Click to expand it.
src/views/courseTrain/onlineCourseNew/ChapterListTea.vue
View file @
7f9a8a5b
<
template
>
<
template
>
<div
v-loading
.
body=
"loading"
id=
"chapterListTea"
class=
"chapterListTea"
>
<div
v-loading
.
body=
"loading"
id=
"chapterListTea"
class=
"chapterListTea"
>
<div
style=
"text-align: left"
>
<div
style=
"text-align: left"
>
<!--
<span
class=
"chapterSwitchBtn"
>
-->
<!--
<label>
-->
<!--
<el-switch
v-model=
"chapterAllSwtich"
on-text=
""
off-text=
""
on-color=
"#13ce66"
off-color=
"#707070"
@
change=
"switchAllChapter"
></el-switch>
-->
<!-- 打开全部-->
<!--
</label>
-->
<!--
</span>
-->
<a
@
click=
"addCourseChapter"
class=
"tabs-addChapter"
@
mouseover=
"blueShow"
@
mouseout=
"blueHide"
>
<a
@
click=
"addCourseChapter"
class=
"tabs-addChapter"
@
mouseover=
"blueShow"
@
mouseout=
"blueHide"
>
<img
:src=
"isShow === true ? eleUrl.url : eleUrl.no_url"
style=
"position: relative;top: -1px;"
>
添加章
</a>
<img
:src=
"isShow === true ? eleUrl.url : eleUrl.no_url"
style=
"position: relative;top: -1px;"
>
添加章
</a>
<a
@
click=
"setSectionFlag"
class=
"tabs-addSection"
@
mouseover=
"blueJShow"
@
mouseout=
"blueJHide"
>
<a
@
click=
"setSectionFlag"
class=
"tabs-addSection"
@
mouseover=
"blueJShow"
@
mouseout=
"blueJHide"
>
<img
:src=
"isJShow === true ? eleUrl.url:eleUrl.no_url"
style=
"position: relative;top: -1px;"
>
添加节
</a>
<img
:src=
"isJShow === true ? eleUrl.url:eleUrl.no_url"
style=
"position: relative;top: -1px;"
>
添加节
</a>
<span
style=
"color:#999999;margin-left: 14px;margin-top: 10px"
><img
src=
"@/assets/image/icon-question.png"
style=
"margin-right: 9px;width: 20px;height: 20px;margin-top: -4px;"
/>
一小节对应一个课时
</span>
<span
style=
"color:#999999;margin-left: 14px;margin-top: 10px"
><img
src=
"@/assets/image/icon-question.png"
style=
"margin-right: 9px;width: 20px;height: 20px;margin-top: -4px;"
/>
一小节对应一个课时
</span>
<!--
<a
@
click=
"showExportDialog"
v-show=
"isSelected==2"
class=
"tabs-addSection"
><img
src=
"../../static/images/export.png"
style=
"position: relative;top: -1px;"
>
导出作业
</a>
-->
<!--
<edu-button
btnType=
"main-btn"
btnValue=
"导出作业"
@
clicked=
"showExportDialog"
v-show=
"isSelected==2"
class=
"export"
></edu-button>
-->
<!--
<edu-button
btnType=
"main-btn"
btnValue=
"刷新"
@
clicked=
"refreshScoreList"
v-show=
"isSelected==2"
style=
"width: 106px !important;"
class=
"refurbish"
></edu-button>
-->
<!--
<edu-button
btnType=
"main-btn"
btnValue=
"刷新"
@
click=
""
v-show=
"isSelected==2"
style=
"width: 106px !important;"
class=
"refurbish"
></edu-button>
-->
<!--
<a
class=
"classContrast"
style=
"cursor: default;color:#FF0000;"
>
还差
{{
needClassHours
}}
学时与预设总学时一致
</a>
-->
<!--
<a
class=
"classContrast"
style=
"cursor: default;color: green;"
>
当前课时已满足预设总学时
</a>
-->
</div>
</div>
<!-- 添加章节 弹出框-->
<!-- 添加章节 弹出框-->
<div
class=
"addCourseWrap"
>
<div
class=
"addCourseWrap"
>
...
...
src/views/courseTrain/onlineCourseNew/components/EduPdf.vue
View file @
7f9a8a5b
<
template
>
<
template
>
<div
class=
"pdf-container"
>
<div
class=
"pdf-container"
>
<div
class=
"tool-bar"
>
<a
class=
"resize"
@
click=
"changePage('after')"
>
下一页
</a>
<input
@
keyup
.
enter=
"toPage"
@
blur=
"toPage"
onkeypress=
"return event.keyCode>=48&&event.keyCode
<
=
57
"
ng-pattern=
"/[^a-zA-Z]/"
v-model=
"page"
>
/
{{
numPages
}}
<a
class=
"resize"
style=
"float:left"
@
click=
"changePage('before')"
>
上一页
</a>
<!--
<a
class=
"aRotate"
@
click=
"rotate += 90"
>
⟳
</a>
-->
<!--
<a
class=
"aRotate"
@
click=
"rotate -= 90"
>
⟲
</a>
-->
</div>
<div
class=
"pdf"
>
<div
class=
"pdf"
>
<div
class=
"pdfList"
>
<div
class=
"pdfList"
>
<pdf
<pdf
...
@@ -18,96 +11,116 @@
...
@@ -18,96 +11,116 @@
></pdf>
></pdf>
</div>
</div>
</div>
</div>
<div
class=
"tool-bar"
v-show=
"isPdfShow"
>
<a
class=
"resize"
style=
"float:left"
@
click=
"changePage('before')"
>
上一页
</a>
<input
@
keyup
.
enter=
"toPage"
@
blur=
"toPage"
onkeypress=
"return event.keyCode>=48&&event.keyCode
<
=
57
"
ng-pattern=
"/[^a-zA-Z]/"
v-model=
"page"
>
/
{{
numPages
}}
<a
class=
"resize"
@
click=
"changePage('after')"
>
下一页
</a>
</div>
</div>
</div>
</
template
>
</
template
>
<
script
>
<
script
>
import
pdf
from
'vue-pdf'
;
import
pdf
from
'vue-pdf'
import
$
from
'jquery'
;
export
default
{
export
default
{
components
:
{
components
:
{
pdf
:
pdf
pdf
:
pdf
},
},
data
()
{
data
()
{
return
{
return
{
src
:
''
,
src
:
""
,
numPages
:
undefined
,
numPages
:
undefined
,
page
:
1
,
page
:
1
,
rotate
:
0
,
rotate
:
0
,
pageArr
:
[
1
]
pageArr
:[
1
],
isPdfShow
:
false
}
;
}
},
},
props
:
[
'pdfSrc'
],
props
:
[
'pdfSrc'
,
'isShowTools'
],
methods
:
{
methods
:
{
// handleInput(e){
// handleInput(e){
// this.page=parseInt(e.target.value.replace(/[^\d]/g,''));
// this.page=parseInt(e.target.value.replace(/[^\d]/g,''));
// },
// },
changePage
(
params
)
{
changePage
(
params
)
{
if
(
params
===
'before'
)
{
if
(
params
===
'before'
)
{
this
.
page
=
this
.
page
-
1
>
0
?
(
this
.
page
-
1
)
:
1
;
this
.
page
=
this
.
page
-
1
>
0
?(
this
.
page
-
1
):
1
}
else
{
}
else
{
this
.
page
=
this
.
page
+
1
>
this
.
numPages
?
this
.
numPages
:
(
this
.
page
+
1
);
this
.
page
=
this
.
page
+
1
>
this
.
numPages
?
this
.
numPages
:(
this
.
page
+
1
)
}
}
},
},
toPage
()
{
toPage
(){
cons
t
newPage
=
parseInt
(
this
.
page
);
le
t
newPage
=
parseInt
(
this
.
page
);
if
(
newPage
<
1
||
$
.
trim
(
this
.
page
)
==
''
)
{
if
(
newPage
<
1
||
$
.
trim
(
this
.
page
)
==
""
)
{
console
.
log
(
'toPage-----------<1'
);
console
.
log
(
"toPage-----------<1"
);
this
.
page
=
1
;
this
.
page
=
1
;
}
}
if
(
newPage
>
this
.
numPages
)
{
if
(
newPage
>
this
.
numPages
)
{
console
.
log
(
'toPage----------->total'
);
console
.
log
(
"toPage----------->total"
);
this
.
page
=
this
.
numPages
;
this
.
page
=
this
.
numPages
;
}
}
},
},
toLittle
()
{
toLittle
(){
cons
t
cW
=
$
(
'.pdf-container'
).
width
();
le
t
cW
=
$
(
'.pdf-container'
).
width
();
cons
t
cH
=
$
(
'.pdf-container'
).
height
();
le
t
cH
=
$
(
'.pdf-container'
).
height
();
cons
t
pW
=
$
(
'.pdfList'
).
width
();
le
t
pW
=
$
(
'.pdfList'
).
width
();
cons
t
pH
=
$
(
'.pdfList'
).
height
();
le
t
pH
=
$
(
'.pdfList'
).
height
();
if
(
pW
*
5
/
6
<
cW
*
0.01
||
(
pH
*
5
/
6
/
this
.
numPages
)
<
cH
*
0.01
)
{
if
(
pW
*
5
/
6
<
cW
*
0.01
||
(
pH
*
5
/
6
/
this
.
numPages
)
<
cH
*
0.01
)
{
return
;
return
;
}
}
// let newW = pW*5/6
<
cW
*
0.3
?
cW
*
0.3
:
pW
*
5
/
6
;
// let newW = pW*5/6
<
cW
*
0.3
?
cW
*
0.3
:
pW
*
5
/
6
;
// let newH = (pH*5/6/this.numPages)
<
cH
*
0.3
?
cH
*
0.3
*
this
.
numPages
:
pH
*
5
/
6
;
// let newH = (pH*5/6/this.numPages)
<
cH
*
0.3
?
cH
*
0.3
*
this
.
numPages
:
pH
*
5
/
6
;
const
newW
=
pW
*
5
/
6
;
let
newW
=
pW
*
5
/
6
;
const
newH
=
pH
*
5
/
6
;
let
newH
=
pH
*
5
/
6
;
$
(
'.pdfList'
).
width
(
newW
);
$
(
'.pdfList'
).
width
(
newW
);
$
(
'.pdfList'
).
height
(
newH
);
$
(
'.pdfList'
).
height
(
newH
);
},
},
toBig
()
{
toBig
(){
cons
t
cW
=
$
(
'.pdf-container'
).
width
();
le
t
cW
=
$
(
'.pdf-container'
).
width
();
cons
t
cH
=
$
(
'.pdf-container'
).
height
();
le
t
cH
=
$
(
'.pdf-container'
).
height
();
cons
t
pW
=
$
(
'.pdfList'
).
width
();
le
t
pW
=
$
(
'.pdfList'
).
width
();
cons
t
pH
=
$
(
'.pdfList'
).
height
();
le
t
pH
=
$
(
'.pdfList'
).
height
();
let
newW
,
newH
;
let
newW
,
newH
;
if
(
pW
*
6
/
5
>
cW
&&
(
pH
*
6
/
5
/
this
.
numPages
)
>
cH
)
{
if
(
pW
*
6
/
5
>
cW
&&
(
pH
*
6
/
5
/
this
.
numPages
)
>
cH
)
{
return
;
return
;
}
}
// newW = pW*6/5>cW?cW:pW*6/5;
// newW = pW*6/5>cW?cW:pW*6/5;
// newH = (pH*6/5/this.numPages)>cH?cH*this.numPages:pH*6/5;
// newH = (pH*6/5/this.numPages)>cH?cH*this.numPages:pH*6/5;
newW
=
pW
*
6
/
5
;
newW
=
pW
*
6
/
5
;
newH
=
pH
*
6
/
5
;
newH
=
pH
*
6
/
5
;
$
(
'.pdfList'
).
width
(
newW
);
$
(
'.pdfList'
).
width
(
newW
);
$
(
'.pdfList'
).
height
(
newH
);
$
(
'.pdfList'
).
height
(
newH
);
},
delHide
()
{
this
.
isPdfShow
=
false
},
delShow
()
{
this
.
isPdfShow
=
true
}
}
},
},
beforeMount
()
{
beforeMount
(){
this
.
src
=
pdf
.
createLoadingTask
(
this
.
pdfSrc
)
;
this
.
src
=
pdf
.
createLoadingTask
(
this
.
pdfSrc
)
// this.src = 'https://cdn.mozilla.net/pdfjs/tracemonkey.pdf'
// this.src = 'https://cdn.mozilla.net/pdfjs/tracemonkey.pdf'
},
},
mounted
()
{
mounted
()
{
cons
t
that
=
this
;
le
t
that
=
this
;
this
.
src
.
then
(
pdf
=>
{
this
.
src
.
then
(
pdf
=>
{
that
.
numPages
=
pdf
.
numPages
;
that
.
numPages
=
pdf
.
numPages
;
// $('.pdf').onscroll(this.onScroll);
// $('.pdf').onscroll(this.onScroll);
});
})
},
watch
:{
isShowTools
(){
if
(
this
.
isShowTools
){
this
.
delShow
()
}
else
{
this
.
delHide
()
}
}
}
}
}
;
}
</
script
>
</
script
>
<
style
scoped
>
<
style
scoped
>
.pdf-container
{
.pdf-container
{
...
@@ -119,11 +132,13 @@
...
@@ -119,11 +132,13 @@
overflow
:
hidden
;
overflow
:
hidden
;
}
}
.tool-bar
{
.tool-bar
{
position
:
absolute
;
bottom
:
0
;
width
:
100%
;
width
:
100%
;
background
:
rgb
(
50
,
54
,
5
7
);
background
:
rgb
a
(
43
,
51
,
63
,
0.
7
);
height
:
48
px
;
height
:
30
px
;
line-height
:
48
px
;
line-height
:
30
px
;
box-shadow
:
0
2px
6px
0
rgb
(
50
,
54
,
57
);
/*box-shadow: 0 2px 6px 0 rgb(50, 54, 57);*/
color
:
rgb
(
241
,
241
,
241
);
color
:
rgb
(
241
,
241
,
241
);
text-align
:
center
;
text-align
:
center
;
font-size
:
13px
;
font-size
:
13px
;
...
@@ -150,14 +165,15 @@
...
@@ -150,14 +165,15 @@
.pdfList
{
.pdfList
{
display
:
inline-block
;
display
:
inline-block
;
margin-top
:
20px
;
margin-top
:
23px
;
margin-bottom
:
23px
;
width
:
60%
;
width
:
60%
;
}
}
.pdfList
div
{
.pdfList
div
{
background
:
#fff
;
background
:
#fff
;
border-radius
:
5px
;
border-radius
:
5px
;
margin-top
:
5
px
;
margin-top
:
3
px
;
margin-bottom
:
10px
;
/*margin-bottom: 10px;*/
box-shadow
:
1px
4px
10px
2px
rgb
(
50
,
54
,
57
);
box-shadow
:
1px
4px
10px
2px
rgb
(
50
,
54
,
57
);
}
}
.aRotate
{
.aRotate
{
...
@@ -168,7 +184,7 @@
...
@@ -168,7 +184,7 @@
.resize
{
.resize
{
font-size
:
25px
;
font-size
:
25px
;
float
:
right
;
float
:
right
;
margin
-right
:
15px
;
margin
:
0
15px
;
font-size
:
14px
;
font-size
:
14px
;
}
}
.pdf
{
.pdf
{
...
...
src/views/courseTrain/sortManage.vue
View file @
7f9a8a5b
...
@@ -5,7 +5,7 @@
...
@@ -5,7 +5,7 @@
<a-alert
:message=
successInfor
v-if=
"showSuccess"
type=
"success"
showIcon
/>
<a-alert
:message=
successInfor
v-if=
"showSuccess"
type=
"success"
showIcon
/>
<a-alert
:message=
failInfor
v-if=
"showFail"
type=
"error"
showIcon
closable
/>
<a-alert
:message=
failInfor
v-if=
"showFail"
type=
"error"
showIcon
closable
/>
</div>
</div>
<div
style=
"height:
666px
"
>
<div
style=
"height:
88vh
"
>
<div
class=
"sortManageMenu"
>
<div
class=
"sortManageMenu"
>
<div
style=
"display: inline-block"
>
<div
style=
"display: inline-block"
>
<span
class=
"allCategory"
>
全部分类
</span>
<span
class=
"allCategory"
>
全部分类
</span>
...
...
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