Add Question.valid_file_portrait as well as crop editor for images

This commit is contained in:
Raphael Michel
2021-04-19 15:39:38 +02:00
parent 638b856f42
commit 24bccf8b9c
24 changed files with 4239 additions and 21 deletions

View File

@@ -567,6 +567,7 @@ var form_handlers = function (el) {
el.find("input[name*=question], select[name*=question]").change(questions_toggle_dependent);
questions_toggle_dependent();
questions_init_photos(el);
};
$(function () {

View File

@@ -105,6 +105,7 @@ $(function () {
$("#valid-date").toggle($("#id_type").val() == "D");
$("#valid-datetime").toggle($("#id_type").val() == "W");
$("#valid-number").toggle($("#id_type").val() == "N");
$("#valid-file").toggle($("#id_type").val() == "F");
show = $("#id_type").val() == "B" && $("#id_required").prop("checked");
$(".alert-required-boolean").toggle(show);