{"version":3,"sources":["webpack:///src/components/Proposals/ModalDeleteRequest.vue","webpack:///./src/components/Proposals/ModalDeleteRequest.vue","webpack:///./src/components/Proposals/ModalDeleteRequest.vue?8955","webpack:///./src/components/Proposals/ModalDeleteRequest.vue?08cc","webpack:///./src/components/Proposals/ModalDeleteRequest.vue?da97"],"names":["components","BaseCheckbox","props","showModal","type","Boolean","default","onClickCancel","Function","required","locationId","Number","request","Object","data","isDeleteConfirmed","isDeleting","isDeletingSuccess","isDeletingError","computed","locationRequest","_this","lr","index","Locations","findIndex","l","LocationId","created","methods","deleteRequest","_this2","self","rfpProvider","DeleteProposalRequestLocation","Key","then","response","status","$emit","finally","isStopping","render","_vm","_c","_self","attrs","modalTitle","confirmButtonCssClass","buttonLabelConfirm","$t","isSaving","isSavingSuccess","isSavingError","hideFooterButtons","disableSaveButton","onClickSave","on","closeModal","scopedSlots","_u","key","fn","staticClass","_v","_s","label","model","value","callback","$$v","expression","proxy","slot","staticRenderFns","_withStripped"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAiCA;AACA;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,UAAA;MACAN,IAAA,EAAAO,MAAA;MACAF,QAAA;IACA;IAEAG,OAAA;MACAR,IAAA,EAAAS,MAAA;MACAP,OAAA;IACA;EACA;EAEAQ,IAAA,WAAAA,KAAA;IACA;MACAC,iBAAA;MACAC,UAAA;MACAC,iBAAA;MACAC,eAAA;IACA;EACA;EAEAC,QAAA;IACAC,eAAA,WAAAA,gBAAA;MAAA,IAAAC,KAAA;MACA,IAAAC,EAAA;MAEA,IAAAC,KAAA,QAAAX,OAAA,CAAAY,SAAA,CAAAC,SAAA,CACA,UAAAC,CAAA;QAAA,OAAAA,CAAA,CA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,gBAAgB,mHAAU;AAC1B,EAAE,+FAAM;AACR,EAAE,oGAAM;AACR,EAAE,6GAAe;AACjB;AACA;AACA;AACA;;AAEA;;AAEA;AACA,IAAI,KAAU,EAAE,YAiBf;AACD;AACe,gF;;;;;;;;;;;;;ACtCf;AAA0S,CAAgB,oVAAG,EAAC,C;;;;;;;;;;;;;ACA9T;AAAA;AAAA;AAAA;AAAA","file":"js/384.js?id=f0980862b194c34bde02","sourcesContent":["<template>\n    <ui-component-modal\n    modalTitle=''\n    confirmButtonCssClass=\"is-danger\"\n    :buttonLabelConfirm=\"$t('Form.Control.Delete')\"\n    :isSaving='isDeleting'\n    :isSavingSuccess='isDeletingSuccess'\n    :isSavingError='isDeletingError'\n    :hideFooterButtons='isDeletingError || isDeletingSuccess'\n    :disableSaveButton=\"!isDeleteConfirmed\"\n    :onClickCancel='onClickCancel'\n    :onClickSave='deleteRequest'\n    :showModal='showModal'\n    @closeModal='onClickCancel'\n  >\n    <template slot='modalTitle'></template>\n    <template v-slot:content>\n      <div class=\"has-margin-bottom is-size-5 has-text-centered\">\n        {{ $t('Components.Proposals.ModalDeleteRequest.Text_Description') }}\n      </div>\n\n      <div class=\"has-text-centered has-margin-bottom\">\n        <BaseCheckbox\n          v-model=\"isDeleteConfirmed\"\n          class=\"has-text-left\"\n          :label=\"$t('Components.Reservation.ModalDeleteOption.Label_YesSure')\"\n        />\n      </div>\n    </template>\n  </ui-component-modal>\n</template>\n\n<script>\nimport { EventBus } from '@/eventbus/event-bus'\nimport rfpProvider from '@/providers/rfp'\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    locationId: {\n      type: Number,\n      required: true\n    },\n\n    request: {\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    locationRequest() {\n      let lr = null;\n\n      let index = this.request.Locations.findIndex(\n        (l) => l.LocationId === this.locationId\n      );\n      if (index > -1) {\n        lr = this.request.Locations[index];\n      }\n\n      return lr;\n    },\n  },\n\n  created() {},\n\n  methods: {\n    deleteRequest() {\n      let self = this\n\n      if (!self.isDeleting) {\n        self.isDeleting = true\n\n        rfpProvider.methods.DeleteProposalRequestLocation(this.locationRequest.LocationId, this.request.Key)\n        .then((response) => {\n          if (response.status === 204) {\n            this.$emit('requestDeleted')\n          }\n        })\n        .finally(() => {\n          this.isStopping = false;\n        })\n      }\n\n\n    }\n  }\n}\n</script>","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: \"\",\n        confirmButtonCssClass: \"is-danger\",\n        buttonLabelConfirm: _vm.$t(\"Form.Control.Delete\"),\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.deleteRequest,\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(\n                \"div\",\n                {\n                  staticClass: \"has-margin-bottom is-size-5 has-text-centered\",\n                },\n                [\n                  _vm._v(\n                    \" \" +\n                      _vm._s(\n                        _vm.$t(\n                          \"Components.Proposals.ModalDeleteRequest.Text_Description\"\n                        )\n                      ) +\n                      \" \"\n                  ),\n                ]\n              ),\n              _c(\n                \"div\",\n                { staticClass: \"has-text-centered has-margin-bottom\" },\n                [\n                  _c(\"BaseCheckbox\", {\n                    staticClass: \"has-text-left\",\n                    attrs: {\n                      label: _vm.$t(\n                        \"Components.Reservation.ModalDeleteOption.Label_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 \"./ModalDeleteRequest.vue?vue&type=template&id=38db7795\"\nimport script from \"./ModalDeleteRequest.vue?vue&type=script&lang=js\"\nexport * from \"./ModalDeleteRequest.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('38db7795')) {\n      api.createRecord('38db7795', component.options)\n    } else {\n      api.reload('38db7795', component.options)\n    }\n    module.hot.accept(\"./ModalDeleteRequest.vue?vue&type=template&id=38db7795\", function () {\n      api.rerender('38db7795', {\n        render: render,\n        staticRenderFns: staticRenderFns\n      })\n    })\n  }\n}\ncomponent.options.__file = \"src/components/Proposals/ModalDeleteRequest.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!./ModalDeleteRequest.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!./ModalDeleteRequest.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!./ModalDeleteRequest.vue?vue&type=template&id=38db7795\""],"sourceRoot":""}