improved concernement admin form
This commit is contained in:
parent
180436dfce
commit
a6bb304bff
|
@ -121,7 +121,7 @@ third_party_settings:
|
|||
group_sources:
|
||||
children:
|
||||
- field_sources
|
||||
label: Sources
|
||||
label: 'Expériences vécues'
|
||||
region: content
|
||||
parent_name: group_tabs
|
||||
weight: 15
|
||||
|
|
|
@ -6,7 +6,12 @@ dependencies:
|
|||
- field.storage.node.body
|
||||
- node.type.besoin
|
||||
module:
|
||||
- allowed_formats
|
||||
- text
|
||||
third_party_settings:
|
||||
allowed_formats:
|
||||
allowed_formats:
|
||||
- linkonly
|
||||
id: node.besoin.body
|
||||
field_name: body
|
||||
entity_type: node
|
||||
|
|
|
@ -12,7 +12,7 @@ id: node.entite.field_sources
|
|||
field_name: field_sources
|
||||
entity_type: node
|
||||
bundle: entite
|
||||
label: Sources
|
||||
label: 'Experiences vécues'
|
||||
description: 'Comment avez-vous eu connaissance de cette menace / ce maintient ?'
|
||||
required: false
|
||||
translatable: false
|
||||
|
@ -25,12 +25,15 @@ settings:
|
|||
source: source
|
||||
negate: 0
|
||||
target_bundles_drag_drop:
|
||||
action:
|
||||
weight: 4
|
||||
doleance:
|
||||
weight: 5
|
||||
enabled: false
|
||||
entite_concernement:
|
||||
weight: 5
|
||||
enabled: false
|
||||
etape:
|
||||
weight: 7
|
||||
enabled: false
|
||||
source:
|
||||
weight: 6
|
||||
enabled: true
|
||||
|
|
|
@ -3,7 +3,7 @@ langcode: fr
|
|||
status: true
|
||||
dependencies: { }
|
||||
id: source
|
||||
label: source
|
||||
label: 'Expérience vécue'
|
||||
icon_uuid: null
|
||||
icon_default: null
|
||||
description: 'action''s source'
|
||||
|
|
|
@ -206,6 +206,9 @@ div[data-drupal-selector=edit-actions] > * {
|
|||
#node-concernement-edit-form .ief-entity-operations input[type=submit].ief-submit-remove {
|
||||
display: none;
|
||||
}
|
||||
#node-concernement-edit-form .field--name-field-date > * {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
#boussole-layout {
|
||||
display: flex;
|
||||
|
|
|
@ -1 +1 @@
|
|||
{"version":3,"sourceRoot":"","sources":["../scss/ouatminimal.scss"],"names":[],"mappings":"AAAA;AACA;EACE;EACA;;;AAEF;AAAA;EAEE;;;AAEF;EACE;;;AAGF;EACE;EACA;;;AAGF;AAKI;EACE;;;AAKN;EACE;EACA;;AACA;EACE;EACA;;;AAIJ;EACE;EACA;;;AAGF;EACE;EACA;;;AAGF;AACE;EACA;EACA;;;AAEF;AAAA;EAEE;EACA;;;AAEF;AAAA;EAEE;EACA;;;AAGF;EACE;;;AAEF;EACE;;;AAEF;EACE;;;AAEF;EACE;;;AAEF;EACE;EACA;;;AAGF;AAAA;AAAA;AAIA;AACA;EACE;;;AAGF;AACA;EAIE;IACE;IACA;IACA;;EAGF;IACE;IACA;;EAGF;AACE;IACA;IACA;IAEA;AACA;IACA;;EAGF;IACE;IACA;IACA;;EAGF;AACE;IACA;IACA;AACA;IACA;;EAGF;IACE;;AAGF;EACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;IASE;IACA;IACA;;;AAIJ;AAAA;AAAA;AAAA;AAAA;AAAA;AAMA;EAEE;IACE;;EAEF;AAAA;AAAA;IAGE;IACA;IACA;;;AAKJ;AAEE;EACE;EACA;EACA;EAAU;EACV;AAeA;AAAA;AAAA;;AAbA;EACE;;AAEF;EACE;EACA;EACA;;AAEF;AAAA;EAEE;EACA;;AAQJ;AACE;EACA;;AAEF;EACE;;AAKA;AAAA;AAAA;AAAA;AAAA;AAAA;EAGE;;AAEF;AAAA;AAAA;AAAA;AAAA;AAAA;EAGE;;AAKJ;EACE;;;AAOJ;EACE;EACA;EACA;;AAEA;EACE;;AAKF;EACE;EACA;EACA;;AAGE;EACE;EACA;EACA;;AAIF;EACE;;AAEA;EACE;EACA;EACA;EACA;;AAEA;EACE;EACA;;AAGF;EACE;;AAKR;EACE;EACA;EACA;;AAEA;EACE;;AAIA;EACE;;AAEF;EACE;;AAWN;EACE;EACA;;AAKA;AAAA;EACE;;AAGF;AAAA;EACE;;AACA;AAAA;EACE;;AAMN;EACE;;AAeJ;EACE;EACA;AAEA;;AACA;EACE;EACA;EACA;EACA;EACA;EACA;AACA;EACA;EACA;EACA;;AAEA;EACE;EACA;EAAY;EACZ;EACA;EACA;EACA;;AAEA;EACE;;AAEF;EACE;EACA;;AAEF;EACE;;AAGF;EACE;;;AAYV;AAAA;AAAA;EAGE;;;AAGF;AAAA;EAEE;;;AAMF;EACE;EACA;EACA;;AACA;EACE;;AAEF;EACE","file":"ouatminimal.css"}
|
||||
{"version":3,"sourceRoot":"","sources":["../scss/ouatminimal.scss"],"names":[],"mappings":"AAAA;AACA;EACE;EACA;;;AAEF;AAAA;EAEE;;;AAEF;EACE;;;AAGF;EACE;EACA;;;AAGF;AAKI;EACE;;;AAKN;EACE;EACA;;AACA;EACE;EACA;;;AAIJ;EACE;EACA;;;AAGF;EACE;EACA;;;AAGF;AACE;EACA;EACA;;;AAEF;AAAA;EAEE;EACA;;;AAEF;AAAA;EAEE;EACA;;;AAGF;EACE;;;AAEF;EACE;;;AAEF;EACE;;;AAEF;EACE;;;AAEF;EACE;EACA;;;AAGF;AAAA;AAAA;AAIA;AACA;EACE;;;AAGF;AACA;EAIE;IACE;IACA;IACA;;EAGF;IACE;IACA;;EAGF;AACE;IACA;IACA;IAEA;AACA;IACA;;EAGF;IACE;IACA;IACA;;EAGF;AACE;IACA;IACA;AACA;IACA;;EAGF;IACE;;AAGF;EACA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;IASE;IACA;IACA;;;AAIJ;AAAA;AAAA;AAAA;AAAA;AAAA;AAMA;EAEE;IACE;;EAEF;AAAA;AAAA;IAGE;IACA;IACA;;;AAKJ;AAEE;EACE;EACA;EACA;EAAU;EACV;AAeA;AAAA;AAAA;;AAbA;EACE;;AAEF;EACE;EACA;EACA;;AAEF;AAAA;EAEE;EACA;;AAQJ;AACE;EACA;;AAEF;EACE;;AAKA;AAAA;AAAA;AAAA;AAAA;AAAA;EAGE;;AAEF;AAAA;AAAA;AAAA;AAAA;AAAA;EAGE;;AAKJ;EACE;;AAIA;EACE;;;AAQN;EACE;EACA;EACA;;AAEA;EACE;;AAKF;EACE;EACA;EACA;;AAGE;EACE;EACA;EACA;;AAIF;EACE;;AAEA;EACE;EACA;EACA;EACA;;AAEA;EACE;EACA;;AAGF;EACE;;AAKR;EACE;EACA;EACA;;AAEA;EACE;;AAIA;EACE;;AAEF;EACE;;AAWN;EACE;EACA;;AAKA;AAAA;EACE;;AAGF;AAAA;EACE;;AACA;AAAA;EACE;;AAMN;EACE;;AAeJ;EACE;EACA;AAEA;;AACA;EACE;EACA;EACA;EACA;EACA;EACA;AACA;EACA;EACA;EACA;;AAEA;EACE;EACA;EAAY;EACZ;EACA;EACA;EACA;;AAEA;EACE;;AAEF;EACE;EACA;;AAEF;EACE;;AAGF;EACE;;;AAYV;AAAA;AAAA;EAGE;;;AAGF;AAAA;EAEE;;;AAMF;EACE;EACA;EACA;;AACA;EACE;;AAEF;EACE","file":"ouatminimal.css"}
|
|
@ -157,17 +157,16 @@ function ouatminimal_preprocess_input(&$variables) {
|
|||
if (preg_match('/^ief-field_entite-\d+-subform-field_entite-form-add$/', $name)) {
|
||||
$element['#value'] = $element['#attributes']['value'] = $variables['attributes']['value'] = "Editer l'entité";
|
||||
}
|
||||
// // rename entité reference in paragraphe "Ajouter un node existant" to "ajouyer entite existante"
|
||||
// // "ief-field_entite-0-subform-field_entite-form-add"
|
||||
// if (preg_match('/^ief-field_entite-\d+-subform-field_entite-form-add-existing$/', $name)) {
|
||||
// $element['#value'] = $element['#attributes']['value'] = $variables['attributes']['value'] = "Ajouter une entité éxistante";
|
||||
// }
|
||||
|
||||
// // rename entité reference in paragraphe "Ajout de node" to "Ajouter"
|
||||
// // "ief-reference-submit-field_entite-7-subform-field_entite-form"
|
||||
// if (preg_match('/^ief-reference-submit-field_entite-\d+-subform-field_entite-form$/', $name)) {
|
||||
// $element['#value'] = $element['#attributes']['value'] = $variables['attributes']['value'] = "Ajouter";
|
||||
// }
|
||||
// ief-add-submit-field_entite-15-subform-field_entite-form
|
||||
if (preg_match('/^ief-add-submit-field_entite-\d+-subform-field_entite-form$/', $name)) {
|
||||
$element['#value'] = $element['#attributes']['value'] = $variables['attributes']['value'] = "Créer l'entité";
|
||||
}
|
||||
|
||||
// ief-edit-submit-field_entite-14-subform-field_entite-form-0
|
||||
if (preg_match('/^ief-edit-submit-field_entite-\d+-subform-field_entite-form-\d+$/', $name)) {
|
||||
$element['#value'] = $element['#attributes']['value'] = $variables['attributes']['value'] = "Enregistrer l'entité";
|
||||
}
|
||||
|
||||
// rename remove (paragraphe) to "supprimer"
|
||||
if (preg_match('/field_entite_\d+_remove/', $name)) {
|
||||
|
|
|
@ -222,6 +222,12 @@ div[data-drupal-selector="edit-actions"]{
|
|||
.ief-entity-operations input[type="submit"].ief-submit-remove{
|
||||
display: none;
|
||||
}
|
||||
|
||||
.field--name-field-date{
|
||||
>*{
|
||||
display: inline-block;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -0,0 +1,44 @@
|
|||
{#
|
||||
/**
|
||||
* @file
|
||||
* Default theme implementation for an individual form element.
|
||||
*
|
||||
* Available variables for all fields:
|
||||
* - multiple: Whether there are multiple instances of the field.
|
||||
*
|
||||
* Available variables for single cardinality fields:
|
||||
* - elements: Form elements to be rendered.
|
||||
*
|
||||
* Available variables when there are multiple fields.
|
||||
* - table: Table of field items.
|
||||
* - description: The description element containing the following properties:
|
||||
* - content: The description content of the form element.
|
||||
* - attributes: HTML attributes to apply to the description container.
|
||||
* - button: "Add another item" button.
|
||||
*
|
||||
* @see template_preprocess_field_multiple_value_form()
|
||||
*
|
||||
* @ingroup themeable
|
||||
*/
|
||||
#}
|
||||
{% if multiple %}
|
||||
{%
|
||||
set classes = [
|
||||
'js-form-item',
|
||||
'form-item'
|
||||
]
|
||||
%}
|
||||
<div{{ attributes.addClass(classes) }}>
|
||||
{% if description.content %}
|
||||
<div{{ description.attributes.addClass('description') }} >{{ description.content }}</div>
|
||||
{% endif %}
|
||||
{{ table }}
|
||||
{% if button %}
|
||||
<div class="clearfix">{{ button }}</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
{% else %}
|
||||
{% for element in elements %}
|
||||
{{ element }}
|
||||
{% endfor %}
|
||||
{% endif %}
|
Loading…
Reference in New Issue