Преглед на файлове

make new properties columns optional by default

Nicolas Cannasse преди 4 години
родител
ревизия
b79cb75388
променени са 1 файла, в които са добавени 2 реда и са изтрити 1 реда
  1. 2 1
      hide/comp/cdb/ModalColumnForm.hx

+ 2 - 1
hide/comp/cdb/ModalColumnForm.hx

@@ -184,7 +184,8 @@ class ModalColumnForm extends Modal {
 		} else {
 			form.addClass("create");
 			form.find("input").not("[type=submit]").val("");
-			form.find("[name=req]").prop("checked", true);
+			var isProp = sheet.parent != null && sheet.parent.sheet.columns[sheet.parent.column].type == TProperties;
+			form.find("[name=req]").prop("checked", !isProp);
 			form.find("[name=kind]").val("");
 		}