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

Modification : On enregistre la condition sur le champ qui recoit la condition

Correction : orthographe
parent 3fa7e41b
......@@ -70,8 +70,8 @@
echo $this->WebcilForm->input('mustBe', [
'id' => 'mustBe',
'options' => [
'shown' => "afficher",
'hidden' => "cacher"
'shown' => "affiché",
'hidden' => "caché"
],
'empty' => true,
'class' => 'transformSelect form-control',
......@@ -87,8 +87,8 @@
echo $this->WebcilForm->input('ifNot', [
'id' => 'ifNot',
'options' => [
'shown' => "afficher",
'hidden' => "cacher"
'shown' => "affiché",
'hidden' => "caché"
],
'empty' => true,
'class' => 'transformSelect form-control',
......@@ -306,12 +306,8 @@
var idContainer = '#' + $('.form-container').attr('id');
var fieldChoose = null;
if (jQuery.inArray(idFieldConditionCreated, ['transfertHorsUe', 'donneesSensible']) !== -1){
fieldChoose = $(idContainer).find('input[name ="' + thenTheField + '"], textarea[name ="' + thenTheField + '"], option[name ="' + thenTheField + '"]').closest('.draggable');
} else {
fieldChoose = $(idContainer).find('input[name ="' + idFieldConditionCreated + '"], option[name ="' + idFieldConditionCreated + '"]').closest('.draggable');
}
// On selectionne le champs qui va recevoir la condition
var fieldChoose = $(idContainer).find('input[name ="' + thenTheField + '"], textarea[name ="' + thenTheField + '"], option[name ="' + thenTheField + '"]').closest('.draggable');
var otherConditions = $(fieldChoose).attr('data-virtual-conditions');
if (otherConditions) {
......
......@@ -904,9 +904,9 @@ var createForm = function(typeCreateForm) {
}
if (value['ifNot'] == 'shown') {
ifNot = 'afficher';
ifNot = 'affiché';
} else {
ifNot = 'cacher';
ifNot = 'caché';
}
writeConditions = writeConditions + '<p>' +
......
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