\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n\r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ item.name }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n {{ $t(\"register.form.backButton\") }}\r\n \r\n \r\n mdi-content-save{{ $t(\"onboarding.deviceSetup.save\") }}\r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n \r\n \r\n\r\n \r\n \r\n \r\n {{ $t(\"register.form.confirm.continue\") }}\r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n {{ snackbarText }}\r\n {{\r\n $t(\"onboarding.deviceSetup.close\")\r\n }}\r\n \r\n
\r\n\r\n\r\n\r\n","import mod from \"-!../../../node_modules/cache-loader/dist/cjs.js??ref--12-0!../../../node_modules/thread-loader/dist/cjs.js!../../../node_modules/babel-loader/lib/index.js!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./DeviceSetup.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../../node_modules/cache-loader/dist/cjs.js??ref--12-0!../../../node_modules/thread-loader/dist/cjs.js!../../../node_modules/babel-loader/lib/index.js!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./DeviceSetup.vue?vue&type=script&lang=js&\"","import { render, staticRenderFns } from \"./DeviceSetup.vue?vue&type=template&id=75357215&\"\nimport script from \"./DeviceSetup.vue?vue&type=script&lang=js&\"\nexport * from \"./DeviceSetup.vue?vue&type=script&lang=js&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports\n\n/* vuetify-loader */\nimport installComponents from \"!../../../node_modules/vuetify-loader/lib/runtime/installComponents.js\"\nimport { VBtn } from 'vuetify/lib/components/VBtn';\nimport { VCard } from 'vuetify/lib/components/VCard';\nimport { VCardActions } from 'vuetify/lib/components/VCard';\nimport { VCardSubtitle } from 'vuetify/lib/components/VCard';\nimport { VCardText } from 'vuetify/lib/components/VCard';\nimport { VCardTitle } from 'vuetify/lib/components/VCard';\nimport { VCol } from 'vuetify/lib/components/VGrid';\nimport { VDivider } from 'vuetify/lib/components/VDivider';\nimport { VForm } from 'vuetify/lib/components/VForm';\nimport { VIcon } from 'vuetify/lib/components/VIcon';\nimport { VListItem } from 'vuetify/lib/components/VList';\nimport { VListItemContent } from 'vuetify/lib/components/VList';\nimport { VListItemTitle } from 'vuetify/lib/components/VList';\nimport { VRow } from 'vuetify/lib/components/VGrid';\nimport { VSelect } from 'vuetify/lib/components/VSelect';\nimport { VSnackbar } from 'vuetify/lib/components/VSnackbar';\nimport { VSpacer } from 'vuetify/lib/components/VGrid';\ninstallComponents(component, {VBtn,VCard,VCardActions,VCardSubtitle,VCardText,VCardTitle,VCol,VDivider,VForm,VIcon,VListItem,VListItemContent,VListItemTitle,VRow,VSelect,VSnackbar,VSpacer})\n","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('v-card',{attrs:{\"flat\":\"\"}},[_c('ValidationObserver',{ref:\"observer\",scopedSlots:_vm._u([{key:\"default\",fn:function(ref){\nvar invalid = ref.invalid;\nvar passes = ref.passes;\nreturn [_c('v-card-subtitle',{staticClass:\"greytext--text\",domProps:{\"innerHTML\":_vm._s(_vm.$t('onboarding.verify.title'))}}),_c('v-card-text',[_c('ValidationProvider',{attrs:{\"vid\":\"credentialsEmail\"},scopedSlots:_vm._u([{key:\"default\",fn:function(ref){\nvar errors = ref.errors;\nreturn [_c('VTextFieldWithValidation',{attrs:{\"clearable\":\"\",\"rules\":\"required|email\",\"label\":_vm.$t('onboarding.verify.email'),\"error\":errors.length > 0},model:{value:(_vm.email),callback:function ($$v) {_vm.email=$$v},expression:\"email\"}})]}}],null,true)}),_c('ValidationProvider',{attrs:{\"vid\":\"credentialsPassword\"},scopedSlots:_vm._u([{key:\"default\",fn:function(ref){\nvar errors = ref.errors;\nreturn [_c('VTextFieldWithValidation',{attrs:{\"clearable\":\"\",\"rules\":\"required|min:8\",\"counter\":\"\",\"label\":_vm.$t('onboarding.verify.password'),\"append-icon\":_vm.showpassword ? 'mdi-eye' : 'mdi-eye-off',\"type\":_vm.showpassword ? 'text' : 'password',\"hint\":_vm.$t('onboarding.data.min8'),\"error\":errors.length > 0},on:{\"click:append\":function($event){_vm.showpassword = !_vm.showpassword}},model:{value:(_vm.password),callback:function ($$v) {_vm.password=$$v},expression:\"password\"}}),_c('span',{staticClass:\"red--text\"},[_vm._v(_vm._s(errors[0]))])]}}],null,true)})],1),_c('v-card-actions',[_c('v-row',{staticClass:\"mx-auto\"},[_c('v-col',{attrs:{\"cols\":\"8\"}},[_c('v-text-field',{staticClass:\"rafiTextField\",attrs:{\"hint\":_vm.$t('spamProtection.description'),\"outlined\":\"\",\"dense\":\"\"},on:{\"input\":_vm.spamProtectionAnswerChanged},scopedSlots:_vm._u([{key:\"prepend-inner\",fn:function(){return [_c('span',{staticClass:\"text-no-wrap mt-1\"},[_vm._v(_vm._s(_vm.$t(\"spamProtection.label\"))+\" \"+_vm._s(_vm.spamProtectionAnswer.summandLeft)+\" + \"+_vm._s(_vm.spamProtectionAnswer.summandRight)+\" =\")])]},proxy:true}],null,true),model:{value:(_vm.spamProtectionEntry),callback:function ($$v) {_vm.spamProtectionEntry=$$v},expression:\"spamProtectionEntry\"}})],1),_c('v-col',{attrs:{\"cols\":\"4\"}},[_c('v-btn',{staticClass:\"rafiButton petrol white--text mt-1\",attrs:{\"tile\":\"\",\"elevation\":\"0\",\"loading\":_vm.iswaitingForBackend,\"disabled\":invalid || !_vm.spamProtectionAnswerValid},on:{\"click\":function($event){return passes(_vm.submit)}}},[_vm._v(\" \"+_vm._s(_vm.$t(\"onboarding.form.verify\"))+\" \")])],1)],1)],1)]}}])})],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import axios from \"axios\";\r\nimport i18n from \"../i18n\";\r\n\r\n//returns onboarding token for device or null\r\n//pass email and password\r\nasync function getToken(email, password, spamProtectionAnswer) \r\n{\r\n spamProtectionAnswer.sum = Number(spamProtectionAnswer.sum);\r\n\r\n //set content\r\n let body = { email: email, password: password, spamProtectionAnswer: spamProtectionAnswer };\r\n\r\n //request\r\n const token = await axios\r\n .post(`/Onboarding`, body)\r\n .then(response => {\r\n return response;\r\n })\r\n .catch((error) => { \r\n if(error.message == \"Request failed with status code 400\")\r\n {\r\n error.message = i18n.t(\"onboarding.permissionFailed\");\r\n }\r\n return error;\r\n });\r\n\r\n return token;\r\n}\r\n\r\nexport default { getToken };\r\n","