Commit f4a2c9af authored by Wouter Wolters's avatar Wouter Wolters Committed by Christian Kuhn
Browse files

[TASK] Use new modal for not found page when using &edit as parameter

When using &edit=123124312321 as extra parameter for the backend
an oldschool alert is shown.
Replace this with a nicer modal.

Resolves: #78533
Releases: master
Change-Id: I83d3c7bd358a0eced599a31ec51af6186089d723
Reviewed-on: https://review.typo3.org/50477


Tested-by: default avatarTYPO3com <no-reply@typo3.com>
Tested-by: Riccardo De Contardi's avatarRiccardo De Contardi <erredeco@gmail.com>
Reviewed-by: default avatarMichael Oehlhof <typo3@oehlhof.de>
Tested-by: default avatarMichael Oehlhof <typo3@oehlhof.de>
Reviewed-by: Christian Kuhn's avatarChristian Kuhn <lolli@schwarzbu.ch>
Tested-by: Christian Kuhn's avatarChristian Kuhn <lolli@schwarzbu.ch>
parent ba21e9cf
......@@ -661,9 +661,18 @@ class BackendController
}
} else {
$this->js .= '
// Warning about page editing:
alert(' . GeneralUtility::quoteJSvalue(sprintf($this->getLanguageService()->getLL('noEditPage'), $editId)) . ');
';
// Warning about page editing:
require(["TYPO3/CMS/Backend/Modal", "TYPO3/CMS/Backend/Severity"], function(Modal, Severity) {
Modal.show("", ' . GeneralUtility::quoteJSvalue(sprintf($this->getLanguageService()->getLL('noEditPage'), $editId)) . ', Severity.notice, [{
text: ' . GeneralUtility::quoteJSvalue($this->getLanguageService()->sL('LLL:EXT:lang/locallang_common.xlf:close')) . ',
active: true,
btnClass: "btn-info",
name: "cancel",
trigger: function () {
Modal.currentModal.trigger("modal-dismiss");
}
}])
});';
}
}
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment