TagSpaces is an offline, open source, document manager with tagging support
fixing creating multiple taggroups #367
uggrock7f108bb41ed6
diff --git a/data/js/tags.ui.js b/data/js/tags.ui.jsindex ae05dc578..8f0e87784 100644--- a/data/js/tags.ui.js+++ b/data/js/tags.ui.js@@ -167,16 +167,18 @@ define(function(require, exports, module) {});generateTagGroups();});- $('#createTagGroupButton').click(function() {- TSCORE.Config.createTagGroup(TSCORE.selectedTagData, $('#newTagGroupName').val());- generateTagGroups();- });+ $('#createTagGroupButton').on("click", createTagGroup);$('#editTagGroupButton').click(function() {TSCORE.Config.editTagGroup(TSCORE.selectedTagData, $('#tagGroupName').val());generateTagGroups();});}+ function createTagGroup() {+ TSCORE.Config.createTagGroup(TSCORE.selectedTagData, $('#newTagGroupName').val());+ generateTagGroups();+ }+function generateTagGroups() {console.log('Generating TagGroups...');var $tagGroupsContent = $('#tagGroupsContent');@@ -523,7 +525,8 @@ define(function(require, exports, module) {function showDialogTagGroupCreate() {$('#newTagGroupName').val('');$('#formTagGroupCreate').validator();- $('#formTagGroupCreate').submit(function(e) {+ $('#formTagGroupCreate').off();+ $('#formTagGroupCreate').on("submit", function(e) {e.preventDefault();if ($('#createTagGroupButton').prop('disabled') === false) {$('#createTagGroupButton').click();