From ded68bb4f66add1a7f13e8741130f822ffc17608 Mon Sep 17 00:00:00 2001 From: Matthias Date: Sun, 6 Jun 2021 16:09:51 +0200 Subject: [PATCH] change titel with modal submit --- InvenTree/templates/js/modals.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/InvenTree/templates/js/modals.js b/InvenTree/templates/js/modals.js index c8ebd90eb4..741d558164 100644 --- a/InvenTree/templates/js/modals.js +++ b/InvenTree/templates/js/modals.js @@ -776,7 +776,11 @@ function handleModalForm(url, options) { // Form was returned, invalid! else { - if (!options.hideErrorMessage) { + if (response.title) { + modalSetTitle(modal, response.title); + } + + if (response.hideErrorMessage || !options.hideErrorMessage) { var warningDiv = $(modal).find('#form-validation-warning'); warningDiv.css('display', 'block'); }