Skip to content
GitLab
Explore
Projects
Groups
Topics
Snippets
Projects
Groups
Topics
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Register
Sign in
Toggle navigation
Menu
UPSMF
program-service
Commits
ff99b549
Commit
ff99b549
authored
3 years ago
by
snehar-nd
Browse files
Options
Download
Patches
Plain Diff
Fix for Instructions in question paper(Instruction values are missing sometimes.)
parent
d579e319
release-5.1.0
dependabot/npm_and_yarn/src/async-2.6.4
dependabot/npm_and_yarn/src/axios-0.21.2
dependabot/npm_and_yarn/src/decode-uri-component-0.2.2
dependabot/npm_and_yarn/src/jsonwebtoken-9.0.0
dependabot/npm_and_yarn/src/lodash-4.17.21
dependabot/npm_and_yarn/src/moment-2.29.4
dependabot/npm_and_yarn/src/moment-timezone-0.5.37
dependabot/npm_and_yarn/src/node-fetch-2.6.7
dependabot/npm_and_yarn/src/qs-and-body-parser-and-express-6.5.3
dependabot/npm_and_yarn/src/redis-3.1.1
dependabot/npm_and_yarn/src/simple-get-2.8.2
dependabot/npm_and_yarn/src/underscore-1.12.1
master
release-4.6.0
release-4.7.0
release-4.8.0
release-4.9.0
release-5.1.0_RC1
release-4.9.0_RC1
release-4.8.0_RC3
release-4.8.0_RC2
release-4.8.0_RC1
release-4.7.0_RC6
release-4.7.0_RC5
release-4.7.0_RC4
release-4.7.0_RC3
release-4.7.0_RC2
release-4.7.0_RC1
release-4.6.0_RC6
release-4.6.0_RC5
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/service/print/printDocxV1.0/dataImporter.js
+4
-13
src/service/print/printDocxV1.0/dataImporter.js
src/service/print/printDocxV1.0/docx.js
+1
-1
src/service/print/printDocxV1.0/docx.js
with
5 additions
and
14 deletions
+5
-14
src/service/print/printDocxV1.0/dataImporter.js
+
4
−
13
View file @
ff99b549
...
@@ -45,7 +45,7 @@ const getQuestionSet = async (id) => {
...
@@ -45,7 +45,7 @@ const getQuestionSet = async (id) => {
headers
,
headers
,
};
};
return
axios
(
request
).
then
((
r
)
=>
{
return
axios
(
request
).
then
(
async
(
r
)
=>
{
const
data
=
r
.
data
.
result
.
questionSet
;
const
data
=
r
.
data
.
result
.
questionSet
;
let
sections
;
let
sections
;
if
(
data
&&
"
children
"
in
data
)
sections
=
data
.
children
;
if
(
data
&&
"
children
"
in
data
)
sections
=
data
.
children
;
...
@@ -65,17 +65,8 @@ const getQuestionSet = async (id) => {
...
@@ -65,17 +65,8 @@ const getQuestionSet = async (id) => {
});
});
else
return
[];
else
return
[];
});
// Hierarchy
});
// Hierarchy
const
instructions
=
getQuestionForSet
(
id
).
then
((
resp
)
=>
{
const
instructions
=
await
getQuestionForSet
(
id
);
return
resp
.
instructions
.
default
;
});
var
introData
instructions
.
then
((
result
)
=>
{
introData
=
result
})
const
promiseMap
=
questionIds
.
map
((
sec
)
=>
const
promiseMap
=
questionIds
.
map
((
sec
)
=>
sec
.
map
((
question
)
=>
{
sec
.
map
((
question
)
=>
{
...
@@ -109,7 +100,7 @@ const getQuestionSet = async (id) => {
...
@@ -109,7 +100,7 @@ const getQuestionSet = async (id) => {
return
{
return
{
sectionData
,
sectionData
,
paperData
:
data
,
paperData
:
data
,
instructions
:
intr
oData
instructions
:
in
s
tr
uctions
.
instructions
.
default
};
};
});
});
});
});
...
...
This diff is collapsed.
Click to expand it.
src/service/print/printDocxV1.0/docx.js
+
1
−
1
View file @
ff99b549
...
@@ -20,11 +20,11 @@ const buildDOCX_1_WithCallback = async (id, callback) => {
...
@@ -20,11 +20,11 @@ const buildDOCX_1_WithCallback = async (id, callback) => {
callback
(
null
,
data
.
error
,
data
.
errorMsg
);
callback
(
null
,
data
.
error
,
data
.
errorMsg
);
}
else
{
}
else
{
let
subject
,
grade
,
examName
,
instructions
,
language
,
description
;
let
subject
,
grade
,
examName
,
instructions
,
language
,
description
;
if
(
data
.
instructions
)
instructions
=
data
.
instructions
;
if
(
data
.
paperData
)
{
if
(
data
.
paperData
)
{
subject
=
data
.
paperData
.
subject
&&
data
.
paperData
.
subject
[
0
];
subject
=
data
.
paperData
.
subject
&&
data
.
paperData
.
subject
[
0
];
grade
=
data
.
paperData
.
gradeLevel
&&
data
.
paperData
.
gradeLevel
[
0
];
grade
=
data
.
paperData
.
gradeLevel
&&
data
.
paperData
.
gradeLevel
[
0
];
examName
=
data
.
paperData
.
name
;
examName
=
data
.
paperData
.
name
;
instructions
=
data
.
instructions
;
language
=
data
.
paperData
.
medium
&&
data
.
paperData
.
medium
[
0
];
language
=
data
.
paperData
.
medium
&&
data
.
paperData
.
medium
[
0
];
}
}
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Topics
Snippets