![]() Server : Apache System : Linux server2.corals.io 4.18.0-348.2.1.el8_5.x86_64 #1 SMP Mon Nov 15 09:17:08 EST 2021 x86_64 User : corals ( 1002) PHP Version : 7.4.33 Disable Function : exec,passthru,shell_exec,system Directory : /home/corals/vreg/node_modules/.cache/nuxt/dist/server/pages/pa/ |
{"version":3,"file":"pages/pa/verify.js","sources":["webpack:///./pages/pa/verify.vue?bdc8","webpack:///./pages/pa/verify.vue?2bdb","webpack:///./pages/pa/verify.vue?e2be","webpack:///./pages/pa/verify.vue?d982","webpack:///./pages/pa/verify.vue","webpack:///./pages/pa/verify.vue?9301","webpack:///./pages/pa/verify.vue?9e1a","webpack:///./components/Forms/InputField.vue?b99a","webpack:///./components/Forms/InputField.vue","webpack:///./components/Forms/InputField.vue?b7d9","webpack:///./components/Forms/InputField.vue?be57","webpack:///./components/Forms/InputField.vue?bf7d","webpack:///./components/Forms/FormErrorMsg.vue?9f25","webpack:///./mixins/forms.js","webpack:///./components/Forms/FormErrorMsg.vue?497a","webpack:///./components/Forms/FormErrorMsg.vue","webpack:///./components/Forms/FormErrorMsg.vue?5544","webpack:///./components/Forms/FormErrorMsg.vue?6e2b","webpack:///./components/Forms/InputField.vue?db84","webpack:///./components/Forms/InputField.vue?fbac","webpack:///./components/Forms/FormErrorMsg.vue?6c28","webpack:///./components/Forms/FormErrorMsg.vue?d1be"],"sourcesContent":["// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../node_modules/css-loader/dist/cjs.js??ref--3-oneOf-1-1!../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../node_modules/postcss-loader/src/index.js??ref--3-oneOf-1-2!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./verify.vue?vue&type=style&index=0&lang=css&\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add CSS to SSR context\nvar add = require(\"!../../node_modules/vue-style-loader/lib/addStylesServer.js\").default\nmodule.exports.__inject__ = function (context) {\n add(\"f52cc9b6\", content, true, context)\n};","export * from \"-!../../node_modules/vue-style-loader/index.js??ref--3-oneOf-1-0!../../node_modules/css-loader/dist/cjs.js??ref--3-oneOf-1-1!../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../node_modules/postcss-loader/src/index.js??ref--3-oneOf-1-2!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./verify.vue?vue&type=style&index=0&lang=css&\"","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../node_modules/css-loader/dist/runtime/api.js\");\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(false);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, \".loading{min-height:457px;background:#f0f4f8;padding:40px 0 50px}.loading-box{max-width:580px;margin:0 auto;border-radius:4px;box-shadow:0 5px 15px rgba(0,0,0,.15);padding:25px 40px 32px}.loading-bar,.loading-box{width:100%;background:#fff}.loading-bar{border:1px solid #9ca3b5;border-radius:4px;height:8px;position:relative;margin-bottom:36px}@-webkit-keyframes progress-animation{0%{width:0}20%{width:14%}55%{width:41.2%}to{width:85.4%}}@keyframes progress-animation{0%{width:0}20%{width:14%}55%{width:41.2%}to{width:85.4%}}@-webkit-keyframes complete-progress-animation{0%{width:85.4%}20%{width:95%}55%{width:99%}to{width:100%}}@keyframes complete-progress-animation{0%{width:85.4%}20%{width:95%}55%{width:99%}to{width:100%}}.loading-bar .inner{position:absolute;left:-1px;top:-1px;height:8px;background:#006bcd;border-radius:4px;width:85.4%;-webkit-animation:progress-animation 10s ease-in-out;animation:progress-animation 10s ease-in-out}.loading-bar .inner.completed{width:calc(100% + 2px);-webkit-animation:complete-progress-animation 2s ease-in-out;animation:complete-progress-animation 2s ease-in-out}.loading-step{border:1px solid #9ca3b5;background:#fff;border-radius:4px;margin-bottom:15px;position:relative;padding:13px 45px 14px 18px;transition:all .3s ease-in}.loading-step p{margin:0;color:#1d2e59}.loading-step .error-image{width:16px;height:16px}.loading-step .error-image,.loading-step .loading-image{position:absolute;right:3px;top:50%;transform:translateY(-50%);opacity:1;transition:all .3s ease-in}.loading-step .error-image,.loading-step .loaded-image{position:absolute;right:12px;top:47%;transform:translateY(-50%);opacity:0;transition:all .3s ease-in}.loading-step.done{border:1px solid #4bbf64}.loading-step.done .loading-image,.loading-step.error .loading-image{opacity:0}.loading-step.done .loaded-image,.loading-step.error .error-image{opacity:1}@media only screen and (max-width:767px){.loading-box{padding:25px 20px 32px}}\", \"\"]);\n// Exports\nmodule.exports = ___CSS_LOADER_EXPORT___;\n","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',[_vm._ssrNode(\"<h1>Verify</h1> <p class=\\\"description\\\">Verifying information ...</p> <div class=\\\"loading-bar\\\"><div\"+(_vm._ssrClass(\"inner\",_vm.loadingBarInnerClass))+\"></div></div> \"+(_vm._ssrList((_vm.steps),function(step){return (((step.status !== 'pending')?(\"<div\"+(_vm._ssrClass(\"loading-step\",step.status))+\"><p>\"+_vm._ssrEscape(_vm._s(step.status !== 'done'?step.waiting_text:step.done_text))+\"</p> \"+((step.hint_text)?(\"<small>\"+_vm._ssrEscape(_vm._s(step.hint_text))+\"</small>\"):\"<!---->\")+\" <img src=\\\"/images/verify/loading-blue.gif\\\" alt=\\\"Loading\\\" class=\\\"loading-image\\\"> <img src=\\\"/images/verify/form-tick.svg\\\" alt=\\\"Loaded\\\" class=\\\"loaded-image\\\"> <img src=\\\"/images/verify/cross.svg\\\" alt=\\\"Loaded\\\" class=\\\"error-image\\\"></div>\"):\"<!---->\"))}))+\" \"),(_vm.showErrorMessage)?_vm._ssrNode(\"<div class=\\\"text-danger\\\">\",\"</div>\",[_vm._ssrNode(\"<h6>\"+_vm._ssrEscape(_vm._s(_vm.errorMessage))+\"</h6> \"),_c('nuxt-link',{staticClass:\"btn-back\",attrs:{\"to\":\"/florida/step-1\"}},[_c('svg',{attrs:{\"width\":\"12\",\"height\":\"10\",\"viewBox\":\"0 0 12 10\",\"fill\":\"none\",\"xmlns\":\"http://www.w3.org/2000/svg\"}},[_c('path',{attrs:{\"d\":\"M11 5.6C11.3314 5.6 11.6 5.33137 11.6 5C11.6 4.66863 11.3314 4.4 11 4.4L11 5.6ZM0.575736 4.57574C0.341421 4.81005 0.341421 5.18995 0.575736 5.42427L4.39411 9.24264C4.62843 9.47696 5.00833 9.47696 5.24264 9.24264C5.47696 9.00833 5.47696 8.62843 5.24264 8.39411L1.84853 5L5.24264 1.60589C5.47696 1.37157 5.47695 0.991675 5.24264 0.75736C5.00833 0.523045 4.62843 0.523045 4.39411 0.75736L0.575736 4.57574ZM11 4.4L1 4.4L1 5.6L11 5.6L11 4.4Z\",\"fill\":\"#1D2E59\"}})]),_vm._v(\"\\n Go back and try again\\n \")])],2):_vm._e()],2)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\n\nimport forms from \"@/mixins/forms\";\n\nexport default {\n name: \"verify\",\n mixins: [forms],\n middleware({store: {state}, redirect, route: {path}}) {\n if (Object.keys(state.step3Form).length === 0) {\n return redirect('/pa/step-1');\n }\n },\n data() {\n return {\n loadingBarInnerClass: '',\n showErrorMessage: false,\n errorMessage: 'Sorry, something went wrong!!',\n steps: {\n verify_information: {\n status: 'in_progress',\n waiting_text: 'Your information is being verified',\n done_text: 'Your information is verified',\n },\n searching_vehicle: {\n status: 'pending',\n waiting_text: 'Searching database for vehicle to renew',\n done_text: 'Vehicle found in database',\n },\n finalizing_app: {\n status: 'pending',\n waiting_text: 'Finalizing application',\n hint_text: 'Do not click Back or Refresh.',\n done_text: 'Your application is ready',\n },\n },\n verifyInformation: null,\n searchingVehicle: null,\n }\n },\n mounted() {\n this.verifyInformation = setTimeout(() => {\n this.steps.searching_vehicle.status = 'in_progress';\n this.steps.verify_information.status = 'done';\n }, 5000);\n\n this.searchingVehicle = setTimeout(() => {\n this.steps.finalizing_app.status = 'in_progress';\n this.steps.searching_vehicle.status = 'done';\n }, 10000);\n\n let orderId = this.$store.state.orderId,\n url = process.env.get_estimates_api + '/' + orderId;\n\n\n return setTimeout(() => {\n this.dummyPrices();\n }, 1000);\n\n this.$axios.get(url).then(({data}) => {\n this.completeSteps();\n if (data.status === 'success') {\n this.steps.finalizing_app.status = 'done';\n this.redirectSuccessStatus(data);\n } else {\n this.goManual();\n }\n }).catch((error) => {\n this.goManual();\n });\n },\n methods: {\n goManual() {\n this.completeSteps();\n this.$store.commit('SET_ORIGINAL_ORDER_TYPE', 'manual')\n this.redirectSuccessStatus({\n \"status\": \"success\",\n \"estimates\": []\n });\n },\n redirectSuccessStatus(data) {\n let prices = this.getPrices(data),\n path = '/pa/select-offline-plates',\n isEmptyEstimates = false;\n\n // if we don't have any estimate, go and fill manually.\n //otherwise select from incoming estimates.\n if (this.arePricesEmpty(prices)) {\n //if we don't have any plates\n if (!this.$store.state.offlineFormPlates.length) {\n this.$store.commit('SET_OFFLINE_FORM_PLATE', this.getPricePlaceholder());\n this.$store.commit('SET_ORIGINAL_ORDER_TYPE', 'manual')\n }\n isEmptyEstimates = true;\n path = '/pa/step-4';\n }\n\n\n this.$store.commit('SET_EMPTY_ESTIMATES', isEmptyEstimates);\n\n this.$store.commit('SET_FORM_FLOW', 'offline');\n\n this.storeSavedSession('verify', path, {\n form_flow: this.$store.state.formFlow,\n empty_estimates: this.$store.state.emptyEstimates,\n original_order_type: this.$store.state.originalOrderType,\n prices: prices\n })\n\n },\n arePricesEmpty(prices) {\n return (Array.isArray(prices) && prices.length === 0)\n || (prices.constructor === Object && Object.keys(prices).length === 0)\n },\n dummyPrices() {\n let data = {\n \"status\": \"success\",\n \"estimates\": [\n {\n \"estimates\": [\n \"Renew this Registration for Vehicle for 2 years -- $92.95\",\n \"Renew this Registration for Vehicle for 1 year -- $46.85\",\n \"Get a Duplicate Registration -- $3.75 ( *** NO DECAL will be issued ***)\",\n \"Take No Action\"\n ],\n \"license_make\": \"(KIA)\",\n \"license_plate\": \"JR16R\",\n \"license_expiry\": \"8/28/2021\",\n \"offline_processing\": \"false\"\n },\n {\n \"estimates\": [\n \"Renew this Registration for Vehicle for 2 years -- $92.95\",\n \"Renew this Registration for Vehicle for 1 year -- $46.85\",\n \"Get a Duplicate Registration -- $3.75 ( *** NO DECAL will be issued ***)\",\n \"Take No Action\"\n ],\n \"license_make\": \"(FORD MOTOR COMPANY)\",\n \"license_plate\": \"PJBW88\",\n \"license_expiry\": \"8/28/2020\",\n \"offline_processing\": \"false\"\n },\n {\n \"estimates\": [\n \"Get a Duplicate Registration -- $3.75 ( *** NO DECAL will be issued ***)\",\n \"Take No Action\"\n ],\n \"license_make\": \"(ARISING INDUSTRIES, INC.)\",\n \"license_plate\": \"Y314IK\",\n \"license_expiry\": \"8/28/2022\",\n \"offline_processing\": \"false\"\n }\n ]\n };\n this.redirectSuccessStatus(data);\n },\n getPricePlaceholder() {\n return {\n index: 0,\n 'license_plate': '',\n 'license_make': '',\n 'license_plate_label': '',\n offline_processing: true,\n 'prices': [{\n price: ''\n }],\n }\n },\n completeSteps() {\n clearTimeout(this.verifyInformation);\n clearTimeout(this.searchingVehicle);\n this.steps.searching_vehicle.status = 'done';\n this.steps.verify_information.status = 'done';\n this.loadingBarInnerClass = 'completed';\n },\n getPrices(data) {\n let prices = {};\n\n data.estimates.forEach((license) => {\n let hasOffline = this.isLicenseOffline(license);\n\n if (!license.estimates.length && !hasOffline) {\n return;\n }\n prices[license.license_plate] = {\n 'license_plate': license.license_plate,\n 'license_make': license.license_make ? license.license_make.replace(/[()]/g, '') : '',\n 'license_plate_label': license.license_plate,\n 'prices': [],\n };\n\n if (license.license_expiry) {\n prices[license.license_plate]['license_plate_label'] = `${license.license_plate} - Expires ${license.license_expiry}`;\n prices[license.license_plate]['expires_on'] = license.license_expiry;\n }\n\n prices[license.license_plate]['offline_processing'] = true;\n\n let priceIndex = 0;\n\n license.estimates.forEach((text) => {\n\n if (this.includeEstimate(text)) {\n if (!text.includes('--')) {\n return;\n }\n\n let split = text.split(\"--\"),\n formatted_priceSplit = split[1].trim(),\n secondSplit = formatted_priceSplit.split(' ('),\n formatted_price = secondSplit[0].trim(),\n description = split[0].trim() + (secondSplit.length > 1 ? (' (' + secondSplit[1]) : ''),\n renewal_type;\n\n if (text.indexOf('1 year') >= 0) {\n description = `1-Year Renewal`;\n renewal_type = 'one_year';\n } else if (text.indexOf('2 years') >= 0) {\n description = `2-Years Renewal`;\n renewal_type = 'two_years';\n }\n\n prices[license.license_plate]['prices'].push({\n key: license.license_plate + '_' + priceIndex,\n license_plate: license.license_plate,\n estimate: text,\n renewal_type: renewal_type,\n description: description,\n formatted_price: formatted_price,\n price: formatted_price.match(/\\d+(?:\\.\\d+)?/g)[0],\n });\n\n priceIndex++;\n }\n });\n });\n\n\n prices = this.clearEmptyPrices(prices);\n prices = this.orderPricesByExpiresOn(prices);\n\n this.$store.commit('SET_OFFLINE_API_PLATES', prices);\n\n return prices;\n },\n orderPricesByExpiresOn(prices, dir = 'desc') {\n return _.orderBy(prices, (item) => {\n let expires_on = item['expires_on'] || this.$moment().subtract(100, 'y');\n return this.$moment(expires_on).unix();\n }, dir);\n },\n clearEmptyPrices(prices) {\n\n for (let priceKey in prices) {\n if (!prices[priceKey].prices || !prices[priceKey].prices.length) {\n delete prices[priceKey];\n }\n }\n\n return prices;\n },\n shouldConsiderAllAsOffline(estimates) {\n let considerAllAsOffline = false;\n\n for (let index in estimates) {\n if (this.isLicenseOffline(estimates[index])) {\n considerAllAsOffline = true;\n break;\n }\n }\n\n return considerAllAsOffline;\n },\n isLicenseOffline(license) {\n return (license.hasOwnProperty('offline_processing')\n && (license.offline_processing == 'true'\n || license.offline_processing == true\n || license.offline_processing == 1))\n },\n includeEstimate(estimate) {\n let excludedEstimates = ['Take no action', 'Take No Action', 'Get a Duplicate Registration'];\n\n for (let excludeEstimate of excludedEstimates) {\n if (estimate.includes(excludeEstimate)) {\n return false;\n }\n }\n return true;\n }\n }\n}\n","import mod from \"-!../../node_modules/babel-loader/lib/index.js??ref--2-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./verify.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../node_modules/babel-loader/lib/index.js??ref--2-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./verify.vue?vue&type=script&lang=js&\"","import { render, staticRenderFns } from \"./verify.vue?vue&type=template&id=795eaeb6&\"\nimport script from \"./verify.vue?vue&type=script&lang=js&\"\nexport * from \"./verify.vue?vue&type=script&lang=js&\"\nfunction injectStyles (context) {\n \n var style0 = require(\"./verify.vue?vue&type=style&index=0&lang=css&\")\nif (style0.__inject__) style0.__inject__(context)\n\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 injectStyles,\n null,\n \"e9cbe17a\"\n \n)\n\nexport default component.exports","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('ValidationProvider',{attrs:{\"rules\":_vm.rules,\"name\":_vm.vName || _vm.field},scopedSlots:_vm._u([{key:\"default\",fn:function(ref){\nvar errors = ref.errors;\nreturn [_c('div',{staticClass:\"form-group with-animation\",class:_vm.formGroupClasses},[_vm._t(\"default\",function(){return [_c('p',{staticClass:\"placeholder-text\",class:{'required':_vm.isRequired}},[_vm._v(_vm._s(_vm.placeholder))]),_vm._v(\" \"),((_vm.type)==='checkbox')?_c('input',{directives:[{name:\"model\",rawName:\"v-model\",value:(_vm.form[_vm.field]),expression:\"form[field]\"}],staticClass:\"form-control\",class:{'with-border':_vm.addWithBorderClass},attrs:{\"disabled\":_vm.$attrs['disabled'],\"name\":_vm.vName || _vm.field,\"type\":\"checkbox\"},domProps:{\"checked\":Array.isArray(_vm.form[_vm.field])?_vm._i(_vm.form[_vm.field],null)>-1:(_vm.form[_vm.field])},on:{\"change\":function($event){var $$a=_vm.form[_vm.field],$$el=$event.target,$$c=$$el.checked?(true):(false);if(Array.isArray($$a)){var $$v=null,$$i=_vm._i($$a,$$v);if($$el.checked){$$i<0&&(_vm.$set(_vm.form, _vm.field, $$a.concat([$$v])))}else{$$i>-1&&(_vm.$set(_vm.form, _vm.field, $$a.slice(0,$$i).concat($$a.slice($$i+1))))}}else{_vm.$set(_vm.form, _vm.field, $$c)}}}}):((_vm.type)==='radio')?_c('input',{directives:[{name:\"model\",rawName:\"v-model\",value:(_vm.form[_vm.field]),expression:\"form[field]\"}],staticClass:\"form-control\",class:{'with-border':_vm.addWithBorderClass},attrs:{\"disabled\":_vm.$attrs['disabled'],\"name\":_vm.vName || _vm.field,\"type\":\"radio\"},domProps:{\"checked\":_vm._q(_vm.form[_vm.field],null)},on:{\"change\":function($event){return _vm.$set(_vm.form, _vm.field, null)}}}):_c('input',{directives:[{name:\"model\",rawName:\"v-model\",value:(_vm.form[_vm.field]),expression:\"form[field]\"}],staticClass:\"form-control\",class:{'with-border':_vm.addWithBorderClass},attrs:{\"disabled\":_vm.$attrs['disabled'],\"name\":_vm.vName || _vm.field,\"type\":_vm.type},domProps:{\"value\":(_vm.form[_vm.field])},on:{\"input\":function($event){if($event.target.composing){ return; }_vm.$set(_vm.form, _vm.field, $event.target.value)}}})]}),_vm._v(\" \"),_vm._l((_vm.$getFormInputErrors(errors,_vm.field,_vm.form)),function(err){return (!_vm.errorMsgsOutOfWrapper)?_c('span',{staticClass:\"validation-err-msg\",domProps:{\"innerHTML\":_vm._s(err)}}):_vm._e()})],2),_vm._v(\" \"),_vm._l((_vm.$getFormInputErrors(errors,_vm.field,_vm.form)),function(err){return (_vm.errorMsgsOutOfWrapper)?_c('span',{staticClass:\"validation-err-msg\",domProps:{\"innerHTML\":_vm._s(err)}}):_vm._e()})]}}],null,true)})}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\nexport default {\n name: \"input-field\",\n props: {\n vName: {\n required: false,\n },\n type: {\n required: false,\n default: 'text'\n },\n rules: {\n required: false,\n type: String,\n default: ''\n },\n formGroupClass: {\n require: false,\n default: ''\n },\n form: {\n required: true\n },\n field: {\n required: true,\n type: String\n },\n placeholder: {\n required: false,\n default: ''\n },\n errorMsgsOutOfWrapper: {\n required: false,\n default: false\n }\n },\n data() {\n return {\n addWithBorderClass: false,\n formGroupClasses: []\n }\n },\n mounted() {\n\n this.formGroupClass.split(' ').forEach(c => {\n if (c.trim()) {\n this.formGroupClasses.push({[c]: true});\n }\n });\n\n this.focusOnInputIfValue();\n\n },\n methods: {\n focusOnInputIfValue() {\n\n if (!this.fieldValue) {\n return;\n }\n\n let hasFocusedClass = this.formGroupClasses.find(c => {\n if (c['focused']) {\n return c;\n }\n });\n\n if (hasFocusedClass) {\n return;\n }\n\n this.formGroupClasses.push({\n 'focused': true\n });\n },\n\n },\n computed: {\n isRequired() {\n return this.rules.indexOf('required') >= 0;\n },\n fieldValue() {\n return this.field.split('.').reduce((o, f) => o[f], this.form);\n }\n },\n watch: {\n fieldValue() {\n this.focusOnInputIfValue();\n }\n }\n}\n","import mod from \"-!../../node_modules/babel-loader/lib/index.js??ref--2-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./InputField.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../node_modules/babel-loader/lib/index.js??ref--2-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./InputField.vue?vue&type=script&lang=js&\"","import { render, staticRenderFns } from \"./InputField.vue?vue&type=template&id=7fbd73e8&scoped=true&\"\nimport script from \"./InputField.vue?vue&type=script&lang=js&\"\nexport * from \"./InputField.vue?vue&type=script&lang=js&\"\nfunction injectStyles (context) {\n \n var style0 = require(\"./InputField.vue?vue&type=style&index=0&id=7fbd73e8&scoped=true&lang=css&\")\nif (style0.__inject__) style0.__inject__(context)\n\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 injectStyles,\n \"7fbd73e8\",\n \"4951dfc0\"\n \n)\n\nexport default component.exports","// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../node_modules/css-loader/dist/cjs.js??ref--3-oneOf-1-1!../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../node_modules/postcss-loader/src/index.js??ref--3-oneOf-1-2!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./InputField.vue?vue&type=style&index=0&id=7fbd73e8&scoped=true&lang=css&\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add CSS to SSR context\nvar add = require(\"!../../node_modules/vue-style-loader/lib/addStylesServer.js\").default\nmodule.exports.__inject__ = function (context) {\n add(\"f5598fc8\", content, true, context)\n};","// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../node_modules/css-loader/dist/cjs.js??ref--3-oneOf-1-1!../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../node_modules/postcss-loader/src/index.js??ref--3-oneOf-1-2!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./FormErrorMsg.vue?vue&type=style&index=0&id=4c656529&scoped=true&lang=css&\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add CSS to SSR context\nvar add = require(\"!../../node_modules/vue-style-loader/lib/addStylesServer.js\").default\nmodule.exports.__inject__ = function (context) {\n add(\"3e06b350\", content, true, context)\n};","import InputField from \"@/components/Forms/InputField\";\nimport FormErrorMsg from \"@/components/Forms/FormErrorMsg\";\nimport {toPng} from 'html-to-image';\n\nexport default {\n components: {\n InputField, FormErrorMsg\n },\n data() {\n return {\n formErrorMsg: ''\n }\n },\n methods: {\n frontendFormSubmitHandler() {\n\n if (!this.$refs.form) {\n return this.submit();\n }\n\n this.$refs.form.validate().then(success => {\n //submit the form if not errors occurs\n if (success) {\n return this.submit();\n }\n\n let firstErrorFieldName = this.getFirstFieldErrorName();\n\n //focus on the input if found!\n if (firstErrorFieldName) {\n this.focusOnElement(firstErrorFieldName);\n }\n\n });\n\n },\n getFirstFieldErrorName() {\n let errorsKeys = Object.keys(this.$refs.form.errors),\n firstErrorFieldName;\n\n while (errorsKeys.length) {\n firstErrorFieldName = errorsKeys.shift();\n\n if (this.$refs.form.errors[firstErrorFieldName].length) {\n return firstErrorFieldName;\n }\n }\n },\n focusOnElement(fieldName) {\n let [el] = document.getElementsByName(fieldName);\n\n //try with id\n if (!el) {\n el = document.getElementById(fieldName);\n }\n\n el.scrollIntoView({behavior: 'smooth'});\n el.focus();\n },\n catchError(err) {\n if (err.response) {\n this.form.onFail(err.response.data.data);\n this.formErrorMsg = err.response.data.message;\n } else {\n this.formErrorMsg = err.message;\n }\n },\n storeSavedSession(step, redirectTo, payload) {\n let storedOrderId = this.$store.state.orderId;\n\n if (storedOrderId) {\n\n this.$axios.post(`orders/${storedOrderId}/${step}/store-saved-session`, {\n payload: payload\n });\n\n }\n\n if (redirectTo) {\n this.$router.push({path: redirectTo});\n }\n\n },\n saveElectronicSignature() {\n const {isEmpty, data} = this.$refs.signaturePad.saveSignature();\n\n if (isEmpty) {\n this.form.electronic_signature = '';\n } else {\n this.form.electronic_signature = data;\n }\n },\n clearElectronicSignature() {\n this.$refs.signaturePad.clearSignature();\n this.saveElectronicSignature();\n },\n async htmlToPNG() {\n const el = this.$refs.screenShotSection;\n this.form.signature_sc = await toPng(el);\n },\n async screenshot() {\n await this.htmlToPNG();\n this.ipVisible = false;\n },\n onBeginSignature() {\n },\n onEndSignature() {\n this.saveElectronicSignature();\n },\n }\n}\n","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return (_vm.errorMsg)?_c('p',{staticClass:\"form-error-msg\",domProps:{\"innerHTML\":_vm._s(_vm.errorMsg)}},[]):_vm._e()}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","//\n//\n//\n//\n\nexport default {\n name: \"FormErrorMsg\",\n props: {\n msg: {\n type: String\n }\n },\n data() {\n return {\n errorMsg: ''\n }\n },\n mounted() {\n this.setFormErrorMsg(this.msg);\n },\n methods: {\n setFormErrorMsg(msg) {\n this.errorMsg = msg;\n }\n },\n beforeMount() {\n this.$eventBus.$on('setFormErrorMsg', this.setFormErrorMsg)\n },\n watch: {\n msg() {\n this.setFormErrorMsg(this.msg);\n }\n }\n}\n","import mod from \"-!../../node_modules/babel-loader/lib/index.js??ref--2-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./FormErrorMsg.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../node_modules/babel-loader/lib/index.js??ref--2-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./FormErrorMsg.vue?vue&type=script&lang=js&\"","import { render, staticRenderFns } from \"./FormErrorMsg.vue?vue&type=template&id=4c656529&scoped=true&\"\nimport script from \"./FormErrorMsg.vue?vue&type=script&lang=js&\"\nexport * from \"./FormErrorMsg.vue?vue&type=script&lang=js&\"\nfunction injectStyles (context) {\n \n var style0 = require(\"./FormErrorMsg.vue?vue&type=style&index=0&id=4c656529&scoped=true&lang=css&\")\nif (style0.__inject__) style0.__inject__(context)\n\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 injectStyles,\n \"4c656529\",\n \"1910dda6\"\n \n)\n\nexport default component.exports","export * from \"-!../../node_modules/vue-style-loader/index.js??ref--3-oneOf-1-0!../../node_modules/css-loader/dist/cjs.js??ref--3-oneOf-1-1!../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../node_modules/postcss-loader/src/index.js??ref--3-oneOf-1-2!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./InputField.vue?vue&type=style&index=0&id=7fbd73e8&scoped=true&lang=css&\"","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../node_modules/css-loader/dist/runtime/api.js\");\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(false);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, \".form-control[data-v-7fbd73e8]:disabled{background-color:unset!important}\", \"\"]);\n// Exports\nmodule.exports = ___CSS_LOADER_EXPORT___;\n","export * from \"-!../../node_modules/vue-style-loader/index.js??ref--3-oneOf-1-0!../../node_modules/css-loader/dist/cjs.js??ref--3-oneOf-1-1!../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../node_modules/postcss-loader/src/index.js??ref--3-oneOf-1-2!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./FormErrorMsg.vue?vue&type=style&index=0&id=4c656529&scoped=true&lang=css&\"","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../node_modules/css-loader/dist/runtime/api.js\");\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(false);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, \".form-error-msg[data-v-4c656529]{text-align:right;margin-top:10px;color:red;font-weight:700}\", \"\"]);\n// Exports\nmodule.exports = ___CSS_LOADER_EXPORT___;\n"],"mappings":";;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;ACXA;AAAA;AAAA;AAAA;;;;;;;;ACAA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;ACNA;AACA;AACA;;;;;;;;ACFA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAGA;AAmFA;AACA;AAEA;;ACvHA;;;;;ACAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;ACvBA;AACA;AACA;AACA;AACA;;;;;ACJA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAEA;;AC5BA;;;;;ACAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;ACvBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;ACXA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;ACXA;AAAA;AAAA;AAAA;AAAA;AAsBA;AAOA;AAuBA;;;;;;;;;;ACpDA;AACA;AACA;;;;;ACFA;AACA;AACA;AACA;AAEA;;ACLA;;;;;ACAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;ACvBA;AAAA;AAAA;AAAA;;;;;;;;ACAA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;ACNA;AAAA;AAAA;AAAA;;;;;;;;ACAA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;A","sourceRoot":""}