Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
X
xiaomai-cloud-class-web
Overview
Overview
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
xiaomai-cloud-class
xiaomai-cloud-class-web
Commits
0d1f5c70
Commit
0d1f5c70
authored
May 18, 2021
by
chenshu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix:修复管理端部分问题
parent
a0698067
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
30 additions
and
12 deletions
+30
-12
src/modules/course-manage/offline-course/AddOfflineCourse.jsx
+15
-3
src/modules/course-manage/offline-course/OfflineCourseData.jsx
+14
-8
src/modules/course-manage/offline-course/components/OfflineCourseList.jsx
+1
-1
No files found.
src/modules/course-manage/offline-course/AddOfflineCourse.jsx
View file @
0d1f5c70
...
@@ -1090,7 +1090,11 @@ class AddOfflineCourse extends React.Component {
...
@@ -1090,7 +1090,11 @@ class AddOfflineCourse extends React.Component {
style=
{
{
width
:
72
,
marginRight
:
4
}
}
style=
{
{
width
:
72
,
marginRight
:
4
}
}
value=
{
signInTimeUnit
}
value=
{
signInTimeUnit
}
onChange=
{
(
value
)
=>
{
onChange=
{
(
value
)
=>
{
this
.
setState
({
signInTimeUnit
:
value
});
const
data
=
{
signInTimeUnit
:
value
}
if
(
value
===
'HOUR'
&&
signInTimeNum
>
24
)
{
data
.
signInTimeNum
=
24
;
}
this
.
setState
(
data
);
}
}
}
}
>
>
{
unitList
.
map
(
item
=>
(
{
unitList
.
map
(
item
=>
(
...
@@ -1153,7 +1157,11 @@ class AddOfflineCourse extends React.Component {
...
@@ -1153,7 +1157,11 @@ class AddOfflineCourse extends React.Component {
style=
{
{
width
:
72
,
marginRight
:
4
}
}
style=
{
{
width
:
72
,
marginRight
:
4
}
}
value=
{
signOutStartTimeUnit
}
value=
{
signOutStartTimeUnit
}
onChange=
{
(
value
)
=>
{
onChange=
{
(
value
)
=>
{
this
.
setState
({
signOutStartTimeUnit
:
value
});
const
data
=
{
signOutStartTimeUnit
:
value
}
if
(
value
===
'HOUR'
&&
signOutStartTimeNum
>
24
)
{
data
.
signOutStartTimeNum
=
24
;
}
this
.
setState
(
data
);
}
}
}
}
>
>
{
unitList
.
map
(
item
=>
(
{
unitList
.
map
(
item
=>
(
...
@@ -1174,7 +1182,11 @@ class AddOfflineCourse extends React.Component {
...
@@ -1174,7 +1182,11 @@ class AddOfflineCourse extends React.Component {
style=
{
{
width
:
72
,
marginRight
:
4
}
}
style=
{
{
width
:
72
,
marginRight
:
4
}
}
value=
{
signOutEndTimeUnit
}
value=
{
signOutEndTimeUnit
}
onChange=
{
(
value
)
=>
{
onChange=
{
(
value
)
=>
{
this
.
setState
({
signOutEndTimeUnit
:
value
});
const
data
=
{
signOutEndTimeUnit
:
value
}
if
(
value
===
'HOUR'
&&
signOutEndTimeNum
>
24
)
{
data
.
signOutEndTimeNum
=
24
;
}
this
.
setState
(
data
);
}
}
}
}
>
>
{
unitList
.
map
(
item
=>
(
{
unitList
.
map
(
item
=>
(
...
...
src/modules/course-manage/offline-course/OfflineCourseData.jsx
View file @
0d1f5c70
...
@@ -57,6 +57,9 @@ export default class OfflineCourseData extends React.Component {
...
@@ -57,6 +57,9 @@ export default class OfflineCourseData extends React.Component {
totalJoin
:
result
.
totalJoin
||
0
,
totalJoin
:
result
.
totalJoin
||
0
,
calendarTime
,
calendarTime
,
currentDate
,
currentDate
,
offlineCourseType
:
result
.
offlineCourseType
,
whetherSetSignInOut
:
result
.
whetherSetSignInOut
,
whetherSetApply
:
result
.
whetherSetApply
,
},
()
=>
this
.
getDateDetail
());
},
()
=>
this
.
getDateDetail
());
}
}
})
})
...
@@ -157,6 +160,9 @@ export default class OfflineCourseData extends React.Component {
...
@@ -157,6 +160,9 @@ export default class OfflineCourseData extends React.Component {
joinInNum
,
joinInNum
,
joinNum
,
joinNum
,
joinOutNum
,
joinOutNum
,
offlineCourseType
,
whetherSetApply
,
whetherSetSignInOut
,
}
=
this
.
state
;
}
=
this
.
state
;
const
calendarLength
=
calendarTime
.
length
;
const
calendarLength
=
calendarTime
.
length
;
const
dateList
=
(
calendarTime
[
currentIndex
]
||
{}).
value
||
[];
const
dateList
=
(
calendarTime
[
currentIndex
]
||
{}).
value
||
[];
...
@@ -170,10 +176,10 @@ export default class OfflineCourseData extends React.Component {
...
@@ -170,10 +176,10 @@ export default class OfflineCourseData extends React.Component {
/>
/>
<
div
className=
"box"
>
<
div
className=
"box"
>
<
div
className=
"offline-name"
>
课程名称:
{
courseName
}
</
div
>
<
div
className=
"offline-name"
>
课程名称:
{
courseName
}
</
div
>
<
div
className=
"offline-application"
>
报名总人数:
{
totalJoin
}
</
div
>
{
whetherSetApply
===
'YES'
&&
<
div
className=
"offline-application"
>
报名总人数:
{
totalJoin
}
</
div
>
}
<
div
className=
"offline-application"
>
{
whetherSetSignInOut
===
'YES'
&&
<
div
className=
"offline-application"
>
完成考勤总人数
<
Tooltip
title=
"根据上课日期,在规定时间内完成签到和签退的用户数"
><
span
className=
"icon iconfont"
>

</
span
></
Tooltip
>
:
{
fullJoin
}
完成考勤总人数
<
Tooltip
title=
"根据上课日期,在规定时间内完成签到和签退的用户数"
><
span
className=
"icon iconfont"
>

</
span
></
Tooltip
>
:
{
fullJoin
}
</
div
>
</
div
>
}
</
div
>
</
div
>
<
div
className=
"box data-box"
>
<
div
className=
"box data-box"
>
<
div
className=
"left-box"
>
<
div
className=
"left-box"
>
...
@@ -184,7 +190,7 @@ export default class OfflineCourseData extends React.Component {
...
@@ -184,7 +190,7 @@ export default class OfflineCourseData extends React.Component {
onClick=
{
()
=>
{
onClick=
{
()
=>
{
const
index
=
currentIndex
-
1
;
const
index
=
currentIndex
-
1
;
if
(
index
>=
0
&&
index
<
calendarLength
)
{
if
(
index
>=
0
&&
index
<
calendarLength
)
{
this
.
setState
({
currentIndex
:
index
,
currentDate
:
calendarTime
[
index
][
0
]
},
()
=>
{
this
.
setState
({
currentIndex
:
index
,
currentDate
:
calendarTime
[
index
]
.
value
[
0
]
},
()
=>
{
this
.
getDateDetail
();
this
.
getDateDetail
();
});
});
}
}
...
@@ -198,7 +204,7 @@ export default class OfflineCourseData extends React.Component {
...
@@ -198,7 +204,7 @@ export default class OfflineCourseData extends React.Component {
onClick=
{
()
=>
{
onClick=
{
()
=>
{
const
index
=
currentIndex
+
1
;
const
index
=
currentIndex
+
1
;
if
(
index
>=
0
&&
index
<
calendarLength
)
{
if
(
index
>=
0
&&
index
<
calendarLength
)
{
this
.
setState
({
currentIndex
:
index
,
currentDate
:
calendarTime
[
index
][
0
]
},
()
=>
{
this
.
setState
({
currentIndex
:
index
,
currentDate
:
calendarTime
[
index
]
.
value
[
0
]
},
()
=>
{
this
.
getDateDetail
();
this
.
getDateDetail
();
});
});
}
}
...
@@ -222,10 +228,10 @@ export default class OfflineCourseData extends React.Component {
...
@@ -222,10 +228,10 @@ export default class OfflineCourseData extends React.Component {
</
div
>
</
div
>
</
div
>
</
div
>
<
div
className=
"right-box"
>
<
div
className=
"right-box"
>
<
div
className=
"selected-date"
>
5月1日
</
div
>
<
div
className=
"selected-date"
>
{
moment
(
currentDate
).
format
(
'MM-DD'
)
}
</
div
>
<
div
className=
"detail-data"
>
<
div
className=
"detail-data"
>
<
span
className=
"icon iconfont"
>

</
span
>
{
offlineCourseType
!==
'ALL_DAY_OFFLINE'
&&
<
span
className=
"icon iconfont"
>

</
span
>
}
<
span
className=
"data-text"
>
报名人数:
{
joinNum
}
</
span
>
{
offlineCourseType
!==
'ALL_DAY_OFFLINE'
&&
whetherSetApply
===
'YES'
&&
<
span
className=
"data-text"
>
报名人数:
{
joinNum
}
</
span
>
}
<
span
className=
"icon iconfont"
>

</
span
>
<
span
className=
"icon iconfont"
>

</
span
>
<
span
className=
"data-text"
>
完成考勤数
<
Tooltip
title=
"当日在规定时间内完成签到和签退的用户数"
><
span
className=
"icon iconfont"
>

</
span
></
Tooltip
>
:
{
fullJoinNum
}
</
span
>
<
span
className=
"data-text"
>
完成考勤数
<
Tooltip
title=
"当日在规定时间内完成签到和签退的用户数"
><
span
className=
"icon iconfont"
>

</
span
></
Tooltip
>
:
{
fullJoinNum
}
</
span
>
<
span
className=
"icon iconfont"
>

</
span
>
<
span
className=
"icon iconfont"
>

</
span
>
...
...
src/modules/course-manage/offline-course/components/OfflineCourseList.jsx
View file @
0d1f5c70
...
@@ -72,7 +72,7 @@ class OfflineCourseList extends React.Component {
...
@@ -72,7 +72,7 @@ class OfflineCourseList extends React.Component {
return
(
return
(
<
div
className=
"record__item"
>
<
div
className=
"record__item"
>
<
img
className=
"course-cover"
src=
{
coverUrl
||
defaultCoverUrl
}
/>
<
img
className=
"course-cover"
src=
{
coverUrl
||
defaultCoverUrl
}
/>
<
div
>
<
div
style=
{
{
width
:
200
}
}
>
<
Tooltip
title=
{
courseName
}
>
<
Tooltip
title=
{
courseName
}
>
<
div
className=
"course-name"
>
{
courseName
}
</
div
>
<
div
className=
"course-name"
>
{
courseName
}
</
div
>
</
Tooltip
>
</
Tooltip
>
...
...
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