Fairoj : extras keys added for covid 19 ques

This commit is contained in:
venbatechnologies@gmail.com 2020-07-29 15:28:01 +05:30
parent e705d273e0
commit f1b7fc4261

View File

@ -384,7 +384,8 @@ export class QueriesDocsComponent implements OnInit {
if(this.questions_JSON.questions.length > 0) {
let geneatedQues = this.questions_JSON.questions.filter(val=>val.is_repeatable != '1').map(vv=>{
return {question_key:vv.question_key,question:vv.question,is_repeatable:'0',type:vv.type}
return {question_key:vv.question_key,question:vv.question,is_repeatable:'0',type:vv.type ,is_subfield:vv.hasOwnProperty('is_subfield') ? vv.is_subfield : '0'
,parent_question_key:vv.hasOwnProperty('parent_question_key') ? vv.parent_question_key : ''}
})
let covidFormAnswers = this.covid19QuesForm.getRawValue()
covidFormAnswers.question_info = geneatedQues