Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
B
biz.qingxiao.com
Project
Project
Details
Activity
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
wangxuelai
biz.qingxiao.com
Commits
90a9e645
Commit
90a9e645
authored
Nov 28, 2019
by
wangxuelai
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
''
parent
5efedba0
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
61 additions
and
22 deletions
+61
-22
arrowleft.png
image/course/arrowleft.png
+0
-0
arrowright.png
image/course/arrowright.png
+0
-0
index.html
index.html
+1
-1
UploadCourseware.js
src/components/UploadCourseware.js
+31
-14
UploadCourseware.less
src/components/UploadCourseware.less
+22
-0
StudentAdd.js
src/pages/student/StudentAdd.js
+5
-5
StudentEdit.js
src/pages/studentinfo/StudentEdit.js
+2
-2
No files found.
image/course/arrowleft.png
0 → 100644
View file @
90a9e645
3.08 KB
image/course/arrowright.png
0 → 100644
View file @
90a9e645
3.09 KB
index.html
View file @
90a9e645
...
...
@@ -17,6 +17,6 @@
</head>
<body>
<div
id=
"root"
></div>
<script
src=
"dist/main.js?1574
863280714
"
charset=
"utf-8"
></script>
<script
src=
"dist/main.js?1574
907675933
"
charset=
"utf-8"
></script>
</body>
</html>
\ No newline at end of file
src/components/UploadCourseware.js
View file @
90a9e645
...
...
@@ -13,6 +13,11 @@ const { Option } = Select;
const
{
TextArea
}
=
Input
;
const
{
Group
}
=
Radio
;
class
UploadCourseware
extends
React
.
Component
{
constructor
(
props
)
{
super
(
props
);
this
.
state
=
{};
this
.
ref
=
React
.
createRef
();
}
componentDidMount
()
{
// 挂载
}
componentDidUpdate
()
{
...
...
@@ -95,6 +100,13 @@ class UploadCourseware extends React.Component {
that
.
reLoadVideoPoster
(
src
);
};
}
pptSwiper
=
(
type
)
=>
{
if
(
type
==
'prev'
)
{
this
.
ref
.
current
.
slick
.
slickPrev
();
}
else
if
(
type
==
'next'
)
{
this
.
ref
.
current
.
slick
.
slickNext
();
}
}
render
()
{
const
{
visible
,
...
...
@@ -184,20 +196,25 @@ class UploadCourseware extends React.Component {
<
/div
>
}
{(
info
.
mediaType
==
4
||
info
.
mediaType
==
5
)
&&
info
.
from
!=
'upload'
&&
<
Carousel
className
=
{
pageStyle
.
Carousel
}
ref
=
{
this
.
ref
}
draggable
>
{
info
.
images
.
map
((
ele
,
index
)
=>
{
return
(
<
div
className
=
{
pageStyle
.
CarouselBox
}
key
=
{
ele
}
>
<
img
className
=
{
pageStyle
.
CarouselImg
}
alt
=
""
src
=
{
pptImagify
(
ele
)}
/
>
<
/div
>
);
})
}
<
/Carousel
>
<
div
className
=
{
pageStyle
.
CarouselContent
}
>
<
img
alt
=
""
src
=
{
`
${
__IMGCDN__
}
course/arrowleft.png`
}
className
=
{
pageStyle
.
carouselPrev
}
onClick
=
{()
=>
this
.
pptSwiper
(
'prev'
)}
/
>
<
img
alt
=
""
src
=
{
`
${
__IMGCDN__
}
course/arrowright.png`
}
className
=
{
pageStyle
.
carouselNext
}
onClick
=
{()
=>
this
.
pptSwiper
(
'next'
)}
/
>
<
Carousel
className
=
{
pageStyle
.
Carousel
}
ref
=
{
this
.
ref
}
draggable
lazyLoad
>
{
info
.
images
.
map
((
ele
,
index
)
=>
{
return
(
<
div
className
=
{
pageStyle
.
CarouselBox
}
key
=
{
ele
}
>
<
img
className
=
{
pageStyle
.
CarouselImg
}
alt
=
""
src
=
{
pptImagify
(
ele
)}
/
>
<
/div
>
);
})
}
<
/Carousel
>
<
/div
>
}
<
/div
>
<
div
className
=
{
pageStyle
.
uploadbottom
}
>
...
...
src/components/UploadCourseware.less
View file @
90a9e645
...
...
@@ -245,4 +245,26 @@
text-align: center;
font-size: 20px;
z-index: 100;
}
.CarouselContent {
position: relative;
&:hover {
.carouselPrev, .carouselNext {
display: block;
}
}
.carouselPrev, .carouselNext {
position: absolute;
width: 41px;
height: 41px;
display: block;
top: 50%;
transform: translateY(-50%);
z-index: 3;
cursor: pointer;
display: none;
}
.carouselNext {
right: 0;
}
}
\ No newline at end of file
src/pages/student/StudentAdd.js
View file @
90a9e645
...
...
@@ -64,7 +64,7 @@ class StudentAddForm extends React.Component {
}
=
values
;
save
({
name
,
birthday
:
values
.
birthday
.
format
(
'YYYY-MM-DD'
)
||
null
,
birthday
:
values
.
birthday
?
values
.
birthday
.
format
(
'YYYY-MM-DD'
)
:
null
,
avatar
,
remark
,
mobile
,
...
...
@@ -287,10 +287,10 @@ class StudentAddForm extends React.Component {
>
{
getFieldDecorator
(
'birthday'
,
{
rules
:
[
{
required
:
true
,
message
:
'请输入生日'
,
},
//
{
//
required: true,
//
message: '请输入生日',
//
},
],
})(
<
DatePicker
disabledDate
=
{
this
.
disabledDate
}
onChange
=
{
this
.
onChange
}
allowClear
style
=
{{
width
:
134
}}
/>
)
}
<
span
style
=
{{
marginLeft
:
12
}}
>
年龄:
{
this
.
state
.
cage
}
<
/span
>
...
...
src/pages/studentinfo/StudentEdit.js
View file @
90a9e645
...
...
@@ -54,7 +54,7 @@ class StudentAddForm extends React.Component {
}
=
values
;
save
({
name
,
birthday
:
values
.
birthday
.
format
(
'YYYY-MM-DD'
)
||
null
,
birthday
:
values
.
birthday
?
values
.
birthday
.
format
(
'YYYY-MM-DD'
)
:
null
,
avatar
,
remark
,
mobile
,
...
...
@@ -164,7 +164,7 @@ class StudentAddForm extends React.Component {
}}
>
{
getFieldDecorator
(
'birthday'
,
{
initialValue
:
moment
(
studentsdetail
.
birthday
,
'YYYY-MM-DD'
)
,
initialValue
:
studentsdetail
.
birthday
?
moment
(
studentsdetail
.
birthday
,
'YYYY-MM-DD'
)
:
null
,
rules
:
[
{
required
:
true
,
...
...
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