File tree 2 files changed +4
-10
lines changed
2 files changed +4
-10
lines changed Original file line number Diff line number Diff line change 41
41
}
42
42
43
43
if (!$ question ->add ($ _REQUEST )) {
44
- http_response_code (500 );
45
- echo array_shift ($ _SESSION ['MESSAGE_AFTER_REDIRECT ' ][ERROR ]);
46
- unset($ _SESSION ['MESSAGE_AFTER_REDIRECT ' ][ERROR ]);
44
+ http_response_code (400 );
47
45
exit ;
48
46
}
49
47
$ json = [
Original file line number Diff line number Diff line change @@ -817,13 +817,9 @@ function buildTiles(list) {
817
817
data: form.serializeArray(),
818
818
dataType: 'json'
819
819
}).fail(function(data) {
820
- // Closing and opening the modal workarounds
821
- // the whole modal being disabled when alert is shown
822
- // modalWindow.dialog('close');
823
- // alert(data.responseText);
824
- // modalWindow.dialog('open');
825
- $('#plugin_formcreator_error').text(data.responseText);
826
- $('#plugin_formcreator_error').show();
820
+ // fix for GLPI <= 9.5.2
821
+ $('[id^="message_after_redirect_"]').remove();
822
+ displayAjaxMessageAfterRedirect();
827
823
}).done(function(data) {
828
824
var sectionId = form.find('select[name="plugin_formcreator_sections_id"]').val();
829
825
var container = $('[data-itemtype="PluginFormcreatorSection"][data-id="' + sectionId + '"] .grid-stack');
You can’t perform that action at this time.
0 commit comments