From 1aa9091e0df1c3066004051579757fcc01dd0549 Mon Sep 17 00:00:00 2001 From: Andrej Date: Tue, 3 Oct 2023 09:11:27 +0200 Subject: [PATCH] Fix protocol parser import button closing [SCI-9275] --- app/javascript/vue/protocol_import/file_import_modal.vue | 2 +- app/views/protocols/index/_general_toolbar.html.erb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/javascript/vue/protocol_import/file_import_modal.vue b/app/javascript/vue/protocol_import/file_import_modal.vue index f7ab40fc7..76d7870f3 100644 --- a/app/javascript/vue/protocol_import/file_import_modal.vue +++ b/app/javascript/vue/protocol_import/file_import_modal.vue @@ -47,6 +47,7 @@ }, methods: { open() { + $('.protocol-import-dropdown-button').dropdown('toggle'); $(this.$refs.modal).modal('show'); }, close() { @@ -66,7 +67,6 @@ confirm() { let formData = new FormData(); Array.from(this.files).forEach(file => formData.append('files[]', file, file.name)); - $('.protocol-import-dropdown').dropdown('toggle'); $.post({ url: this.importUrl, data: formData, processData: false, contentType: false }, (data) => { this.state = 'in_progress'; diff --git a/app/views/protocols/index/_general_toolbar.html.erb b/app/views/protocols/index/_general_toolbar.html.erb index d62d96203..60ba96f2d 100644 --- a/app/views/protocols/index/_general_toolbar.html.erb +++ b/app/views/protocols/index/_general_toolbar.html.erb @@ -11,7 +11,7 @@
-