diff --git a/vue/src/apps/ImportView/ImportView.vue b/vue/src/apps/ImportView/ImportView.vue index b7a339734..c340a26a3 100644 --- a/vue/src/apps/ImportView/ImportView.vue +++ b/vue/src/apps/ImportView/ImportView.vue @@ -52,23 +52,23 @@ - - - - - - - - - - - - - + + + + + + + + + + + + + - - - + + + @@ -238,17 +238,20 @@ +
+ +
- Import & + Import & View Import & Edit + v-if="!import_multiple" :disabled="import_loading">Import & Edit - Import & + Import & Restart - Restart + Restart
@@ -462,6 +465,7 @@ export default { source_data: '', recipe_json: undefined, use_plural: false, + import_loading: false, // recipe_html: undefined, // recipe_tree: undefined, recipe_images: [], @@ -504,6 +508,7 @@ export default { * @param silent do not show any messages for imports */ importRecipe: function (action, data, silent) { + this.import_loading = true if (this.recipe_json !== undefined) { this.$set(this.recipe_json, 'keywords', this.recipe_json.keywords.filter(k => k.show)) } @@ -528,12 +533,14 @@ export default { if (recipe_json.source_url !== '') { this.failed_imports.push(recipe_json.source_url) } + this.import_loading = false if (!silent) { StandardToasts.makeStandardToast(this, StandardToasts.FAIL_CREATE) } }) } else { console.log('cant import recipe without data') + this.import_loading = false if (!silent) { StandardToasts.makeStandardToast(this, StandardToasts.FAIL_CREATE) } @@ -563,6 +570,7 @@ export default { this.imported_recipes.push(recipe) break; case 'nothing': + this.import_loading = false break; } },