From 61d779c6ed28aa2495166b85c7771cbb3013f0bd Mon Sep 17 00:00:00 2001 From: Klemen Benedicic Date: Fri, 24 May 2024 13:44:51 +0200 Subject: [PATCH] Fixed PR commentaries, updated .gitignore [SCI-10717] --- .gitignore | 3 +++ app/javascript/vue/shared/confirmation_modal.vue | 14 +++++++------- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/.gitignore b/.gitignore index a16f03f0c..d4bf0890c 100644 --- a/.gitignore +++ b/.gitignore @@ -95,3 +95,6 @@ public/marvin4js-license.cxl /app/assets/builds/* !/app/assets/builds/.keep + +# Ignore npm files +package-lock.json diff --git a/app/javascript/vue/shared/confirmation_modal.vue b/app/javascript/vue/shared/confirmation_modal.vue index 4ba0f16a5..45f5ee48f 100644 --- a/app/javascript/vue/shared/confirmation_modal.vue +++ b/app/javascript/vue/shared/confirmation_modal.vue @@ -57,22 +57,22 @@ export default { return { resolvePromise: null, rejectPromise: null - } + }; }, methods: { - show: function() { + show() { $(this.$refs.modal).modal('show'); return new Promise((resolve, reject) => { - this.resolvePromise = resolve - this.rejectPromise = reject - }) + this.resolvePromise = resolve; + this.rejectPromise = reject; + }); }, confirm() { - this.resolvePromise(true) + this.resolvePromise(true); $(this.$refs.modal).modal('hide'); }, cancel() { - this.resolvePromise(false) + this.resolvePromise(false); $(this.$refs.modal).modal('hide'); } }