{"version":3,"sources":["webpack:///src/components/Notes/ModalDeleteNote.vue","webpack:///./src/components/Notes/ModalDeleteNote.vue","webpack:///./src/components/Notes/ModalDeleteNote.vue?7758","webpack:///./src/components/Notes/ModalDeleteNote.vue?a0a8","webpack:///./src/components/Notes/ModalDeleteNote.vue?69c2","webpack:///./src/eventbus/event-bus.js"],"names":["BaseCheckbox","components","props","note","type","Object","default","showModal","Boolean","onClickCancel","Function","required","data","isDeleteConfirmed","isDeleting","isDeletingSuccess","isDeletingError","computed","created","methods","deleteNote","self","noteProvider","Id","then","response","status","$emit","catch","error","finally","render","_vm","_c","_self","attrs","modalTitle","$t","buttonLabelConfirm","confirmButtonCssClass","isSaving","isSavingSuccess","isSavingError","hideFooterButtons","disableSaveButton","onClickSave","savingSuccessMessage","on","closeModal","scopedSlots","_u","key","fn","staticClass","_v","_s","Subject","label","model","value","callback","$$v","expression","proxy","slot","staticRenderFns","_withStripped","EventBus","Vue"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AA0CA;AACA;AACA;AACA;AAEA,IAAAA,YAAA,YAAAA,aAAA;EAAA;AAAA;AAEe;EACfC,UAAA;IACAD,YAAA,EAAAA;EACA;EAEAE,KAAA;IACAC,IAAA;MACAC,IAAA,EAAAC,MAAA;MACAC,OAAA;IACA;IAEAC,SAAA;MACAH,IAAA,EAAAI,OAAA;MACAF,OAAA;IACA;IAEAG,aAAA;MACAL,IAAA,EAAAM,QAAA;MACAC,QAAA;IACA;EACA;EAEAC,IAAA,WAAAA,KAAA;IACA;MACAC,iBAAA;MACAC,UAAA;MACAC,iBAAA;MACAC,eAAA;IACA;EACA;EAEAC,QAAA;EAEAC,OAAA,WAAAA,QAAA;EAEAC,OAAA;IACAC,UAAA,WAAAA,WAAA;MACA,IAAAC,IAAA;MAEA,KAAAA,IAAA,CAAAP,UAAA;QACAO,IAAA,CAAAP,UAAA;QAEAQ,+DAAA,CAAAH,OAAA,CACAC,UAAA,CAAAC,IAAA,CAAAlB,IAAA,CAAA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CAAC;AACD,IAAIC,eAAe,GAAG,EAAE;AACxBlC,MAAM,CAACmC,aAAa,GAAG,IAAI;;;;;;;;;;;;;;ACrF3B;AAAA;AAAA;AAAA;AAA6F;AAC3B;AACL;;;AAG7D;AAC6F;AAC7F,gBAAgB,mHAAU;AAC1B,EAAE,4FAAM;AACR,EAAE,iGAAM;AACR,EAAE,0GAAe;AACjB;AACA;AACA;AACA;;AAEA;;AAEA;AACA,IAAI,KAAU,EAAE,YAiBf;AACD;AACe,gF;;;;;;;;;;;;;ACtCf;AAAuS,CAAgB,iVAAG,EAAC,C;;;;;;;;;;;;;ACA3T;AAAA;AAAA;AAAA;AAAA;;;;;;;;;;;;;;ACAA;AAAA;AAAqB;AACd,IAAMC,QAAQ,GAAG,IAAIC,2CAAG,CAAC,CAAC;AAElBD,iEAAQ,E","file":"js/299.js?id=877221864a9ea3f4225d","sourcesContent":["<template>\n  <ui-component-modal\n    :modalTitle=\"$t('Components.Notes.ModalDeleteNote.Modal_Title')\"\n    :buttonLabelConfirm=\"$t('Form.Control.Delete')\"\n    confirmButtonCssClass=\"is-danger\"\n    :isSaving=\"isDeleting\"\n    :isSavingSuccess=\"isDeletingSuccess\"\n    :isSavingError=\"isDeletingError\"\n    :hideFooterButtons=\"isDeletingError || isDeletingSuccess\"\n    :disableSaveButton=\"!isDeleteConfirmed\"\n    :onClickCancel=\"onClickCancel\"\n    :onClickSave=\"deleteNote\"\n    :showModal=\"showModal\"\n    @closeModal=\"onClickCancel\"\n    :savingSuccessMessage=\"\n      $t('Components.Notes.ModalDeleteNote.Modal_DeletingSuccess')\n    \"\n  >\n    <template slot=\"modalTitle\"></template>\n    <template v-slot:content>\n      <div>\n        <div class=\"has-text-centered has-margin-bottom\">\n          {{ $t('Components.Notes.ModalDeleteNote.Modal_TextAreYouSure') }}\n        </div>\n        <div class=\"has-text-centered\">\n          <div class=\"has-margin-bottom has-margin-top\">\n            <b>{{ note.Subject }}</b>\n          </div>\n        </div>\n        <div class=\"has-text-centered\">\n          <BaseCheckbox\n            v-model=\"isDeleteConfirmed\"\n            class=\"has-text-left\"\n            :label=\"$t('Components.ToDos.ModalDeleteToDo.Text_YesSure')\"\n          />\n        </div>\n      </div>\n    </template>\n  </ui-component-modal>\n</template>\n\n<script>\nimport Vue from 'vue'\nimport { mapState, mapMutations } from 'vuex'\nimport { EventBus } from '@/eventbus/event-bus'\nimport noteProvider from '@/providers/note'\n\nconst BaseCheckbox = () => import('@/components/UI/Form/BaseCheckbox')\n\nexport default {\n  components: {\n    BaseCheckbox,\n  },\n\n  props: {\n    note: {\n      type: Object,\n      default: null,\n    },\n\n    showModal: {\n      type: Boolean,\n      default: false,\n    },\n\n    onClickCancel: {\n      type: Function,\n      required: true,\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    deleteNote() {\n      let self = this\n\n      if (!self.isDeleting) {\n        self.isDeleting = true\n\n        noteProvider.methods\n          .deleteNote(self.note.Id)\n          .then((response) => {\n            if (response.status === 204) {\n              self.$emit('noteDeleted', self.note)\n\n              self.onClickCancel()\n            }\n          })\n          .catch((error) => {\n            self.isDeletingError = true\n          })\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(\"Components.Notes.ModalDeleteNote.Modal_Title\"),\n        buttonLabelConfirm: _vm.$t(\"Form.Control.Delete\"),\n        confirmButtonCssClass: \"is-danger\",\n        isSaving: _vm.isDeleting,\n        isSavingSuccess: _vm.isDeletingSuccess,\n        isSavingError: _vm.isDeletingError,\n        hideFooterButtons: _vm.isDeletingError || _vm.isDeletingSuccess,\n        disableSaveButton: !_vm.isDeleteConfirmed,\n        onClickCancel: _vm.onClickCancel,\n        onClickSave: _vm.deleteNote,\n        showModal: _vm.showModal,\n        savingSuccessMessage: _vm.$t(\n          \"Components.Notes.ModalDeleteNote.Modal_DeletingSuccess\"\n        ),\n      },\n      on: { closeModal: _vm.onClickCancel },\n      scopedSlots: _vm._u([\n        {\n          key: \"content\",\n          fn: function () {\n            return [\n              _c(\"div\", [\n                _c(\n                  \"div\",\n                  { staticClass: \"has-text-centered has-margin-bottom\" },\n                  [\n                    _vm._v(\n                      \" \" +\n                        _vm._s(\n                          _vm.$t(\n                            \"Components.Notes.ModalDeleteNote.Modal_TextAreYouSure\"\n                          )\n                        ) +\n                        \" \"\n                    ),\n                  ]\n                ),\n                _c(\"div\", { staticClass: \"has-text-centered\" }, [\n                  _c(\n                    \"div\",\n                    { staticClass: \"has-margin-bottom has-margin-top\" },\n                    [_c(\"b\", [_vm._v(_vm._s(_vm.note.Subject))])]\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.ToDos.ModalDeleteToDo.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          },\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 \"./ModalDeleteNote.vue?vue&type=template&id=e5b5a548\"\nimport script from \"./ModalDeleteNote.vue?vue&type=script&lang=js\"\nexport * from \"./ModalDeleteNote.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('e5b5a548')) {\n      api.createRecord('e5b5a548', component.options)\n    } else {\n      api.reload('e5b5a548', component.options)\n    }\n    module.hot.accept(\"./ModalDeleteNote.vue?vue&type=template&id=e5b5a548\", function () {\n      api.rerender('e5b5a548', {\n        render: render,\n        staticRenderFns: staticRenderFns\n      })\n    })\n  }\n}\ncomponent.options.__file = \"src/components/Notes/ModalDeleteNote.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!./ModalDeleteNote.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!./ModalDeleteNote.vue?vue&type=script&lang=js\"","export * from \"-!../../../node_modules/cache-loader/dist/cjs.js?{\\\"cacheDirectory\\\":\\\"node_modules/.cache/vue-loader\\\",\\\"cacheIdentifier\\\":\\\"d2a26fb4-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!./ModalDeleteNote.vue?vue&type=template&id=e5b5a548\"","import Vue from 'vue'\nexport const EventBus = new Vue()\n\nexport default EventBus\n"],"sourceRoot":""}