From 5e277e6715a650b05e7606f29381d25b9a3a33b0 Mon Sep 17 00:00:00 2001 From: Julian Ophals Date: Tue, 25 Mar 2025 16:29:02 -0700 Subject: [PATCH 1/3] Added erro message for failed file uploads --- .../src/main/webapp/WEB-INF/views/auth/group/item.html | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/citesphere/src/main/webapp/WEB-INF/views/auth/group/item.html b/citesphere/src/main/webapp/WEB-INF/views/auth/group/item.html index e55bf9880..e2f02fd01 100644 --- a/citesphere/src/main/webapp/WEB-INF/views/auth/group/item.html +++ b/citesphere/src/main/webapp/WEB-INF/views/auth/group/item.html @@ -111,7 +111,10 @@ success: function(data) { document.getElementById('uploadFileInput').value = ''; $("#uploadFileModal").modal('hide'); - } + }, + error: function(data) { + showNotification(" Error while attempting to upload files!", "danger", 10000); + } }); }); From 57c2c199b4dcf96d1fefade132b3b5a3875d84bf Mon Sep 17 00:00:00 2001 From: Julian Ophals Date: Wed, 26 Mar 2025 12:25:40 -0700 Subject: [PATCH 2/3] [story/CITE-230] added hide action to upload file pop-up --- citesphere/src/main/webapp/WEB-INF/views/auth/group/item.html | 1 + 1 file changed, 1 insertion(+) diff --git a/citesphere/src/main/webapp/WEB-INF/views/auth/group/item.html b/citesphere/src/main/webapp/WEB-INF/views/auth/group/item.html index e2f02fd01..64edf7bf7 100644 --- a/citesphere/src/main/webapp/WEB-INF/views/auth/group/item.html +++ b/citesphere/src/main/webapp/WEB-INF/views/auth/group/item.html @@ -113,6 +113,7 @@ $("#uploadFileModal").modal('hide'); }, error: function(data) { + $("#uploadFileModal").modal('hide'); showNotification(" Error while attempting to upload files!", "danger", 10000); } }); From cb6637274ad9ecb94e1d934fad22e941f7782282 Mon Sep 17 00:00:00 2001 From: Julian Ophals Date: Wed, 26 Mar 2025 16:55:13 -0700 Subject: [PATCH 3/3] [story/CITE-230] fixed indentation and removed error alert timeout --- .../webapp/WEB-INF/views/auth/group/item.html | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/citesphere/src/main/webapp/WEB-INF/views/auth/group/item.html b/citesphere/src/main/webapp/WEB-INF/views/auth/group/item.html index 64edf7bf7..1b53daeae 100644 --- a/citesphere/src/main/webapp/WEB-INF/views/auth/group/item.html +++ b/citesphere/src/main/webapp/WEB-INF/views/auth/group/item.html @@ -112,9 +112,9 @@ document.getElementById('uploadFileInput').value = ''; $("#uploadFileModal").modal('hide'); }, - error: function(data) { + error: function(data) { $("#uploadFileModal").modal('hide'); - showNotification(" Error while attempting to upload files!", "danger", 10000); + showNotification(" Error while attempting to upload files!", "danger"); } }); @@ -276,16 +276,16 @@ }); } - function showNotification(message, status, time) { + function showNotification(message, status, time=0) { $.notify(''+ message, { type: status, - offset: {x: 50, y: 90}, - timer: time, - animate: { - enter: 'animated fadeInRight', - exit: 'animated fadeOutRight' - }, - }); + offset: {x: 50, y: 90}, + timer: time, + animate: { + enter: 'animated fadeInRight', + exit: 'animated fadeOutRight' + }, + }); }