{"version":3,"sources":["webpack:///./src/views/Flow/MobileBusiness/Step6AppointmentInfoMobile/Step6AppointmentInfoMobile.vue?8f02","webpack:///./src/views/Flow/MobileBusiness/Step6AppointmentInfoMobile/Step6AppointmentInfoMobile.controller.js","webpack:///./src/views/Flow/MobileBusiness/Step6AppointmentInfoMobile/Step6AppointmentInfoMobile.controller.js?3f03","webpack:///./src/views/Flow/MobileBusiness/Step6AppointmentInfoMobile/Step6AppointmentInfoMobile.vue","webpack:///./src/views/Flow/MobileBusiness/Step6AppointmentInfoMobile/Step6AppointmentInfoMobile.styles.scss?7cb8"],"names":["render","_vm","this","_h","$createElement","_c","_self","staticClass","attrs","$gettext","on","goToPreviousStep","directives","name","rawName","_v","ref","$event","preventDefault","save","class","scopedSlots","_u","key","fn","errors","classes","value","expression","$$selectedVal","Array","prototype","filter","call","target","options","o","selected","map","val","_value","timeOfArr","multiple","_l","moment","domProps","_s","loadingState","isValidAppointment","appointmet","debounceConfim","staticRenderFns","components","ValidationObserver","ValidationProvider","AppointmentOverview","Title","DateMobilePicker","PersonalDataForm","Remark","AddressPicker","props","data","computed","mapGetters","customerDataRaw","appointmentPostObject","cat","momentOfArrival","timeOfArrival","get","set","newModel","setTimeOfArrival","methods","setValidationMessages","extend","required","message","Vue","mapActions","setAppointmentMobile","mapMutations","setCat","setHasApp","$router","push","confirmAppointment","personalDataForm","$refs","form","personalDataFormTitle","formPersonalDataTitle","validPersonalDataFormTitle","isValid","timeOfArrForm","timeForm","validate","then","isValidTime","validationFlow","validateStep6AppointmentInfo","catch","router","_","debounce","component"],"mappings":"kJAAA,I,EAAIA,EAAS,WAAa,IAAIC,EAAIC,KAASC,EAAGF,EAAIG,eAAmBC,EAAGJ,EAAIK,MAAMD,IAAIF,EAAG,OAAOE,EAAG,MAAM,CAACE,YAAY,eAAe,CAACF,EAAG,QAAQ,CAACG,MAAM,CAAC,kBAAoBP,EAAIQ,SAAS,4BAA4BC,GAAG,CAAC,yBAAyBT,EAAIU,mBAAmB,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C,MAAK,WACJ,EAAKd,WAAU,GACfgB,OAAeC,kCACdC,OAAM,WACPC,OAAOjB,KAAK,CACVzE,KAAM,qBAQtBqC,eAAgBsD,IAAEC,UAAS,WACzBvG,KAAKqF,uBACJ,QCjI2U,I,wBCQ9UmB,EAAY,eACd,EACA1G,EACAmD,GACA,EACA,KACA,KACA,MAIa,aAAAuD,E,6CCnBf,yBAA+d,EAAG","file":"js/chunk-15b70268.257ecbe0.js","sourcesContent":["var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"l-container\"},[_c('Title',{attrs:{\"previousStepTitle\":_vm.$gettext('Step 6 - Previous title')},on:{\"on-go-to-previous-step\":_vm.goToPreviousStep}},[_c('h1',{directives:[{name:\"translate\",rawName:\"v-translate\"}]},[_vm._v(\"Step 6 - Title\")])]),_c('p',{directives:[{name:\"translate\",rawName:\"v-translate\"}],staticClass:\"u-hide\"},[_vm._v(\"Step 6 - Previous title\")]),_c('p',{directives:[{name:\"translate\",rawName:\"v-translate\"}],staticClass:\"u-hide\"},[_vm._v(\"Step 6 - Title\")]),_c('hr',{staticClass:\"hr--full-width\"}),_c('AppointmentOverview'),_c('hr'),_c('AddressPicker'),_c('hr'),_c('DateMobilePicker'),_c('hr'),_c('PersonalDataForm',{ref:\"personalDataForm\"}),_c('hr'),_c('div',{staticClass:\"m-component\"},[_c('div',{staticClass:\"m-component__info\"},[_c('p',{directives:[{name:\"translate\",rawName:\"v-translate\"}],staticClass:\"m-component__title\"},[_vm._v(\"Mobile - MomentOfArrival\")])]),_c('div',{staticClass:\"m-component__container\"},[_c('ValidationObserver',{ref:\"timeForm\",attrs:{\"slim\":\"\"}},[_c('form',{attrs:{\"id\":\"timeDataForm\"},on:{\"submit\":function($event){$event.preventDefault();return _vm.save($event)}}},[_c('div',{staticClass:\"u-hide\"},[_c('p',{directives:[{name:\"translate\",rawName:\"v-translate\"}]},[_vm._v(\"Validation - Required error\")])]),_c('ValidationProvider',{staticClass:\"a-input__validation-wrapper\",class:{\n 'form-control': 'form-control',\n },attrs:{\"rules\":\"required\"},scopedSlots:_vm._u([{key:\"default\",fn:function(ref){\n var errors = ref.errors;\n var classes = ref.classes;\nreturn [_c('span',{staticClass:\"a-input__validation-wrapper form-control\"},[_c('label',{staticClass:\"a-input__label\"},[_c('select',{directives:[{name:\"model\",rawName:\"v-model\",value:(_vm.timeOfArr),expression:\"timeOfArr\"}],class:classes,attrs:{\"name\":\"selectedTimeArrival\"},on:{\"change\":function($event){var $$selectedVal = Array.prototype.filter.call($event.target.options,function(o){return o.selected}).map(function(o){var val = \"_value\" in o ? o._value : o.value;return val}); _vm.timeOfArr=$event.target.multiple ? $$selectedVal : $$selectedVal[0]}}},_vm._l((_vm.momentOfArrival),function(moment){return _c('option',{key:moment,domProps:{\"value\":moment}},[_vm._v(_vm._s(moment)+\" \")])}),0),_c('span',{staticClass:\"a-input__validation-message\"},[_vm._v(_vm._s(errors[0]))])])])]}}])})],1)])],1)]),_c('hr'),_c('Remark',{attrs:{\"type\":\"arr\"}}),_c('hr'),_c('div',{staticClass:\"a-button__flow-container\"},[_c('div',{staticClass:\"a-button a-button--primary u-full-width u-margin-bottom-3x\",class:{ 'a-button--is-loading': _vm.loadingState, 'a-button--disabled': (!_vm.isValidAppointment || _vm.appointmet) },on:{\"click\":function($event){return _vm.debounceConfim()}}},[_c('span',{directives:[{name:\"translate\",rawName:\"v-translate\"}]},[_vm._v(\"General - Confirm appointment\")]),_c('div',{staticClass:\"a-spinner\"})])])],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import {\r\n AppointmentOverview,\r\n Title,\r\n DateMobilePicker,\r\n PersonalDataForm,\r\n Remark,\r\n AddressPicker,\r\n} from '@/components';\r\nimport Vue from 'vue';\r\nimport router from '@/router';\r\n\r\nimport validationFlow from '@/validation-flow';\r\nimport {\r\n extend,\r\n ValidationObserver,\r\n ValidationProvider,\r\n} from 'vee-validate';\r\nimport {\r\n required,\r\n} from 'vee-validate/dist/rules';\r\nimport {\r\n mapActions,\r\n mapGetters,\r\n mapMutations,\r\n} from 'vuex';\r\n\r\nimport _ from 'lodash';\r\n\r\nexport default {\r\n name: 'step6AppointmentInfoMobile',\r\n components: {\r\n ValidationObserver,\r\n ValidationProvider,\r\n [AppointmentOverview.name]: AppointmentOverview,\r\n [Title.name]: Title,\r\n [DateMobilePicker.name]: DateMobilePicker,\r\n [PersonalDataForm.name]: PersonalDataForm,\r\n [Remark.name]: Remark,\r\n [AddressPicker.name]: AddressPicker,\r\n },\r\n props: {},\r\n data: () => ({}),\r\n computed: {\r\n ...mapGetters('appointment', {\r\n customerDataRaw: 'getCustomerDataRaw',\r\n loadingState: 'getLoadingState',\r\n isValidAppointment: 'getIsValidAppointmentMobileComp',\r\n appointmentPostObject: 'getAppointmentPostObject',\r\n cat: 'getCat',\r\n momentOfArrival: 'getMomentsOfTimeOfArrival',\r\n timeOfArrival: 'getTimeOfArrival',\r\n appointmet: 'getHasAppointment',\r\n }),\r\n timeOfArr: {\r\n get() {\r\n return this.timeOfArrival;\r\n },\r\n set(newModel) {\r\n // console.log(newModel);\r\n if (newModel != null) {\r\n this.setTimeOfArrival(newModel);\r\n }\r\n\r\n return newModel;\r\n },\r\n },\r\n // appointmetVue: {\r\n // get() {\r\n // return this.appointmet;\r\n // },\r\n // set(newModel) {\r\n // // console.log(newModel);\r\n // if (newModel != null) {\r\n // this.setTimeOfArrival(newModel);\r\n // }\r\n\r\n // return newModel;\r\n // },\r\n // },\r\n },\r\n methods: {\r\n save() { },\r\n setValidationMessages() {\r\n // Vee-validate\r\n // Translations are added in the PersonalDataFormComponent\r\n extend('required', {\r\n ...required,\r\n message: Vue.prototype.$gettext('Validation - Required error'),\r\n });\r\n },\r\n ...mapActions('appointment', {\r\n setAppointmentMobile: 'SET_APPOINTMENT_MOBILE_BUS',\r\n }),\r\n ...mapMutations('appointment', {\r\n setCat: 'SET_CAT',\r\n setTimeOfArrival: 'SET_TIMEOFARRIVAL',\r\n setHasApp: 'SET_HASAPPOINTMENT',\r\n }),\r\n goToPreviousStep() {\r\n this.$router.push({\r\n name: 'step5TireInfo',\r\n });\r\n },\r\n confirmAppointment() {\r\n const personalDataForm = this.$refs.personalDataForm.$refs.form;\r\n const personalDataFormTitle = this.$refs.personalDataForm.$refs.formPersonalDataTitle;\r\n const validPersonalDataFormTitle = personalDataFormTitle.isValid();\r\n const timeOfArrForm = this.$refs.timeForm;\r\n personalDataForm.validate().then((isValid) => {\r\n timeOfArrForm.validate().then((isValidTime) => {\r\n if (isValid && isValidTime) {\r\n if (this.isValidAppointment && validPersonalDataFormTitle && !this.loadingState) {\r\n this.setCat('tag');\r\n this.setAppointmentMobile(this.appointmentPostObject)\r\n .then(() => {\r\n this.setHasApp(true);\r\n validationFlow.validateStep6AppointmentInfo();\r\n }).catch(() => {\r\n router.push({\r\n name: 'error',\r\n });\r\n });\r\n }\r\n }\r\n });\r\n });\r\n },\r\n debounceConfim: _.debounce(function () {\r\n this.confirmAppointment();\r\n }, 150),\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/eslint-loader/index.js??ref--13-0!./Step6AppointmentInfoMobile.controller.js?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/eslint-loader/index.js??ref--13-0!./Step6AppointmentInfoMobile.controller.js?vue&type=script&lang=js&\"","import { render, staticRenderFns } from \"./Step6AppointmentInfoMobile.vue?vue&type=template&id=cc3645b2&\"\nimport script from \"./Step6AppointmentInfoMobile.controller.js?vue&type=script&lang=js&\"\nexport * from \"./Step6AppointmentInfoMobile.controller.js?vue&type=script&lang=js&\"\nimport style0 from \"./Step6AppointmentInfoMobile.styles.scss?vue&type=style&index=0&lang=scss&\"\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","import mod from \"-!../../../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!../../../../../node_modules/css-loader/dist/cjs.js??ref--8-oneOf-1-1!../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../node_modules/postcss-loader/src/index.js??ref--8-oneOf-1-2!../../../../../node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-3!./Step6AppointmentInfoMobile.styles.scss?vue&type=style&index=0&lang=scss&\"; export default mod; export * from \"-!../../../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!../../../../../node_modules/css-loader/dist/cjs.js??ref--8-oneOf-1-1!../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../node_modules/postcss-loader/src/index.js??ref--8-oneOf-1-2!../../../../../node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-3!./Step6AppointmentInfoMobile.styles.scss?vue&type=style&index=0&lang=scss&\""],"sourceRoot":""}