Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
educationStu
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
向伟
educationStu
Commits
8d2b5eab
Commit
8d2b5eab
authored
Sep 17, 2021
by
罗超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
687098d6
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
272 additions
and
3 deletions
+272
-3
activity.js
src/api/activity.js
+1
-1
answerSee.vue
src/components/subject/answerSee.vue
+270
-0
activitySignUp.vue
src/pages/activity/activitySignUp.vue
+0
-1
requestMall.js
src/utils/requestMall.js
+1
-1
No files found.
src/api/activity.js
View file @
8d2b5eab
...
...
@@ -65,7 +65,7 @@ export function activitySignUp(data) {
*/
export
function
activityJoinList
(
data
)
{
return
request
({
url
:
'/AppletEducation/GetUserJoinActivityPageListJ
xh
'
,
url
:
'/AppletEducation/GetUserJoinActivityPageListJ
XH
'
,
method
:
'post'
,
data
})
...
...
src/components/subject/answerSee.vue
0 → 100644
View file @
8d2b5eab
<
template
>
<view>
<van-nav-bar
fixed
>
<template
#
left
>
<van-icon
name=
"cross"
style=
"font-size: 32rpx; color: #111"
@
click=
"back"
/>
</
template
>
<
template
#
title
>
<view
style=
"
font-size: 32rpx;
color: #111;
font-family: PingFang SC;
font-weight: 800;
"
>
答题卡
</view
>
</
template
>
</van-nav-bar>
<view
class=
"answer-sheets"
>
<view
v-for=
"(item, index) in questionList"
:key=
"index"
class=
"item"
>
<view
class=
"name"
>
{{ changeNumToHan(index + 1) }}、{{ item.GroupName }}
</view
>
<view
class=
"flex flex_wrap"
>
<view
v-for=
"(item1, index1) in item.DetailsList"
:key=
"index1"
class=
"flex flex_wrap"
>
<view
class=
"item1-1"
v-if=
"
item1.QuestionTypeKey === 'reading-comprehensio' ||
item1.QuestionTypeKey === 'listening'
"
@
click=
"chooseTopic(index, index1)"
>
{{ index1 + 1 }}.
</view
>
<view
class=
"item1"
:class=
"{ isRes: item1.IsRes }"
v-else
@
click=
"chooseTopic(index, index1)"
>
{{ index1 + 1 }}
</view
>
<view
v-if=
"
item1.QuestionTypeKey === 'reading-comprehensio' ||
item1.QuestionTypeKey === 'listening'
"
class=
"flex flex_wrap"
>
<view
v-for=
"(item2, index2) in item1.QuestionContentObj"
:key=
"index2"
>
<view
class=
"item1"
:class=
"{ isRes: item2.IsRes }"
@
click=
"chooseTopic(index, index1)"
>
{{ index2 + 1 }}
</view
>
</view>
</view>
</view>
</view>
</view>
</view>
<view
class=
"submitBox"
v-if=
"ExamStatus === 1"
>
<view
class=
"submit"
@
click=
"savePaper"
>
立即提交
</view>
</view>
<van-toast
id=
"van-toast"
/>
</view>
</template>
<
script
>
import
{
ref
,
reactive
,
toRefs
,
toRef
,
getCurrentInstance
,
watch
,
computed
,
onMounted
,
}
from
"vue"
;
import
{
changeNumToHan
}
from
"../../utils/index"
;
import
{
submitPaper
}
from
"../../api/exam"
;
export
default
{
props
:
{
paperData
:
Object
,
ExamStuId
:
Number
,
SubmitTimes
:
Number
,
StartTime
:
String
,
ExamStatus
:
Number
,
},
setup
(
props
,
ctx
)
{
let
Gid
=
uni
.
getStorageSync
(
"userInfo"
).
Id
;
let
data
=
reactive
({
msg
:
{
GuestId
:
Gid
,
PaperId
:
5
,
PublishId
:
1
},
questionList
:
props
.
paperData
.
Paper
.
GroupList
,
});
console
.
log
(
108
,
props
.
paperData
);
let
methods
=
{
changeNumToHan
,
chooseTopic
(
index
,
index1
,
index2
)
{
ctx
.
emit
(
"chooseTopic"
,
{
index
,
index1
,
index2
,
});
},
//隐藏答题卡
back
()
{
ctx
.
emit
(
"hideAnswer"
);
},
getNowTime
()
{
let
dateTime
;
let
yy
=
new
Date
().
getFullYear
();
let
mm
=
new
Date
().
getMonth
()
+
1
;
let
dd
=
new
Date
().
getDate
();
let
hh
=
new
Date
().
getHours
();
let
mf
=
new
Date
().
getMinutes
()
<
10
?
"0"
+
new
Date
().
getMinutes
()
:
new
Date
().
getMinutes
();
let
ss
=
new
Date
().
getSeconds
()
<
10
?
"0"
+
new
Date
().
getSeconds
()
:
new
Date
().
getSeconds
();
dateTime
=
yy
+
"-"
+
mm
+
"-"
+
dd
+
" "
+
hh
+
":"
+
mf
+
":"
+
ss
;
return
dateTime
;
},
//交卷
async
savePaper
()
{
let
obj
=
JSON
.
parse
(
JSON
.
stringify
(
props
.
paperData
.
Paper
));
delete
obj
.
Group_Id
;
obj
.
Exam_Student_Id
=
props
.
ExamStuId
;
let
time1
=
props
.
StartTime
;
let
time2
=
methods
.
getNowTime
();
var
d1
=
new
Date
(
time1
);
var
d2
=
new
Date
(
time2
);
let
TimeDis
=
parseInt
(
d2
-
d1
)
/
1000
/
60
;
if
(
TimeDis
<
props
.
SubmitTimes
)
{
uni
.
showToast
({
title
:
`开场不足
${
props
.
SubmitTimes
}
分钟禁止交卷哦~`
,
icon
:
"none"
,
});
return
;
}
let
res
=
await
submitPaper
(
obj
);
if
(
res
)
{
if
(
res
.
Code
==
1
)
{
uni
.
showToast
({
title
:
res
.
Message
,
icon
:
"none"
,
});
setTimeout
(()
=>
{
uni
.
navigateTo
({
url
:
"/pages/index/index"
,
});
},
1000
);
}
}
},
};
return
{
...
toRefs
(
data
),
...
methods
,
};
},
};
</
script
>
<
style
scoped
>
.answer-sheets
{
box-sizing
:
border-box
;
padding
:
30
rpx
;
height
:
calc
(
100vh
-
300
rpx
);
overflow-y
:
auto
;
}
.name
,
.num
{
font-size
:
28
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
800
;
color
:
#111111
;
}
.num
{
width
:
100
rpx
;
text-align
:
center
;
}
.item
{
margin-bottom
:
20
rpx
;
}
.item1-1
{
width
:
690
rpx
;
margin
:
22
rpx
0
0
0
;
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
600
;
color
:
#111111
;
}
.item1
{
width
:
44
rpx
;
height
:
44
rpx
;
border
:
1px
solid
#e2e2e2
;
border-radius
:
50%
;
margin
:
22
rpx
;
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
600
;
color
:
#111111
;
display
:
flex
;
justify-content
:
center
;
align-items
:
center
;
box-sizing
:
border-box
;
}
.item2
{
width
:
44
rpx
;
height
:
44
rpx
;
border
:
1px
solid
#e2e2e2
;
border-radius
:
50%
;
text-align
:
center
;
line-height
:
44
rpx
;
margin-right
:
55
rpx
;
font-size
:
26
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
bold
;
color
:
#111111
;
}
.choose
{
background-color
:
#00acf9
!important
;
color
:
#ffffff
!important
;
}
.submitBox
{
width
:
750
rpx
;
height
:
150
rpx
;
background-color
:
#e2e2e2
;
position
:
fixed
;
left
:
0
;
bottom
:
0
;
box-sizing
:
border-box
;
padding-top
:
40
rpx
;
}
.submit
{
width
:
600
rpx
;
height
:
70
rpx
;
border-radius
:
35
rpx
;
display
:
flex
;
justify-content
:
center
;
align-items
:
center
;
background-color
:
#00acf9
;
font-size
:
28
rpx
;
font-family
:
PingFang
SC
;
font-weight
:
bold
;
color
:
#fff
;
margin
:
0
auto
;
}
.isRes
{
background-color
:
#00acf9
!important
;
color
:
#ffffff
!important
;
border
:
none
!important
;
}
</
style
>
src/pages/activity/activitySignUp.vue
View file @
8d2b5eab
...
...
@@ -183,7 +183,6 @@ export default {
TotalPoint
:
0
,
Sex
:
userinfo
.
StuSex
+
1
,
StuBirth
:
userinfo
.
StuBirth
,
EduStudentId
:
userinfo
.
Id
,
},
list
:
[
{
name
:
"在线支付"
,
Id
:
1
,
disabled
:
false
},
...
...
src/utils/requestMall.js
View file @
8d2b5eab
...
...
@@ -22,7 +22,7 @@ let request = (param) => {
MallBaseId
:
parseInt
(
JHdata
.
JHMallBaseId
),
UserId
:
JHdata
.
JHMallUserId
,
TenantId
:
parseInt
(
JHdata
.
JHTenantId
),
StudentId
:
JHdata
.
Id
,
Edu
StudentId
:
JHdata
.
Id
,
OpenId
:
JHdata
.
JHMallUserOpenId
,
SmallShopsId
:
0
,
MiniAppId
:
"wx38e054ee42b054f4"
,
...
...
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