Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
kc9500
mobility-nudging
Commits
f7e762d3
Commit
f7e762d3
authored
Jul 08, 2018
by
Oruluk
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Basic embedding of LimeSurvey
parent
49df1fe8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
3 deletions
+10
-3
client/components/SurveyScreen/SurveyScreen.js
client/components/SurveyScreen/SurveyScreen.js
+10
-3
No files found.
client/components/SurveyScreen/SurveyScreen.js
View file @
f7e762d3
...
...
@@ -13,6 +13,7 @@ class SurveyScreen extends React.Component {
sessionId
:
this
.
props
.
match
.
params
.
sessionId
,
blockId
:
this
.
props
.
match
.
params
.
blockId
,
userId
:
this
.
props
.
viewer
.
user
.
id
,
iframeLoadCount
:
0
,
}
onSubmitHandler
=
(
ev
)
=>
{
...
...
@@ -21,13 +22,19 @@ class SurveyScreen extends React.Component {
// this.props.router.push(nextScreen);
}
onLoadChange
=
(
x
)
=>
{
var
nextScreen
=
`/done/
${
this
.
state
.
sessionId
}
/
${
this
.
state
.
blockId
}
`
//this.props.router.push(nextScreen);
const
iframeLoadCount
=
this
.
state
.
iframeLoadCount
+
1
this
.
setState
({
iframeLoadCount
:
iframeLoadCount
})
console
.
log
(
this
.
state
.
iframeLoadCount
)
// dirty hack
if
(
iframeLoadCount
==
2
){
var
nextScreen
=
`/done/
${
this
.
state
.
sessionId
}
/
${
this
.
state
.
blockId
}
`
this
.
props
.
router
.
push
(
nextScreen
);
}
}
render
()
{
const
lime_src
=
"
https://experiment123.limequery.com/464639?lang=en&id=
"
+
this
.
state
.
sessionId
+
"
|
"
+
this
.
state
.
blockId
...
...
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