(window.webpackJsonp=window.webpackJsonp||[]).push([["store-assessmentsSurveys"],{5906:function(s,t,n){"use strict";n.d(t,"f",(function(){return o})),n.d(t,"g",(function(){return r})),n.d(t,"e",(function(){return i})),n.d(t,"a",(function(){return d})),n.d(t,"m",(function(){return c})),n.d(t,"j",(function(){return m})),n.d(t,"d",(function(){return p})),n.d(t,"l",(function(){return _})),n.d(t,"i",(function(){return f})),n.d(t,"c",(function(){return l})),n.d(t,"k",(function(){return g})),n.d(t,"h",(function(){return w})),n.d(t,"b",(function(){return A}));t=n("bc3a");var e=n.n(t);const a="dp";function u(s){return s?"/"+s:""}async function o(s){return e.a.post(a+"/assessment-identities",s)}async function r(s,t,n=""){return e.a.get(a+"/program-section-module-assessments/"+s+u(n),{params:t})}async function i(s,t=""){return e.a.post(a+"/assessment-finisheds"+u(t),{dp_program_section_module_assessment_id:s})}async function d(s,t){return e.a.patch(a+"/assessment-finisheds/"+s,{comment:t})}async function c(s,t=""){return e.a.post(a+"/assessment-answers"+u(t),s)}async function m(s,t=""){const{dpAssessmentAnswer:n,...o}=s;return e.a.patch(a+"/assessment-answers/"+n+u(t),o)}async function p(s,t=""){return e.a.delete(a+"/assessment-answers/"+s+u(t))}async function _(s,t=""){return e.a.post(a+"/assessment-answers/multiple"+u(t),s)}async function f(s,t=""){const{dp_program_section_module_assessment_id:n,dpAssessmentQuestion:o,...r}=s;return e.a.patch(a+`/assessment-answers/${n}/`+o+u(t),r)}async function l(s,t,n=""){return e.a.delete(a+`/assessment-answers/${s}/`+t+u(n))}async function g(s,t=""){return e.a.post(a+"/assessment-custom-answers"+u(t),s)}async function w(s,t=""){const{dpAssessmentAnswer:n,...o}=s;return e.a.patch(a+"/assessment-custom-answers/"+n+u(t),o)}async function A(s,t=""){return e.a.delete(a+"/assessment-custom-answers/"+s+u(t))}},d20e:function(s,t,n){"use strict";n.r(t);var e=n("5906");t.default={namespaced:!0,state:{assestment:null,additionalAssestments:{},loadingAssestment:!0,guestUuid:null},getters:{getAssestmentId:s=>null==(s=s.assestment)?void 0:s.id},actions:{async getSingleAssestmentData({commit:s},t){return s("assestmentIsLoading"),t=await Object(e.g)(t.slug,t.params,t.uuid),s("setAssestment",t.data.data),s("assestmentNotLoading"),t},async getAdditionalAssestmentData({commit:s},t){return s("assestmentIsLoading"),t=await Object(e.g)(t.slug,t.params,t.uuid),s("setAdditionalAssestments",t.data.data),s("assestmentNotLoading"),t}},mutations:{assestmentIsLoading(s){s.loadingAssestment=!0},assestmentNotLoading(s){s.loadingAssestment=!1},setAssestment(s,t){s.assestment=t},setAdditionalAssestments(s,t){s.additionalAssestments={...s.additionalAssestments,[t.id]:t}},setGuestUuid(s,t){s.guestUuid=t},setOptionsQuestion(s,t){t.option.dp_assessment_user_answer={},Object.assign(t.option.dp_assessment_user_answer,t.data)},setMultipleQuestion(s,t){t.options.forEach(({option:s,dataOption:t})=>{s.dp_assessment_user_answer={},s.dp_assessment_user_answer=t})},setCustomQuestion(s,t){t.question.dp_assessment_user_custom_answer={},Object.assign(t.question.dp_assessment_user_custom_answer,t.data)},setCustomAttachmentQuestion(s,t){t.question.dp_assessment_user_custom_answer={},Object.assign(t.question.dp_assessment_user_custom_answer,t.data),t.question.dp_assessment_user_custom_answer.files=[]}}}}}]);