[Rt-commit] rt branch 5.0/dont-disable-inline-edit-after-errors created. rt-5.0.4-64-g4e21bc9eaa
BPS Git Server
git at git.bestpractical.com
Fri Jul 14 21:05:00 UTC 2023
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "rt".
The branch, 5.0/dont-disable-inline-edit-after-errors has been created
at 4e21bc9eaabaf4239646b918390d26a5c7601e7e (commit)
- Log -----------------------------------------------------------------
commit 4e21bc9eaabaf4239646b918390d26a5c7601e7e
Author: Ronaldo Richieri <ronaldo at bestpractical.com>
Date: Fri Jul 14 18:03:32 2023 -0300
Do not disable inline edit after errors
Inline edit could fail because of various reasons like network error,
timeout, etc. People may still want to submit again or change other
tickets, so it's good to not totally disable it after errors happen.
diff --git a/share/static/js/util.js b/share/static/js/util.js
index 4fa5bae7ae..911fff2b66 100644
--- a/share/static/js/util.js
+++ b/share/static/js/util.js
@@ -1241,9 +1241,24 @@ jQuery(function () {
var renderError = function (error) {
jQuery.jGrowl(error, { sticky: true, themeState: 'none' });
- cell.addClass('error text-danger').html(loc_key('error'));
+ cell.removeClass('loading');
+ tbody.removeClass('refreshing');
+ editor.find(':input').removeAttr('disabled');
+ var errorMessage = jQuery('<div>'+loc_key('error')+'</div>')
+ .addClass('error text-danger').hide();
+ var fadeTime = 250;
+ cell.find('div.value').fadeOut(fadeTime,function () {
+ cell.append(errorMessage);
+ errorMessage.fadeIn(fadeTime, function () {
+ setTimeout(function () {
+ errorMessage.fadeOut(fadeTime, function () {
+ errorMessage.remove();
+ cell.find('div.value').fadeIn(fadeTime);
+ });
+ }, 2000);
+ });
+ });
jQuery(document).off('keyup', escapeKeyHandler);
- disableInlineEdit();
};
jQuery.ajax({
url : editor.attr('action'),
-----------------------------------------------------------------------
hooks/post-receive
--
rt
More information about the rt-commit
mailing list