{"version":3,"sources":["webpack:///./src/views/Profile.vue?7de1","webpack:///./src/services/user.service.js","webpack:///./src/views/Profile.vue?f64f","webpack:///src/views/Profile.vue","webpack:///./src/views/Profile.vue?3600","webpack:///./src/views/Profile.vue?35ee"],"names":["UserService","axios","get","API_AGENTS_URL","headers","authHeader","new_password","use_2fa","post","API_USER_UPDATE_URL","password","id","delete","agent","put","API_NEW_AGENT_URL","API_SUBNETS_URL","render","_vm","this","_h","$createElement","_c","_self","staticClass","attrs","on","$event","preventDefault","handlePasswordChange","_m","currentUser","data","created_at","_v","_s","email","address","directives","name","rawName","value","expression","domProps","target","composing","errors","has","first","_e","Array","isArray","_i","$$a","$$el","$$c","checked","$$v","$$i","concat","slice","loading","message","error","staticRenderFns","$store","state","auth","user","computed","mounted","status","loggedIn","$router","push","methods","$validator","validateAll","then","isValid","component"],"mappings":"kHAAA,W,sICIMA,E,8GAEF,OAAOC,IAAMC,IAAIC,OAAgB,CAAEC,QAASC,qB,6BAGvCC,EAAcC,GACnB,OAAON,IAAMO,KAAKC,OAAqB,CACrCC,SAAUJ,EACVC,QAASA,GACR,CAAEH,QAASC,qB,+BAGPM,GACP,OAAOV,IAAMC,IAAIC,OAAiB,IAAMQ,EAAI,CAAEP,QAASC,qB,kCAG7CM,GACV,OAAOV,IAAMW,OAAOT,OAAiB,IAAMQ,EAAI,CAAEP,QAASC,qB,kCAGhDQ,GACV,OAAOZ,IAAMa,IAAIC,OAAmBF,EAAO,CAAET,QAASC,qB,kCAG5CQ,GACV,OAAOZ,IAAMa,IAAIX,OAAiB,IAAMU,EAAMF,GAAIE,EAAO,CAAET,QAASC,qB,6CAIpE,OAAOJ,IAAMC,IAAIc,OAAkB,cAAe,CAAEZ,QAASC,uB,KAIlD,WAAIL,G,yCCrCnB,IAAIiB,EAAS,WAAa,IAAIC,EAAIC,KAASC,EAAGF,EAAIG,eAAmBC,EAAGJ,EAAIK,MAAMD,IAAIF,EAAG,OAAOE,EAAG,MAAM,CAACE,YAAY,qC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K8C,OAAOC,MAAMC,KAAKC,OAIlCE,QAnBF,WAoBSnD,KAAK8C,OAAOC,MAAMC,KAAKI,OAAOC,UACjCrD,KAAKsD,QAAQC,KAAK,WAItBC,QAAS,CACP9C,qBADJ,WACA,WACMV,KAAK0C,SAAU,EACf1C,KAAKyD,WAAWC,cAAcC,MAAK,SAAzC,GACaC,IAKD,EAAZ,gEACU,EAAV,4CACA,YACY,EAAZ,WACY,EAAZ,2BACY,aAAZ,0CAEA,YACY,EAAZ,WACY,EAAZ,QACA,oDACA,WACA,aAEA,0BACc,EAAd,+BACc,EAAd,2BApBU,EAAV,iBC1GiV,I,wBCQ7UC,EAAY,eACd,EACA/D,EACA+C,GACA,EACA,KACA,WACA,MAIa,aAAAgB,E","file":"js/chunk-7f0640d2.d23fcd32.js","sourcesContent":["export * from \"-!../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--6-oneOf-1-0!../../node_modules/css-loader/dist/cjs.js??ref--6-oneOf-1-1!../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../node_modules/postcss-loader/src/index.js??ref--6-oneOf-1-2!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Profile.vue?vue&type=style&index=0&id=6d1f5611&scoped=true&lang=css&\"","import axios from 'axios';\nimport authHeader from './auth-header';\nimport {API_AGENTS_URL, API_USER_UPDATE_URL, API_NEW_AGENT_URL, API_SUBNETS_URL} from \"@/services/api\";\n\nclass UserService {\n getUserAgents() {\n return axios.get(API_AGENTS_URL, { headers: authHeader() });\n }\n\n update(new_password, use_2fa) {\n return axios.post(API_USER_UPDATE_URL, {\n password: new_password,\n use_2fa: use_2fa\n }, { headers: authHeader() });\n }\n\n getAgent(id) {\n return axios.get(API_AGENTS_URL + '/' + id, { headers: authHeader() });\n }\n\n deleteAgent(id) {\n return axios.delete(API_AGENTS_URL + '/' + id, { headers: authHeader() });\n }\n\n createAgent(agent) {\n return axios.put(API_NEW_AGENT_URL, agent, { headers: authHeader() });\n }\n\n updateAgent(agent) {\n return axios.put(API_AGENTS_URL + '/' + agent.id, agent, { headers: authHeader() });\n }\n\n getCloudFlareSubnets() {\n return axios.get(API_SUBNETS_URL + '/cloudflare', { headers: authHeader() });\n }\n}\n\nexport default new UserService();\n","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"profile-container container-fluid\"},[_c('form',{attrs:{\"name\":\"form\"},on:{\"submit\":function($event){$event.preventDefault();return _vm.handlePasswordChange($event)}}},[_c('div',{staticClass:\"form-group\"},[_vm._m(0),_c('span',{staticClass:\"form-control\",attrs:{\"name\":\"created_at\",\"id\":\"created_at\",\"readonly\":\"true\"}},[_c('timeago',{attrs:{\"datetime\":_vm.currentUser.data.created_at,\"auto-update\":60}})],1)]),_c('div',{staticClass:\"form-group\"},[_vm._m(1),_c('span',{staticClass:\"form-control\",attrs:{\"name\":\"email\",\"id\":\"email\",\"readonly\":\"true\"}},[_vm._v(_vm._s(_vm.currentUser.data.email))])]),_c('div',{staticClass:\"form-group\"},[_vm._m(2),_c('span',{staticClass:\"form-control\",attrs:{\"name\":\"address\",\"id\":\"address\",\"readonly\":\"true\"}},[_vm._v(_vm._s(_vm.currentUser.data.address))])]),_c('div',{staticClass:\"form-group\"},[_vm._m(3),_c('input',{directives:[{name:\"model\",rawName:\"v-model\",value:(_vm.new_password),expression:\"new_password\"},{name:\"validate\",rawName:\"v-validate\",value:('min:8|max:64'),expression:\"'min:8|max:64'\"}],staticClass:\"form-control\",attrs:{\"type\":\"password\",\"name\":\"password\",\"id\":\"password\"},domProps:{\"value\":(_vm.new_password)},on:{\"input\":function($event){if($event.target.composing){ return; }_vm.new_password=$event.target.value}}}),(_vm.errors.has('password'))?_c('div',{staticClass:\"alert alert-danger\"},[_vm._v(_vm._s(_vm.errors.first('password'))+\" \")]):_vm._e()]),_c('div',{staticClass:\"form-group form-check\"},[_c('input',{directives:[{name:\"model\",rawName:\"v-model\",value:(_vm.use_2fa),expression:\"use_2fa\"}],staticClass:\"form-check-input\",attrs:{\"type\":\"checkbox\",\"value\":\"1\",\"id\":\"use_2fa\"},domProps:{\"checked\":Array.isArray(_vm.use_2fa)?_vm._i(_vm.use_2fa,\"1\")>-1:(_vm.use_2fa)},on:{\"change\":function($event){var $$a=_vm.use_2fa,$$el=$event.target,$$c=$$el.checked?(true):(false);if(Array.isArray($$a)){var $$v=\"1\",$$i=_vm._i($$a,$$v);if($$el.checked){$$i<0&&(_vm.use_2fa=$$a.concat([$$v]))}else{$$i>-1&&(_vm.use_2fa=$$a.slice(0,$$i).concat($$a.slice($$i+1)))}}else{_vm.use_2fa=$$c}}}}),_c('label',{staticClass:\"form-check-label\",attrs:{\"for\":\"use_2fa\"}},[_vm._v(\" Two-step verification via email \")])]),_c('div',{staticClass:\"form-group\"},[_c('button',{staticClass:\"btn btn-primary btn-block\",attrs:{\"disabled\":_vm.loading}},[_c('span',{directives:[{name:\"show\",rawName:\"v-show\",value:(_vm.loading),expression:\"loading\"}],staticClass:\"spinner-border spinner-border-sm\"}),_c('span',[_vm._v(\"Save\")])])]),_c('div',{staticClass:\"form-group\"},[(_vm.message)?_c('div',{staticClass:\"alert alert-success\",attrs:{\"role\":\"alert\"}},[_vm._v(_vm._s(_vm.message))]):_vm._e(),(_vm.error)?_c('div',{staticClass:\"alert alert-danger\",attrs:{\"role\":\"alert\"}},[_vm._v(_vm._s(_vm.error))]):_vm._e()])])])}\nvar staticRenderFns = [function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('label',{attrs:{\"for\":\"created_at\"}},[_c('strong',[_vm._v(\"Account Creation\")])])},function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('label',{attrs:{\"for\":\"email\"}},[_c('strong',[_vm._v(\"Email\")])])},function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('label',{attrs:{\"for\":\"address\"}},[_c('strong',[_vm._v(\"Address\")])])},function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('label',{attrs:{\"for\":\"password\"}},[_c('strong',[_vm._v(\"New Password\")])])}]\n\nexport { render, staticRenderFns }","\n \n\n \n \n Account Creation\n \n \n \n \n \n Email\n {{ currentUser.data.email }}\n \n \n Address\n {{ currentUser.data.address }}\n \n \n New Password\n \n {{ errors.first('password') }}\n \n \n\n \n \n \n Two-step verification via email\n \n \n\n \n \n \n Save\n \n \n \n {{message}}\n {{error}}\n \n\n \n\n \n\n\n\n\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!./Profile.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!./Profile.vue?vue&type=script&lang=js&\"","import { render, staticRenderFns } from \"./Profile.vue?vue&type=template&id=6d1f5611&scoped=true&\"\nimport script from \"./Profile.vue?vue&type=script&lang=js&\"\nexport * from \"./Profile.vue?vue&type=script&lang=js&\"\nimport style0 from \"./Profile.vue?vue&type=style&index=0&id=6d1f5611&scoped=true&lang=css&\"\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 \"6d1f5611\",\n null\n \n)\n\nexport default component.exports"],"sourceRoot":""}