Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gk
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
micro_app
gk
Commits
88965029
Commit
88965029
authored
Jul 21, 2020
by
yangshuxing
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改成绩
parent
eb2e33c6
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
187 additions
and
58 deletions
+187
-58
score_review.jsp
src/main/webapp/WEB-INF/views/cmpt/score_review.jsp
+89
-46
score_review.css
src/main/webapp/static/cmpt/score_review.css
+36
-5
icon-score-save.png
src/main/webapp/static/images/manage/icon-score-save.png
+0
-0
score-edit.png
src/main/webapp/static/images/manage/score-edit.png
+0
-0
score_review.js
src/main/webapp/static/js/score_review.js
+62
-7
No files found.
src/main/webapp/WEB-INF/views/cmpt/score_review.jsp
View file @
88965029
...
...
@@ -45,6 +45,9 @@
border
:
none
;
outline
:
none
;
}
.check-all
,
.check
{
width
:
55px
!important
;
}
</style>
</head>
<body>
...
...
@@ -69,25 +72,11 @@
<span
class=
"road-notice-txt"
>
选手提交成绩时,如果“平均配速”(根据里程和用时计算获得)在正常范围(大于2’27”)则自动通过审核,可以立刻领取完赛证书。
</span>
</div>
</div>
<%--<div class="section">
<div style="display: flex;justify-content: space-between">
<h3 class="title">批量删除</h3>
<div class="search-group" style="display: flex;align-items: center;justify-content: center;">
<input type="text" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm'})" class="time-input start" placeholder="起始时间">
<span>~</span>
<input type="text" onclick="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm'})" class="time-input end" placeholder="终止时间">
</div>
<div class="deleteBtn">
<span>删除</span>
</div>
</div>
</div>--%>
<div
class=
"section data"
>
<div
class=
"flex-vt"
>
<span
class=
"title"
>
审核结果
</span>
<span
class=
"export-btn"
>
导出名单
</span>
</div>
<div
class=
"flex"
>
...
...
@@ -117,10 +106,6 @@
<input
v-model=
"searchWord"
class=
"search-ipt"
type=
"text"
>
<span
v-on:click=
"searchKd"
class=
"search-btn-text"
>
搜索
</span>
</div>
<div
class=
"flex-vt"
>
<span
class=
"export-btn"
>
导出名单
</span>
</div>
</div>
<div
class=
"tab"
>
...
...
@@ -136,6 +121,7 @@
<span
v-on:click=
"deleteScores"
class=
"del"
>
删除
</span>
</div>
<div
class=
"data-cloumn"
>
<span
class=
"check-all"
><input
v-on:click=
"checkAll"
:checked=
"checked?'true':'' "
type=
"checkbox"
></span>
<span>
姓名
</span>
<span>
参赛号码
</span>
<span>
上传时间
</span>
...
...
@@ -143,44 +129,101 @@
<span>
里程(KM)
</span>
<span>
用时
</span>
<span>
平均配速
</span>
<span>
全选
<input
v-on:click=
"checkAll"
:checked=
"checked?'true':'' "
type=
"checkbox"
>
</span>
<span>
操作
</span>
</div>
<div
class=
"score-item"
v-on:click=
"showDetail(score.cmptScoreRuleScoreinfoId,$event)"
v-for=
"score in scores"
:data-id=
"score.cmptScoreRuleScoreinfoId"
>
<div
class=
"score-info"
>
<span
v-text=
"score.name"
></span>
<span
v-text=
"score.markNo"
></span>
<span>
{{score.insertTime | substr(10)}}
</span>
<span>
{{score.subsectionTime | substrDate(10)}}
</span>
<span>
{{Number(score.subsectionMileage/1000).toFixed(3)}}
</span>
<span>
{{score.subsectionscore | date_format}}
</span>
<span>
{{score.cmptPace | pace(Number(score.subsectionMileage/1000).toFixed(3),score.subsectionscore) }}
</span>
<span><input
v-on:click
.
stop=
""
type=
"checkbox"
:value=
"score.cmptScoreRuleScoreinfoId"
:checked=
"checked?'true':'' "
></span>
</div>
<div
class=
"flex score-img"
v-on:click
.
stop=
""
>
<div
class=
"img-item"
v-for=
"item in score.scoreFieldValueList"
>
<video
v-if=
"item.fieldType == 2"
v-on:click=
"preview($event,item)"
name=
"media"
><source
:src=
"item.scoreFieldValue"
type=
"video/mp4"
></video>
<img
v-else
v-on:click=
"preview($event,item)"
class=
"img"
:src=
"item.scoreFieldValue"
alt=
""
>
<span
class=
"bigger"
></span>
<div
class=
"score-item"
v-on:click=
"showDetail(score.cmptScoreRuleScoreinfoId,$event,score.markNo)"
v-for=
"score in scores"
:data-id=
"score.cmptScoreRuleScoreinfoId"
>
<template
v-if=
"score.save"
>
<div
class=
"score-info"
>
<span
class=
"check"
><input
v-on:click
.
stop=
""
type=
"checkbox"
:value=
"score.cmptScoreRuleScoreinfoId"
:checked=
"checked?'true':'' "
></span>
<span
v-text=
"score.name"
></span>
<span
v-text=
"score.markNo"
></span>
<span>
{{score.insertTime | substr(10)}}
</span>
<span>
{{score.subsectionTime | substrDate(10)}}
</span>
<span>
{{Number(score.subsectionMileage/1000).toFixed(3)}}
</span>
<span>
{{score.subsectionscore | date_format}}
</span>
<span>
{{score.cmptPace | pace(Number(score.subsectionMileage/1000).toFixed(3),score.subsectionscore) }}
</span>
<span
style=
"cursor: pointer;"
v-on:click
.
stop=
""
v-on:click=
"changeScoreStatus(score)"
>
<span
class=
"icon-score-edit"
></span>
<span
class=
"score-edit"
>
编辑
</span>
</span>
</div>
</template>
<template
v-else
>
<div
class=
"score-info"
>
<span
class=
"check"
><input
v-on:click
.
stop=
""
type=
"checkbox"
:value=
"score.cmptScoreRuleScoreinfoId"
:checked=
"checked?'true':'' "
></span>
<span
v-text=
"score.name"
></span>
<span
v-text=
"score.markNo"
></span>
<span>
{{score.insertTime | substr(10)}}
</span>
<span><input
v-on:click
.
stop=
""
class=
"score-input doneTime"
type=
"text"
onclick=
"WdatePicker({skin:'whyGreen',dateFmt:'yyyy-MM-dd'})"
:value=
"score.subsectionTime | substrDate(10)"
></span>
<span><input
v-on:click
.
stop=
""
class=
"score-input miles"
type=
"text"
:value=
"Number(score.subsectionMileage/1000).toFixed(3)"
></span>
<span><input
v-on:click
.
stop=
""
class=
"score-input duration"
type=
"text"
onclick=
"WdatePicker({skin:'whyGreen',dateFmt:'HH:mm:ss'})"
:value=
"score.subsectionscore | date_format"
></span>
<span>
{{score.cmptPace | pace(Number(score.subsectionMileage/1000).toFixed(3),score.subsectionscore) }}
</span>
<span
style=
"cursor: pointer;"
v-on:click
.
stop=
""
v-on:click=
"saveScoreDetail(score,$event)"
>
<span
class=
"icon-score-save"
></span>
<span
class=
"score-edit"
>
保存
</span>
</span>
</div>
</template>
<template
v-if=
"score.save"
>
<div
class=
"flex score-img"
v-on:click
.
stop=
""
>
<div
class=
"img-item"
v-for=
"item in score.scoreFieldValueList"
>
<video
v-if=
"item.fieldType == 2 && (item.scoreFieldValue.indexOf('mp4')> -1 ||item.scoreFieldValue.indexOf('mov') > -1)"
v-on:click=
"preview($event,item)"
name=
"media"
:src=
"item.scoreFieldValue"
type=
"video/mp4"
></video>
<img
v-else
v-on:click
.
stop=
""
v-on:click=
"preview($event,item)"
class=
"img"
:src=
"item.scoreFieldValue"
alt=
""
>
<span
class=
"bigger"
></span>
</div>
</div>
</div>
<div
class=
"flex score-detail"
v-show=
"score.scoreDetails.length>0"
>
<table>
<thead>
<div
v-on:click
.
stop=
""
class=
"flex score-detail"
v-show=
"score.scoreDetails.length>0"
>
<table>
<thead>
<tr>
<th>
打卡点
</th>
<th>
打卡时间
</th>
</tr>
</thead>
<tbody>
<tr
class=
"score-detail-item"
v-for=
"item in score.scoreDetails"
>
</thead>
<tbody>
<tr
class=
"score-detail-item"
:checkpointId=
"item.checkpointId"
:checkpointTimeId=
"item.checkpointTimeId"
v-for=
"item in score.scoreDetails"
>
<td>
{{item.checkPointName}}
</td>
<td>
{{item.checkpointTime | substrYear}}
</td>
</tr>
</tbody>
</table>
</div>
</tbody>
</table>
</div>
</template>
<template
v-else
>
<div
v-on:click
.
stop=
""
class=
"flex score-detail"
v-show=
"score.scoreDetails.length>0"
>
<table>
<thead>
<tr>
<th>
打卡点
</th>
<th>
打卡时间
</th>
</tr>
</thead>
<tbody>
<tr
class=
"score-detail-item"
:check-point-id=
"item.checkpointId"
:checkpointTimeId=
"item.checkpointTimeId"
v-for=
"item in score.scoreDetails"
>
<td>
{{item.checkPointName}}
</td>
<td><input
v-on:click
.
stop=
""
type=
"text"
class=
"score-input-bigger"
v-bind:value=
"item.checkpointTime | substrYear"
onclick=
"WdatePicker({skin:'whyGreen',dateFmt:'MM-dd HH:mm:ss'})"
></td>
</tr>
</tbody>
</table>
</div>
</template>
</div>
<div
class=
"pager"
>
...
...
src/main/webapp/static/cmpt/score_review.css
View file @
88965029
...
...
@@ -94,6 +94,34 @@ input[type=checkbox] {
color
:
rgba
(
206
,
57
,
57
,
1
);
border-bottom
:
none
;
}
input
.score-input
{
width
:
100px
;
height
:
40px
;
background
:
whitesmoke
;
}
input
.score-input-bigger
{
width
:
120px
;
height
:
40px
;
background
:
whitesmoke
;
}
.icon-score-edit
{
width
:
16px
;
height
:
18px
;
background
:
url(/static/images/manage/score-edit.png)
no-repeat
center
;
background-size
:
contain
;
background-position
:
center
;
}
.icon-score-save
{
width
:
20px
;
height
:
16px
;
background
:
url(/static/images/manage/icon-score-save.png)
no-repeat
center
;
background-size
:
contain
;
background-position
:
center
;
}
.score-edit
{
color
:
#ce3939
!important
;
font-size
:
14px
;
}
.tab
.review-status
:last-child
{
border-right
:
1px
solid
rgba
(
229
,
229
,
229
,
1
);
}
...
...
@@ -101,26 +129,29 @@ input[type=checkbox] {
padding
:
0px
20px
;
}
.data-cloumn
span
,
.score-info
span
{
.data-cloumn
>
span
,
.score-info
>
span
{
display
:
inline-block
;
width
:
1
2
0px
;
width
:
1
1
0px
;
height
:
45px
;
line-height
:
45px
;
font-size
:
16px
;
color
:
rgba
(
153
,
153
,
153
,
1
);
}
.data-cloumn
span
:last-child
,
.score-info
span
:last-child
{
width
:
50
px
;
.data-cloumn
>
span
:last-child
,
.score-info
>
span
:last-child
{
width
:
62
px
;
text-align
:
center
;
}
.score-item
{
background
:
rgba
(
250
,
250
,
250
,
1
);
border-radius
:
4px
;
padding
:
0px
20px
;
margin-bottom
:
2
0px
;
margin-bottom
:
1
0px
;
}
.score-info
{
border-bottom
:
1px
solid
rgba
(
221
,
221
,
221
,
1
);
height
:
45px
;
line-height
:
45px
;
display
:
flex
;
}
.score-info
span
{
color
:
rgba
(
51
,
51
,
51
,
1
);
...
...
src/main/webapp/static/images/manage/icon-score-save.png
0 → 100644
View file @
88965029
977 Bytes
src/main/webapp/static/images/manage/score-edit.png
0 → 100644
View file @
88965029
1.71 KB
src/main/webapp/static/js/score_review.js
View file @
88965029
var
baseURL
=
'http://localhost:8081/'
var
score
=
new
Vue
({
el
:
'#score'
,
data
:
{
...
...
@@ -32,14 +33,18 @@ var score = new Vue({
},
filters
:
{
substr
:
function
(
value
,
length
){
console
.
log
(
value
+
","
+
length
)
if
(
!
value
||
value
.
length
<
18
)
return
""
;
return
value
.
substr
(
5
,
5
)
+
" "
+
value
.
substr
(
11
,
5
);
},
substrYear
:
function
(
value
){
if
(
!
value
)
return
""
;
var
date
=
new
Date
(
value
);
return
date
.
getFullYear
()
+
"-"
+
(
date
.
getMonth
()
+
1
)
+
"-"
+
date
.
getDate
()
+
" "
+
date
.
getHours
()
+
":"
+
date
.
getMinutes
()
+
":"
+
date
.
getSeconds
();
let
date
=
new
Date
(
value
);
let
month
=
(
date
.
getMonth
()
+
1
)
<
10
?
"0"
+
(
date
.
getMonth
()
+
1
)
:
(
date
.
getMonth
()
+
1
);
let
day
=
(
date
.
getDate
())
<
10
?
"0"
+
(
date
.
getDate
())
:
date
.
getDate
();
let
hour
=
date
.
getHours
()
<
10
?
"0"
+
(
date
.
getHours
())
:
date
.
getHours
();
let
min
=
date
.
getMinutes
()
<
10
?
"0"
+
(
date
.
getMinutes
())
:
date
.
getMinutes
();
let
sec
=
date
.
getSeconds
()
<
10
?
"0"
+
(
date
.
getSeconds
())
:
date
.
getSeconds
();
return
month
+
"-"
+
day
+
" "
+
hour
+
":"
+
min
+
":"
+
sec
;
},
substrDate
:
function
(
value
,
length
){
if
(
!
value
||
value
.
length
<
18
)
return
""
;
...
...
@@ -64,6 +69,9 @@ var score = new Vue({
}
},
methods
:{
changeScoreStatus
:
function
(
score
){
score
.
save
=
!
score
.
save
;
},
closeDialog
:
function
(){
score
.
$data
.
dialog
=
false
;
},
...
...
@@ -82,7 +90,6 @@ var score = new Vue({
score
.
$data
.
checked
=
!
score
.
$data
.
checked
},
changeRoad
:
function
()
{
console
.
log
(
score
.
$data
.
selectedRoadId
);
score
.
$data
.
jumpToPage
=
1
;
score
.
$data
.
param
.
page
=
0
;
reviewPage
.
reloadPage
();
...
...
@@ -93,7 +100,6 @@ var score = new Vue({
reviewPage
.
reloadPage
();
},
changeOrigin
:
function
()
{
console
.
log
(
score
.
$data
.
selectedOrigin
);
reviewPage
.
reloadPage
();
},
next
:
function
()
{
...
...
@@ -126,13 +132,61 @@ var score = new Vue({
});
return
obj
;
},
showDetail
:
function
(
id
,
event
){
saveScoreDetail
:
function
(
scoreObj
,
event
){
scoreObj
.
save
=
!
scoreObj
.
save
;
let
parent
=
$
(
event
.
target
).
parents
(
'.score-info'
);
let
doneTime
=
parent
.
find
(
'.doneTime'
).
val
();
let
miles
=
parent
.
find
(
'.miles'
).
val
();
let
duration
=
parent
.
find
(
'.duration'
).
val
();
let
time
=
Number
(
duration
.
split
(
':'
)[
0
]
*
3600
)
+
Number
(
duration
.
split
(
':'
)[
1
]
+
60
)
+
Number
(
duration
.
split
(
':'
)[
2
]);
let
param
=
{};
param
.
cmptId
=
scoreObj
.
cmptId
;
param
.
roadId
=
score
.
$data
.
selectedRoadId
;
param
.
markNo
=
scoreObj
.
markNo
;
param
.
scoreId
=
scoreObj
.
cmptScoreRuleScoreinfoId
;
param
.
duration
=
time
;
param
.
doneTime
=
doneTime
+
" 00:00:00"
;
param
.
miles
=
miles
*
1000
;
console
.
log
(
JSON
.
stringify
(
param
));
if
(
score
.
$data
.
selectedOrigin
!=
1
){
let
details
=
parent
.
siblings
(
'.score-detail'
);
let
trs
=
details
.
find
(
'tbody tr'
);
param
.
details
=
[];
$
.
each
(
trs
,
function
(
i
,
e
)
{
let
detail
=
{};
let
checkPointId
=
$
(
e
).
attr
(
'checkpointid'
);
let
checkpointTimeId
=
$
(
e
).
attr
(
'checkpointtimeid'
);
let
time
=
$
(
e
).
find
(
'input'
).
val
();
detail
.
checkPointId
=
checkPointId
;
detail
.
checkpointTimeId
=
checkpointTimeId
;
if
(
time
){
detail
.
time
=
new
Date
().
getFullYear
()
+
"-"
+
time
;
param
.
details
.
push
(
detail
)
}
})
}
$
.
ajax
({
url
:
baseURL
+
"geexekscore/api/v1/cmpt-score-rule-scoreinfo/updateScore"
,
contentType
:
'application/json'
,
data
:
JSON
.
stringify
(
param
),
type
:
"post"
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
){
console
.
log
(
data
);
}
}
});
},
showDetail
:
function
(
id
,
event
,
markno
){
if
(
score
.
$data
.
selectedOrigin
==
1
)
return
;
if
(
$
(
event
.
currentTarget
).
find
(
'.score-detail-item'
).
length
>
0
){
score
.
getScoreById
(
id
).
scoreDetails
=
[];
return
;
}
$
.
ajax
({
url
:
baseURL
+
"geexekscore/api/v1/cmpt-score-rule-scoreinfo/getCmptScoreRuleScoreDetails?scoreId="
+
id
,
url
:
baseURL
+
"geexekscore/api/v1/cmpt-score-rule-scoreinfo/getCmptScoreRuleScoreDetails?"
+
"scoreId="
+
id
+
"&roadId="
+
score
.
$data
.
selectedRoadId
+
"&markNo="
+
markno
,
success
:
function
(
data
)
{
if
(
data
.
code
==
200
){
if
(
data
.
data
.
length
==
0
){
...
...
@@ -222,6 +276,7 @@ var reviewPage = {
if
(
data
.
code
==
200
){
$
.
each
(
data
.
data
.
records
,
function
(
i
,
e
)
{
e
.
scoreDetails
=
[];
e
.
save
=
true
;
});
score
.
$data
.
scores
=
data
.
data
.
records
;
score
.
$data
.
totalPage
=
data
.
data
.
total
;
...
...
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