{"version":3,"sources":["webpack:///src/components/Settings/LeadSources/ModalDeleteLeadSource.vue","webpack:///./src/components/Settings/LeadSources/ModalDeleteLeadSource.vue","webpack:///./src/components/Settings/LeadSources/ModalDeleteLeadSource.vue?2117","webpack:///./src/components/Settings/LeadSources/ModalDeleteLeadSource.vue?a537","webpack:///./src/components/Settings/LeadSources/ModalDeleteLeadSource.vue?b7fb"],"names":["components","BaseCheckbox","props","showModal","type","Boolean","default","onClickCancel","Function","required","source","Object","data","isDeleteConfirmed","isDeleting","isDeletingSuccess","isDeletingError","computed","created","methods","deleteLeadSource","_this","self","leadsourceProvider","Id","then","response","status","$emit","catch","err","finally","render","_vm","_c","_self","attrs","modalTitle","$t","isSaving","isSavingSuccess","isSavingError","hideFooterButtons","buttonLabelConfirm","disableSaveButton","confirmButtonCssClass","onClickSave","on","closeModal","scopedSlots","_u","key","fn","staticClass","domProps","innerHTML","_s","name","Name","label","model","value","callback","$$v","expression","proxy","slot","staticRenderFns","_withStripped"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAqCA;AAEe;EACfA,UAAA;IACAC,YAAA,WAAAA,aAAA;MAAA;IAAA;EACA;EAEAC,KAAA;IACAC,SAAA;MACAC,IAAA,EAAAC,OAAA;MACAC,OAAA;IACA;IAEAC,aAAA;MACAH,IAAA,EAAAI,QAAA;MACAC,QAAA;IACA;IAEAC,MAAA;MACAN,IAAA,EAAAO,MAAA;MACAL,OAAA;IACA;EACA;EAEAM,IAAA,WAAAA,KAAA;IACA;MACAC,iBAAA;MACAC,UAAA;MACAC,iBAAA;MACAC,eAAA;IACA;EACA;EAEAC,QAAA;EAEAC,OAAA,WAAAA,QAAA;EAEAC,OAAA;IACAC,gBAAA,WAAAA,iBAAA;MAAA,IAAAC,KAAA;MACA,IAAAC,IAAA;MAEA,KAAAA,IAAA,CAAAR,UAAA;QACAQ,IAAA,CAAAR,UAAA;QAEAS,qEAAA,CAAAJ,OAAA,CACAC,gBAAA,MAAAV,MAAA,CAAAc,EAAA,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id=91dfea532ba0744a651c","sourcesContent":["<template>\n  <ui-component-modal\n    :modalTitle=\"$t('Components.Settings.ModalDeleteLeadSource.Main_Title')\"\n    :isSaving=\"isDeleting\"\n    :isSavingSuccess=\"isDeletingSuccess\"\n    :isSavingError=\"isDeletingError\"\n    :hideFooterButtons=\"isDeletingError || isDeletingSuccess\"\n    :buttonLabelConfirm=\"$t('Form.Control.Delete')\"\n    :disableSaveButton=\"!isDeleteConfirmed\"\n    confirmButtonCssClass=\"is-danger\"\n    :onClickCancel=\"onClickCancel\"\n    :onClickSave=\"deleteLeadSource\"\n    :showModal=\"showModal\"\n    @closeModal=\"onClickCancel\"\n  >\n    <template slot=\"modalTitle\"></template>\n    <template v-slot:content>\n      <div\n        class=\"has-margin-bottom is-size-5 has-text-centered\"\n        v-html=\"\n          $t('Components.Settings.ModalDeleteLeadSource.Text_Delete', {\n            name: source.Name,\n          })\n        \"\n      ></div>\n      <div class=\"has-text-centered\">\n        <BaseCheckbox\n          v-model=\"isDeleteConfirmed\"\n          class=\"has-text-left\"\n          :label=\"$t('Components.Settings.ModalDeleteLeadSource.Text_YesSure')\"\n        />\n      </div>\n    </template>\n  </ui-component-modal>\n</template>\n\n<script>\nimport leadsourceProvider from '@/providers/leadsource'\n\nexport default {\n  components: {\n    BaseCheckbox: () => import('@/components/UI/Form/BaseCheckbox'),\n  },\n\n  props: {\n    showModal: {\n      type: Boolean,\n      default: false,\n    },\n\n    onClickCancel: {\n      type: Function,\n      required: true,\n    },\n\n    source: {\n      type: Object,\n      default: null,\n    },\n  },\n\n  data() {\n    return {\n      isDeleteConfirmed: false,\n      isDeleting: false,\n      isDeletingSuccess: false,\n      isDeletingError: false,\n    }\n  },\n\n  computed: {},\n\n  created() {},\n\n  methods: {\n    deleteLeadSource() {\n      let self = this\n\n      if (!self.isDeleting) {\n        self.isDeleting = true\n\n        leadsourceProvider.methods\n          .deleteLeadSource(this.source.Id)\n          .then((response) => {\n            if (response.status === 204) {\n              this.$emit('sourceDeleted', this.source)\n\n              this.onClickCancel()\n            }\n          })\n          .catch((err) => {})\n          .finally(() => {\n            self.isDeleting = false\n          })\n      }\n    },\n  },\n}\n</script>\n","var render = function render() {\n  var _vm = this,\n    _c = _vm._self._c\n  return _c(\n    \"ui-component-modal\",\n    {\n      attrs: {\n        modalTitle: _vm.$t(\n          \"Components.Settings.ModalDeleteLeadSource.Main_Title\"\n        ),\n        isSaving: _vm.isDeleting,\n        isSavingSuccess: _vm.isDeletingSuccess,\n        isSavingError: _vm.isDeletingError,\n        hideFooterButtons: _vm.isDeletingError || _vm.isDeletingSuccess,\n        buttonLabelConfirm: _vm.$t(\"Form.Control.Delete\"),\n        disableSaveButton: !_vm.isDeleteConfirmed,\n        confirmButtonCssClass: \"is-danger\",\n        onClickCancel: _vm.onClickCancel,\n        onClickSave: _vm.deleteLeadSource,\n        showModal: _vm.showModal,\n      },\n      on: { closeModal: _vm.onClickCancel },\n      scopedSlots: _vm._u([\n        {\n          key: \"content\",\n          fn: function () {\n            return [\n              _c(\"div\", {\n                staticClass: \"has-margin-bottom is-size-5 has-text-centered\",\n                domProps: {\n                  innerHTML: _vm._s(\n                    _vm.$t(\n                      \"Components.Settings.ModalDeleteLeadSource.Text_Delete\",\n                      {\n                        name: _vm.source.Name,\n                      }\n                    )\n                  ),\n                },\n              }),\n              _c(\n                \"div\",\n                { staticClass: \"has-text-centered\" },\n                [\n                  _c(\"BaseCheckbox\", {\n                    staticClass: \"has-text-left\",\n                    attrs: {\n                      label: _vm.$t(\n                        \"Components.Settings.ModalDeleteLeadSource.Text_YesSure\"\n                      ),\n                    },\n                    model: {\n                      value: _vm.isDeleteConfirmed,\n                      callback: function ($$v) {\n                        _vm.isDeleteConfirmed = $$v\n                      },\n                      expression: \"isDeleteConfirmed\",\n                    },\n                  }),\n                ],\n                1\n              ),\n            ]\n          },\n          proxy: true,\n        },\n      ]),\n    },\n    [_c(\"template\", { slot: \"modalTitle\" })],\n    2\n  )\n}\nvar staticRenderFns = []\nrender._withStripped = true\n\nexport { render, staticRenderFns }","import { render, staticRenderFns } from \"./ModalDeleteLeadSource.vue?vue&type=template&id=be3c5540\"\nimport script from \"./ModalDeleteLeadSource.vue?vue&type=script&lang=js\"\nexport * from \"./ModalDeleteLeadSource.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\n/* hot reload */\nif (module.hot) {\n  var api = require(\"/github/workspace/node_modules/vue-hot-reload-api/dist/index.js\")\n  api.install(require('vue'))\n  if (api.compatible) {\n    module.hot.accept()\n    if (!api.isRecorded('be3c5540')) {\n      api.createRecord('be3c5540', component.options)\n    } else {\n      api.reload('be3c5540', component.options)\n    }\n    module.hot.accept(\"./ModalDeleteLeadSource.vue?vue&type=template&id=be3c5540\", function () {\n      api.rerender('be3c5540', {\n        render: render,\n        staticRenderFns: staticRenderFns\n      })\n    })\n  }\n}\ncomponent.options.__file = \"src/components/Settings/LeadSources/ModalDeleteLeadSource.vue\"\nexport default component.exports","import mod from \"-!../../../../node_modules/cache-loader/dist/cjs.js??ref--13-0!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ModalDeleteLeadSource.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../node_modules/cache-loader/dist/cjs.js??ref--13-0!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ModalDeleteLeadSource.vue?vue&type=script&lang=js\"","export * from \"-!../../../../node_modules/cache-loader/dist/cjs.js?{\\\"cacheDirectory\\\":\\\"node_modules/.cache/vue-loader\\\",\\\"cacheIdentifier\\\":\\\"381a4baa-vue-loader-template\\\"}!../../../../node_modules/cache-loader/dist/cjs.js??ref--13-0!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/vue-loader/lib/loaders/templateLoader.js??ref--6!../../../../node_modules/cache-loader/dist/cjs.js??ref--1-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ModalDeleteLeadSource.vue?vue&type=template&id=be3c5540\""],"sourceRoot":""}