From: Radek Czajka Date: Fri, 8 Jul 2022 14:28:21 +0000 (+0200) Subject: Warn about required metadata X-Git-Url: https://git.mdrn.pl/redakcja.git/commitdiff_plain/9437f74bdc87107e38ca37f21d7d74579ad6f2aa?ds=sidebyside Warn about required metadata --- diff --git a/src/redakcja/static/js/wiki/view_properties.js b/src/redakcja/static/js/wiki/view_properties.js index eeddf678..7e284a50 100644 --- a/src/redakcja/static/js/wiki/view_properties.js +++ b/src/redakcja/static/js/wiki/view_properties.js @@ -273,6 +273,13 @@ field, this); }); + + count = $('.c > .input-group', $fg).length; + if (field.required) { + if (!count) { + $('
WYMAGANE
').appendTo($('.c', $fg)); + } + } };