Commit d7033d45 authored by Théo GUILLON's avatar Théo GUILLON
Browse files

Ajout : du champ 'ifNot' dasn l'écriture de la condition

parent d202dfd8
......@@ -259,6 +259,7 @@
var hasValue = $('#hasValue').val();
var thenTheField = $('#thenTheField').val();
var mustBe = $('#mustBe').val();
var ifNot = $('#ifNot').val();
var success = true;
if (!ifTheField) {
......@@ -281,6 +282,11 @@
success = false;
}
if (!ifNot) {
$('#ifNot').parent().parent().append('<div class="error-message">Champ obligatoire</div>');
success = false;
}
if (success == false) {
return success;
}
......@@ -289,7 +295,8 @@
'ifTheField' : ifTheField,
'hasValue' : hasValue,
'thenTheField' : thenTheField,
'mustBe' : mustBe
'mustBe' : mustBe,
'ifNot' : ifNot
};
var conditions = {};
......
Markdown is supported
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