diff --git a/src/composer.json b/src/composer.json index ec0e298..7e3e929 100644 --- a/src/composer.json +++ b/src/composer.json @@ -16,6 +16,7 @@ ], "require": { "composer/installers": "^1.9", + "drupal/auto_entitylabel": "3.x-dev@dev", "drupal/core-composer-scaffold": "^9.1", "drupal/core-project-message": "^9.1", "drupal/core-recommended": "^9.1", diff --git a/src/composer.lock b/src/composer.lock index cc3adbd..16d6165 100644 --- a/src/composer.lock +++ b/src/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "81bf05c0952bcf7d3b0f73de90c42bb7", + "content-hash": "59be9916db252189be036d7363f0bd50", "packages": [ { "name": "alchemy/zippy", @@ -2401,6 +2401,76 @@ "issues": "https://www.drupal.org/project/issues/audiofield" } }, + { + "name": "drupal/auto_entitylabel", + "version": "dev-3.x", + "source": { + "type": "git", + "url": "https://git.drupalcode.org/project/auto_entitylabel.git", + "reference": "7d2063d5ee869d20e00409eca12bf6776fff7772" + }, + "require": { + "drupal/core": "^8 || ^9" + }, + "require-dev": { + "drupal/token": "^1.0" + }, + "type": "drupal-module", + "extra": { + "branch-alias": { + "dev-3.x": "3.x-dev" + }, + "drupal": { + "version": "8.x-3.0-beta3+6-dev", + "datestamp": "1609346741", + "security-coverage": { + "status": "not-covered", + "message": "Dev releases are not covered by Drupal security advisories." + } + } + }, + "notification-url": "https://packages.drupal.org/8/downloads", + "license": [ + "GPL-2.0-or-later" + ], + "authors": [ + { + "name": "Pravin Ajaaz", + "homepage": "https://www.drupal.org/user/2910049" + }, + { + "name": "RenatoG", + "homepage": "https://www.drupal.org/user/3326031" + }, + { + "name": "VladimirAus", + "homepage": "https://www.drupal.org/user/673120" + }, + { + "name": "bforchhammer", + "homepage": "https://www.drupal.org/user/216396" + }, + { + "name": "colan", + "homepage": "https://www.drupal.org/user/58704" + }, + { + "name": "diqidoq", + "homepage": "https://www.drupal.org/user/1001934" + }, + { + "name": "purushotam.rai", + "homepage": "https://www.drupal.org/user/3193859" + } + ], + "description": "Allows hiding of entity label fields and automatic label creation.", + "homepage": "https://www.drupal.org/project/auto_entitylabel", + "support": { + "source": "https://git.drupalcode.org/project/auto_entitylabel", + "issues": "https://www.drupal.org/project/issues/auto_entitylabel" + }, + "time": "2021-03-01T17:14:07+00:00" + }, { "name": "drupal/autocomplete_deluxe", "version": "2.0.0-rc1", @@ -12864,6 +12934,7 @@ "aliases": [], "minimum-stability": "stable", "stability-flags": { + "drupal/auto_entitylabel": 20, "drupal/insert": 20, "drupal/typed_data": 20, "drupal/autocomplete_deluxe": 5, diff --git a/src/config/sync/adminimal_theme.settings.yml b/src/config/sync/adminimal_theme.settings.yml index 4cb3c4c..81ca187 100644 --- a/src/config/sync/adminimal_theme.settings.yml +++ b/src/config/sync/adminimal_theme.settings.yml @@ -4,7 +4,13 @@ features: comment_user_verification: true favicon: 1 logo: - use_default: 1 + use_default: 0 + path: '' _core: default_config_hash: Pawk313dlmTas62LfDspeCxjQbNtOVl3_Uyi3REvu1A langcode: fr +favicon: + use_default: 0 + path: '' +custom_css: 0 +disable_google_fonts: 0 diff --git a/src/config/sync/auto_entitylabel.settings.taxonomy_term.auteurs.yml b/src/config/sync/auto_entitylabel.settings.taxonomy_term.auteurs.yml new file mode 100644 index 0000000..7561c80 --- /dev/null +++ b/src/config/sync/auto_entitylabel.settings.taxonomy_term.auteurs.yml @@ -0,0 +1,9 @@ +status: 1 +pattern: '[term:field_prenom:value] [term:field_nom:value]' +escape: false +preserve_titles: false +save: false +chunk: 50 +dependencies: + config: + - taxonomy.vocabulary.auteurs diff --git a/src/config/sync/core.entity_form_display.node.creation.default.yml b/src/config/sync/core.entity_form_display.node.creation.default.yml index 696a3ab..bb16020 100644 --- a/src/config/sync/core.entity_form_display.node.creation.default.yml +++ b/src/config/sync/core.entity_form_display.node.creation.default.yml @@ -4,7 +4,7 @@ status: true dependencies: config: - field.field.node.creation.body - - field.field.node.creation.field_autheurs + - field.field.node.creation.field_auteurs - field.field.node.creation.field_oeuvre - node.type.creation module: @@ -43,7 +43,7 @@ content: show_summary: false third_party_settings: { } region: content - field_autheurs: + field_auteurs: weight: 0 settings: match_operator: CONTAINS diff --git a/src/config/sync/core.entity_form_display.node.texte.default.yml b/src/config/sync/core.entity_form_display.node.texte.default.yml index 020b357..c96ead8 100644 --- a/src/config/sync/core.entity_form_display.node.texte.default.yml +++ b/src/config/sync/core.entity_form_display.node.texte.default.yml @@ -4,7 +4,7 @@ status: true dependencies: config: - field.field.node.texte.body - - field.field.node.texte.field_autheurs + - field.field.node.texte.field_auteurs - field.field.node.texte.field_degres_detrangement - field.field.node.texte.field_edition - field.field.node.texte.field_famille @@ -54,7 +54,7 @@ third_party_settings: parent_name: group_tabs weight: 5 format_type: tab - region: hidden + region: content format_settings: id: '' classes: '' @@ -70,7 +70,7 @@ third_party_settings: parent_name: group_tabs weight: 6 format_type: tab - region: hidden + region: content format_settings: id: '' classes: '' @@ -86,7 +86,7 @@ third_party_settings: parent_name: group_tabs weight: 8 format_type: tab - region: hidden + region: content format_settings: id: '' classes: '' @@ -102,7 +102,7 @@ third_party_settings: parent_name: group_tabs weight: 7 format_type: tab - region: hidden + region: content format_settings: id: '' classes: '' @@ -113,12 +113,12 @@ third_party_settings: group_reference: children: - field_titre - - field_autheurs - field_edition + - field_auteurs parent_name: group_tabs weight: 20 format_type: tab - region: hidden + region: content format_settings: id: '' classes: '' @@ -165,8 +165,8 @@ content: region: content settings: { } third_party_settings: { } - field_autheurs: - weight: 4 + field_auteurs: + weight: 27 settings: match_operator: CONTAINS match_limit: 10 diff --git a/src/config/sync/core.entity_form_display.node.texte_prod.default.yml b/src/config/sync/core.entity_form_display.node.texte_prod.default.yml index 67143ad..6750b44 100644 --- a/src/config/sync/core.entity_form_display.node.texte_prod.default.yml +++ b/src/config/sync/core.entity_form_display.node.texte_prod.default.yml @@ -4,7 +4,7 @@ status: true dependencies: config: - field.field.node.texte_prod.body - - field.field.node.texte_prod.field_autheurs + - field.field.node.texte_prod.field_auteurs - field.field.node.texte_prod.field_date - field.field.node.texte_prod.field_famille - field.field.node.texte_prod.field_fichier @@ -37,7 +37,7 @@ third_party_settings: parent_name: '' weight: 6 format_type: tabs - region: hidden + region: content format_settings: id: '' classes: '' @@ -52,7 +52,7 @@ third_party_settings: parent_name: group_tabs weight: 20 format_type: tab - region: hidden + region: content format_settings: description: '' formatter: open @@ -68,7 +68,7 @@ third_party_settings: parent_name: group_tabs weight: 23 format_type: tab - region: hidden + region: content format_settings: id: '' classes: '' @@ -78,12 +78,12 @@ third_party_settings: label: Media group_reference: children: - - field_autheurs - field_date + - field_auteurs parent_name: group_tabs weight: 24 format_type: tab - region: hidden + region: content format_settings: id: '' classes: '' @@ -97,7 +97,7 @@ third_party_settings: parent_name: group_tabs weight: 22 format_type: tab - region: hidden + region: content format_settings: id: '' classes: '' @@ -112,7 +112,7 @@ third_party_settings: parent_name: group_tabs weight: 21 format_type: tab - region: hidden + region: content format_settings: id: '' classes: '' @@ -158,8 +158,8 @@ content: region: content settings: { } third_party_settings: { } - field_autheurs: - weight: 127 + field_auteurs: + weight: 131 settings: match_operator: CONTAINS match_limit: 10 diff --git a/src/config/sync/core.entity_form_display.taxonomy_term.auteurs.default.yml b/src/config/sync/core.entity_form_display.taxonomy_term.auteurs.default.yml new file mode 100644 index 0000000..50ed440 --- /dev/null +++ b/src/config/sync/core.entity_form_display.taxonomy_term.auteurs.default.yml @@ -0,0 +1,68 @@ +uuid: 50f048df-4329-4c61-bc7a-13f4b7d68326 +langcode: fr +status: true +dependencies: + config: + - field.field.taxonomy_term.auteurs.field_nom + - field.field.taxonomy_term.auteurs.field_prenom + - taxonomy.vocabulary.auteurs + module: + - field_group + - text +third_party_settings: + field_group: + group_details: + children: + - status + parent_name: '' + weight: 3 + format_type: details_sidebar + region: content + format_settings: + id: '' + classes: '' + description: '' + open: false + required_fields: true + weight: 0 + label: details +id: taxonomy_term.auteurs.default +targetEntityType: taxonomy_term +bundle: auteurs +mode: default +content: + description: + type: text_textarea + weight: 2 + region: content + settings: + placeholder: '' + rows: 5 + third_party_settings: { } + field_nom: + weight: 0 + settings: + size: 60 + placeholder: '' + third_party_settings: { } + type: string_textfield + region: content + field_prenom: + weight: 1 + settings: + size: 60 + placeholder: '' + third_party_settings: { } + type: string_textfield + region: content + status: + type: boolean_checkbox + settings: + display_label: true + weight: 6 + region: content + third_party_settings: { } +hidden: + langcode: true + name: true + path: true diff --git a/src/config/sync/core.entity_view_display.node.creation.default.yml b/src/config/sync/core.entity_view_display.node.creation.default.yml index 0755b3a..6bd00d0 100644 --- a/src/config/sync/core.entity_view_display.node.creation.default.yml +++ b/src/config/sync/core.entity_view_display.node.creation.default.yml @@ -4,7 +4,7 @@ status: true dependencies: config: - field.field.node.creation.body - - field.field.node.creation.field_autheurs + - field.field.node.creation.field_auteurs - field.field.node.creation.field_oeuvre - node.type.creation module: @@ -23,8 +23,8 @@ content: settings: { } third_party_settings: { } region: content - field_autheurs: - weight: 102 + field_auteurs: + weight: 104 label: above settings: link: true diff --git a/src/config/sync/core.entity_view_display.node.creation.teaser.yml b/src/config/sync/core.entity_view_display.node.creation.teaser.yml index 9a36ec8..c0b68b0 100644 --- a/src/config/sync/core.entity_view_display.node.creation.teaser.yml +++ b/src/config/sync/core.entity_view_display.node.creation.teaser.yml @@ -5,7 +5,7 @@ dependencies: config: - core.entity_view_mode.node.teaser - field.field.node.creation.body - - field.field.node.creation.field_autheurs + - field.field.node.creation.field_auteurs - field.field.node.creation.field_oeuvre - node.type.creation module: @@ -30,7 +30,7 @@ content: third_party_settings: { } region: content hidden: - field_autheurs: true + field_auteurs: true field_oeuvre: true langcode: true search_api_excerpt: true diff --git a/src/config/sync/core.entity_view_display.node.texte.default.yml b/src/config/sync/core.entity_view_display.node.texte.default.yml index da32803..d1dabb0 100644 --- a/src/config/sync/core.entity_view_display.node.texte.default.yml +++ b/src/config/sync/core.entity_view_display.node.texte.default.yml @@ -4,7 +4,7 @@ status: true dependencies: config: - field.field.node.texte.body - - field.field.node.texte.field_autheurs + - field.field.node.texte.field_auteurs - field.field.node.texte.field_degres_detrangement - field.field.node.texte.field_edition - field.field.node.texte.field_famille @@ -38,8 +38,8 @@ content: settings: { } third_party_settings: { } region: content - field_autheurs: - weight: 102 + field_auteurs: + weight: 118 label: above settings: link: true diff --git a/src/config/sync/core.entity_view_display.node.texte.teaser.yml b/src/config/sync/core.entity_view_display.node.texte.teaser.yml index 6b4b329..7011e1c 100644 --- a/src/config/sync/core.entity_view_display.node.texte.teaser.yml +++ b/src/config/sync/core.entity_view_display.node.texte.teaser.yml @@ -5,7 +5,7 @@ dependencies: config: - core.entity_view_mode.node.teaser - field.field.node.texte.body - - field.field.node.texte.field_autheurs + - field.field.node.texte.field_auteurs - field.field.node.texte.field_degres_detrangement - field.field.node.texte.field_edition - field.field.node.texte.field_famille @@ -41,7 +41,7 @@ content: third_party_settings: { } region: content hidden: - field_autheurs: true + field_auteurs: true field_degres_detrangement: true field_edition: true field_famille: true diff --git a/src/config/sync/core.entity_view_display.node.texte_prod.default.yml b/src/config/sync/core.entity_view_display.node.texte_prod.default.yml index 11a0e60..c3e9170 100644 --- a/src/config/sync/core.entity_view_display.node.texte_prod.default.yml +++ b/src/config/sync/core.entity_view_display.node.texte_prod.default.yml @@ -4,7 +4,7 @@ status: true dependencies: config: - field.field.node.texte_prod.body - - field.field.node.texte_prod.field_autheurs + - field.field.node.texte_prod.field_auteurs - field.field.node.texte_prod.field_date - field.field.node.texte_prod.field_famille - field.field.node.texte_prod.field_fichier @@ -34,8 +34,8 @@ content: settings: { } third_party_settings: { } region: content - field_autheurs: - weight: 108 + field_auteurs: + weight: 111 label: above settings: link: true diff --git a/src/config/sync/core.entity_view_display.node.texte_prod.teaser.yml b/src/config/sync/core.entity_view_display.node.texte_prod.teaser.yml index 45c5614..2e7d0ae 100644 --- a/src/config/sync/core.entity_view_display.node.texte_prod.teaser.yml +++ b/src/config/sync/core.entity_view_display.node.texte_prod.teaser.yml @@ -5,7 +5,7 @@ dependencies: config: - core.entity_view_mode.node.teaser - field.field.node.texte_prod.body - - field.field.node.texte_prod.field_autheurs + - field.field.node.texte_prod.field_auteurs - field.field.node.texte_prod.field_date - field.field.node.texte_prod.field_famille - field.field.node.texte_prod.field_fichier @@ -37,7 +37,7 @@ content: third_party_settings: { } region: content hidden: - field_autheurs: true + field_auteurs: true field_date: true field_famille: true field_fichier: true diff --git a/src/config/sync/core.entity_view_display.taxonomy_term.auteurs.default.yml b/src/config/sync/core.entity_view_display.taxonomy_term.auteurs.default.yml new file mode 100644 index 0000000..38a81ce --- /dev/null +++ b/src/config/sync/core.entity_view_display.taxonomy_term.auteurs.default.yml @@ -0,0 +1,41 @@ +uuid: aa0e70f9-09d7-486f-bcc1-c93d11708066 +langcode: fr +status: true +dependencies: + config: + - field.field.taxonomy_term.auteurs.field_nom + - field.field.taxonomy_term.auteurs.field_prenom + - taxonomy.vocabulary.auteurs + module: + - text +id: taxonomy_term.auteurs.default +targetEntityType: taxonomy_term +bundle: auteurs +mode: default +content: + description: + label: hidden + type: text_default + weight: 0 + region: content + settings: { } + third_party_settings: { } + field_nom: + weight: 1 + label: above + settings: + link_to_entity: false + third_party_settings: { } + type: string + region: content + field_prenom: + weight: 2 + label: above + settings: + link_to_entity: false + third_party_settings: { } + type: string + region: content +hidden: + langcode: true + search_api_excerpt: true diff --git a/src/config/sync/core.extension.yml b/src/config/sync/core.extension.yml index 3c56cf0..5527d6f 100644 --- a/src/config/sync/core.extension.yml +++ b/src/config/sync/core.extension.yml @@ -4,6 +4,7 @@ module: admin_toolbar_links_access_filter: 0 advanced_text_formatter: 0 audiofield: 0 + auto_entitylabel: 0 autocomplete_deluxe: 0 autologout: 0 ban: 0 diff --git a/src/config/sync/field.field.node.creation.field_autheurs.yml b/src/config/sync/field.field.node.creation.field_auteurs.yml similarity index 71% rename from src/config/sync/field.field.node.creation.field_autheurs.yml rename to src/config/sync/field.field.node.creation.field_auteurs.yml index 9b3ca0c..0796871 100644 --- a/src/config/sync/field.field.node.creation.field_autheurs.yml +++ b/src/config/sync/field.field.node.creation.field_auteurs.yml @@ -1,16 +1,16 @@ -uuid: 1e9955e5-f8a7-454f-83d9-01abda610c48 +uuid: c90fbb66-7f1b-4022-934d-fdc1c655827f langcode: fr status: true dependencies: config: - - field.storage.node.field_autheurs + - field.storage.node.field_auteurs - node.type.creation - taxonomy.vocabulary.auteurs -id: node.creation.field_autheurs -field_name: field_autheurs +id: node.creation.field_auteurs +field_name: field_auteurs entity_type: node bundle: creation -label: Autheur(s) +label: Auteur(s) description: '' required: false translatable: true @@ -24,6 +24,6 @@ settings: sort: field: name direction: asc - auto_create: true + auto_create: false auto_create_bundle: '' field_type: entity_reference diff --git a/src/config/sync/field.field.node.texte.field_autheurs.yml b/src/config/sync/field.field.node.texte.field_auteurs.yml similarity index 68% rename from src/config/sync/field.field.node.texte.field_autheurs.yml rename to src/config/sync/field.field.node.texte.field_auteurs.yml index f212208..950d4fa 100644 --- a/src/config/sync/field.field.node.texte.field_autheurs.yml +++ b/src/config/sync/field.field.node.texte.field_auteurs.yml @@ -1,19 +1,19 @@ -uuid: 0bf151e0-6037-4add-9cc6-95bd9ac17b57 +uuid: bd7eadbd-b0b9-4931-b254-b8b91d06df0b langcode: fr status: true dependencies: config: - - field.storage.node.field_autheurs + - field.storage.node.field_auteurs - node.type.texte - taxonomy.vocabulary.auteurs -id: node.texte.field_autheurs -field_name: field_autheurs +id: node.texte.field_auteurs +field_name: field_auteurs entity_type: node bundle: texte -label: Autheur(s) +label: Auteur(s) description: '' required: false -translatable: false +translatable: true default_value: { } default_value_callback: '' settings: @@ -24,6 +24,6 @@ settings: sort: field: name direction: asc - auto_create: true + auto_create: false auto_create_bundle: '' field_type: entity_reference diff --git a/src/config/sync/field.field.node.texte_prod.field_autheurs.yml b/src/config/sync/field.field.node.texte_prod.field_auteurs.yml similarity index 71% rename from src/config/sync/field.field.node.texte_prod.field_autheurs.yml rename to src/config/sync/field.field.node.texte_prod.field_auteurs.yml index 9bfb905..16bec2d 100644 --- a/src/config/sync/field.field.node.texte_prod.field_autheurs.yml +++ b/src/config/sync/field.field.node.texte_prod.field_auteurs.yml @@ -1,19 +1,19 @@ -uuid: 09f73dae-1547-4e53-adb8-16f12a503a3f +uuid: 61ce3ac9-21ed-4be6-b4b2-a26770dfb656 langcode: fr status: true dependencies: config: - - field.storage.node.field_autheurs + - field.storage.node.field_auteurs - node.type.texte_prod - taxonomy.vocabulary.auteurs -id: node.texte_prod.field_autheurs -field_name: field_autheurs +id: node.texte_prod.field_auteurs +field_name: field_auteurs entity_type: node bundle: texte_prod -label: Autheur(s) +label: Auteur(s) description: '' required: false -translatable: true +translatable: false default_value: { } default_value_callback: '' settings: diff --git a/src/config/sync/field.field.taxonomy_term.auteurs.field_nom.yml b/src/config/sync/field.field.taxonomy_term.auteurs.field_nom.yml new file mode 100644 index 0000000..9f0575a --- /dev/null +++ b/src/config/sync/field.field.taxonomy_term.auteurs.field_nom.yml @@ -0,0 +1,19 @@ +uuid: 5489232f-0767-4083-b519-decf935158a0 +langcode: fr +status: true +dependencies: + config: + - field.storage.taxonomy_term.field_nom + - taxonomy.vocabulary.auteurs +id: taxonomy_term.auteurs.field_nom +field_name: field_nom +entity_type: taxonomy_term +bundle: auteurs +label: Nom +description: '' +required: false +translatable: false +default_value: { } +default_value_callback: '' +settings: { } +field_type: string diff --git a/src/config/sync/field.field.taxonomy_term.auteurs.field_prenom.yml b/src/config/sync/field.field.taxonomy_term.auteurs.field_prenom.yml new file mode 100644 index 0000000..6cd6387 --- /dev/null +++ b/src/config/sync/field.field.taxonomy_term.auteurs.field_prenom.yml @@ -0,0 +1,19 @@ +uuid: b0c7e722-cadc-4f28-b3c2-164bccd527fc +langcode: fr +status: true +dependencies: + config: + - field.storage.taxonomy_term.field_prenom + - taxonomy.vocabulary.auteurs +id: taxonomy_term.auteurs.field_prenom +field_name: field_prenom +entity_type: taxonomy_term +bundle: auteurs +label: Prenom +description: '' +required: false +translatable: false +default_value: { } +default_value_callback: '' +settings: { } +field_type: string diff --git a/src/config/sync/field.storage.node.field_autheurs.yml b/src/config/sync/field.storage.node.field_auteurs.yml similarity index 75% rename from src/config/sync/field.storage.node.field_autheurs.yml rename to src/config/sync/field.storage.node.field_auteurs.yml index 20b7dd3..8490a9c 100644 --- a/src/config/sync/field.storage.node.field_autheurs.yml +++ b/src/config/sync/field.storage.node.field_auteurs.yml @@ -1,12 +1,12 @@ -uuid: 08e3d30f-fbb9-4327-9a0b-4f6d9a52a736 +uuid: bce7da6c-5e27-40e3-9216-2d475f5a7b1f langcode: fr status: true dependencies: module: - node - taxonomy -id: node.field_autheurs -field_name: field_autheurs +id: node.field_auteurs +field_name: field_auteurs entity_type: node type: entity_reference settings: diff --git a/src/config/sync/field.storage.taxonomy_term.field_nom.yml b/src/config/sync/field.storage.taxonomy_term.field_nom.yml new file mode 100644 index 0000000..b23cb10 --- /dev/null +++ b/src/config/sync/field.storage.taxonomy_term.field_nom.yml @@ -0,0 +1,21 @@ +uuid: b74ab870-5742-4fc2-a016-722a25f7faf4 +langcode: fr +status: true +dependencies: + module: + - taxonomy +id: taxonomy_term.field_nom +field_name: field_nom +entity_type: taxonomy_term +type: string +settings: + max_length: 255 + is_ascii: false + case_sensitive: false +module: core +locked: false +cardinality: 1 +translatable: true +indexes: { } +persist_with_no_fields: false +custom_storage: false diff --git a/src/config/sync/field.storage.taxonomy_term.field_prenom.yml b/src/config/sync/field.storage.taxonomy_term.field_prenom.yml new file mode 100644 index 0000000..b01b949 --- /dev/null +++ b/src/config/sync/field.storage.taxonomy_term.field_prenom.yml @@ -0,0 +1,21 @@ +uuid: 83eb9a26-c875-4e5d-bc4e-b4068374ff8f +langcode: fr +status: true +dependencies: + module: + - taxonomy +id: taxonomy_term.field_prenom +field_name: field_prenom +entity_type: taxonomy_term +type: string +settings: + max_length: 255 + is_ascii: false + case_sensitive: false +module: core +locked: false +cardinality: 1 +translatable: true +indexes: { } +persist_with_no_fields: false +custom_storage: false diff --git a/src/config/sync/seven.settings.yml b/src/config/sync/seven.settings.yml new file mode 100644 index 0000000..ae59daa --- /dev/null +++ b/src/config/sync/seven.settings.yml @@ -0,0 +1,10 @@ +features: + node_user_picture: false + comment_user_picture: true + comment_user_verification: true + favicon: false +logo: + use_default: false + path: '' +favicon: + use_default: true diff --git a/src/config/sync/views.view.admin_taxo.yml b/src/config/sync/views.view.admin_taxo.yml new file mode 100644 index 0000000..f6eaec8 --- /dev/null +++ b/src/config/sync/views.view.admin_taxo.yml @@ -0,0 +1,631 @@ +uuid: 54d387f0-a1b6-456f-883b-624a8697cf25 +langcode: fr +status: true +dependencies: + module: + - taxonomy + - text + - user + - views_bulk_operations +id: admin_taxo +label: 'admin taxo' +module: views +description: '' +tag: '' +base_table: taxonomy_term_field_data +base_field: tid +display: + default: + display_plugin: default + id: default + display_title: Master + position: 0 + display_options: + access: + type: perm + options: + perm: 'view the administration theme' + cache: + type: tag + options: { } + query: + type: views_query + options: + disable_sql_rewrite: false + distinct: false + replica: false + query_comment: '' + query_tags: { } + exposed_form: + type: basic + options: + submit_button: Appliquer + reset_button: false + reset_button_label: Réinitialiser + exposed_sorts_label: 'Trier par' + expose_sort_order: true + sort_asc_label: Asc + sort_desc_label: Desc + pager: + type: mini + options: + items_per_page: 25 + offset: 0 + id: 0 + total_pages: null + expose: + items_per_page: false + items_per_page_label: 'Éléments par page' + items_per_page_options: '5, 10, 25, 50' + items_per_page_options_all: false + items_per_page_options_all_label: '- Tout -' + offset: false + offset_label: Décalage + tags: + previous: ‹‹ + next: ›› + style: + type: table + options: + grouping: { } + row_class: '' + default_row_class: true + override: true + sticky: true + caption: '' + summary: '' + description: '' + columns: + views_bulk_operations_bulk_form: views_bulk_operations_bulk_form + tid: name + name: name + operations: name + description__value: description__value + status: status + changed: changed + info: + views_bulk_operations_bulk_form: + align: '' + separator: '' + empty_column: false + responsive: '' + tid: + sortable: true + default_sort_order: asc + align: '' + separator: '' + empty_column: false + responsive: '' + name: + sortable: true + default_sort_order: asc + align: '' + separator: '
' + empty_column: false + responsive: '' + operations: + align: '' + separator: '' + empty_column: false + responsive: '' + description__value: + align: '' + separator: '' + empty_column: false + responsive: '' + status: + sortable: false + default_sort_order: asc + align: '' + separator: '' + empty_column: false + responsive: '' + changed: + sortable: true + default_sort_order: desc + align: '' + separator: '' + empty_column: false + responsive: '' + default: changed + empty_table: false + row: + type: fields + fields: + views_bulk_operations_bulk_form: + id: views_bulk_operations_bulk_form + table: views + field: views_bulk_operations_bulk_form + relationship: none + group_type: group + admin_label: '' + label: 'Views bulk operations' + exclude: false + alter: + alter_text: false + text: '' + make_link: false + path: '' + absolute: false + external: false + replace_spaces: false + path_case: none + trim_whitespace: false + alt: '' + rel: '' + link_class: '' + prefix: '' + suffix: '' + target: '' + nl2br: false + max_length: 0 + word_boundary: true + ellipsis: true + more_link: false + more_link_text: '' + more_link_path: '' + strip_tags: false + trim: false + preserve_tags: '' + html: false + element_type: '' + element_class: '' + element_label_type: '' + element_label_class: '' + element_label_colon: true + element_wrapper_type: '' + element_wrapper_class: '' + element_default_classes: true + empty: '' + hide_empty: false + empty_zero: false + hide_alter_empty: true + batch: true + batch_size: 10 + form_step: true + buttons: false + clear_on_exposed: true + action_title: Action + selected_actions: + 0: + action_id: 'entity:break_lock:taxonomy_term' + 4: + action_id: 'entity:publish_action:taxonomy_term' + 6: + action_id: 'entity:unpublish_action:taxonomy_term' + plugin_id: views_bulk_operations_bulk_form + tid: + id: tid + table: taxonomy_term_field_data + field: tid + relationship: none + group_type: group + admin_label: '' + label: 'Identifiant (ID) du terme' + exclude: false + alter: + alter_text: false + text: '' + make_link: false + path: '' + absolute: false + external: false + replace_spaces: false + path_case: none + trim_whitespace: false + alt: '' + rel: '' + link_class: '' + prefix: '' + suffix: '' + target: '' + nl2br: false + max_length: 0 + word_boundary: true + ellipsis: true + more_link: false + more_link_text: '' + more_link_path: '' + strip_tags: false + trim: false + preserve_tags: '' + html: false + element_type: '' + element_class: '' + element_label_type: '' + element_label_class: '' + element_label_colon: true + element_wrapper_type: '' + element_wrapper_class: '' + element_default_classes: true + empty: '' + hide_empty: false + empty_zero: false + hide_alter_empty: true + click_sort_column: value + type: number_integer + settings: + thousand_separator: '' + prefix_suffix: true + group_column: value + group_columns: { } + group_rows: true + delta_limit: 0 + delta_offset: 0 + delta_reversed: false + delta_first_last: false + multi_type: separator + separator: ', ' + field_api_classes: false + entity_type: taxonomy_term + entity_field: tid + plugin_id: field + name: + id: name + table: taxonomy_term_field_data + field: name + relationship: none + group_type: group + admin_label: '' + label: nom + exclude: false + alter: + alter_text: false + text: '' + make_link: false + path: '' + absolute: false + external: false + replace_spaces: false + path_case: none + trim_whitespace: false + alt: '' + rel: '' + link_class: '' + prefix: '' + suffix: '' + target: '' + nl2br: false + max_length: 0 + word_boundary: false + ellipsis: false + more_link: false + more_link_text: '' + more_link_path: '' + strip_tags: false + trim: false + preserve_tags: '' + html: false + element_type: '' + element_class: '' + element_label_type: '' + element_label_class: '' + element_label_colon: true + element_wrapper_type: '' + element_wrapper_class: '' + element_default_classes: true + empty: '' + hide_empty: false + empty_zero: false + hide_alter_empty: true + click_sort_column: value + type: string + settings: + link_to_entity: true + group_column: value + group_columns: { } + group_rows: true + delta_limit: 0 + delta_offset: 0 + delta_reversed: false + delta_first_last: false + multi_type: separator + separator: ', ' + field_api_classes: false + convert_spaces: false + entity_type: taxonomy_term + entity_field: name + plugin_id: term_name + operations: + id: operations + table: taxonomy_term_data + field: operations + relationship: none + group_type: group + admin_label: '' + label: '' + exclude: false + alter: + alter_text: false + text: '' + make_link: false + path: '' + absolute: false + external: false + replace_spaces: false + path_case: none + trim_whitespace: false + alt: '' + rel: '' + link_class: '' + prefix: '' + suffix: '' + target: '' + nl2br: false + max_length: 0 + word_boundary: true + ellipsis: true + more_link: false + more_link_text: '' + more_link_path: '' + strip_tags: false + trim: false + preserve_tags: '' + html: false + element_type: '' + element_class: '' + element_label_type: '' + element_label_class: '' + element_label_colon: false + element_wrapper_type: '' + element_wrapper_class: '' + element_default_classes: true + empty: '' + hide_empty: false + empty_zero: false + hide_alter_empty: true + destination: false + entity_type: taxonomy_term + plugin_id: entity_operations + description__value: + id: description__value + table: taxonomy_term_field_data + field: description__value + relationship: none + group_type: group + admin_label: '' + label: description + exclude: false + alter: + alter_text: false + text: '' + make_link: false + path: '' + absolute: false + external: false + replace_spaces: false + path_case: none + trim_whitespace: false + alt: '' + rel: '' + link_class: '' + prefix: '' + suffix: '' + target: '' + nl2br: false + max_length: 0 + word_boundary: true + ellipsis: true + more_link: false + more_link_text: '' + more_link_path: '' + strip_tags: false + trim: false + preserve_tags: '' + html: false + element_type: '' + element_class: '' + element_label_type: '' + element_label_class: '' + element_label_colon: false + element_wrapper_type: '' + element_wrapper_class: '' + element_default_classes: true + empty: '' + hide_empty: false + empty_zero: false + hide_alter_empty: true + click_sort_column: value + type: text_default + settings: { } + group_column: value + group_columns: { } + group_rows: true + delta_limit: 0 + delta_offset: 0 + delta_reversed: false + delta_first_last: false + multi_type: separator + separator: ', ' + field_api_classes: false + entity_type: taxonomy_term + entity_field: description + plugin_id: field + status: + id: status + table: taxonomy_term_field_data + field: status + relationship: none + group_type: group + admin_label: '' + label: Publié + exclude: false + alter: + alter_text: false + text: '' + make_link: false + path: '' + absolute: false + external: false + replace_spaces: false + path_case: none + trim_whitespace: false + alt: '' + rel: '' + link_class: '' + prefix: '' + suffix: '' + target: '' + nl2br: false + max_length: 0 + word_boundary: true + ellipsis: true + more_link: false + more_link_text: '' + more_link_path: '' + strip_tags: false + trim: false + preserve_tags: '' + html: false + element_type: '' + element_class: '' + element_label_type: '' + element_label_class: '' + element_label_colon: true + element_wrapper_type: '' + element_wrapper_class: '' + element_default_classes: true + empty: '' + hide_empty: false + empty_zero: false + hide_alter_empty: true + click_sort_column: value + type: boolean + settings: + format: unicode-yes-no + format_custom_true: '' + format_custom_false: '' + group_column: value + group_columns: { } + group_rows: true + delta_limit: 0 + delta_offset: 0 + delta_reversed: false + delta_first_last: false + multi_type: separator + separator: ', ' + field_api_classes: false + entity_type: taxonomy_term + entity_field: status + plugin_id: field + changed: + id: changed + table: taxonomy_term_field_data + field: changed + relationship: none + group_type: group + admin_label: '' + label: 'Date de mise à jour' + exclude: false + alter: + alter_text: false + text: '' + make_link: false + path: '' + absolute: false + external: false + replace_spaces: false + path_case: none + trim_whitespace: false + alt: '' + rel: '' + link_class: '' + prefix: '' + suffix: '' + target: '' + nl2br: false + max_length: 0 + word_boundary: true + ellipsis: true + more_link: false + more_link_text: '' + more_link_path: '' + strip_tags: false + trim: false + preserve_tags: '' + html: false + element_type: '' + element_class: '' + element_label_type: '' + element_label_class: '' + element_label_colon: true + element_wrapper_type: '' + element_wrapper_class: '' + element_default_classes: true + empty: '' + hide_empty: false + empty_zero: false + hide_alter_empty: true + click_sort_column: value + type: timestamp + settings: + date_format: html_date + custom_date_format: '' + timezone: '' + group_column: value + group_columns: { } + group_rows: true + delta_limit: 0 + delta_offset: 0 + delta_reversed: false + delta_first_last: false + multi_type: separator + separator: ', ' + field_api_classes: false + entity_type: taxonomy_term + entity_field: changed + plugin_id: field + filters: { } + sorts: { } + title: 'admin taxo auteurs' + header: + result: + id: result + table: views + field: result + relationship: none + group_type: group + admin_label: '' + empty: false + content: 'Affichage de @start à @end sur @total' + plugin_id: result + footer: { } + empty: { } + relationships: { } + arguments: { } + display_extenders: { } + cache_metadata: + max-age: 0 + contexts: + - 'languages:language_content' + - 'languages:language_interface' + - url.query_args + - user.permissions + tags: { } + page_1: + display_plugin: page + id: page_1 + display_title: Auteurs + position: 1 + display_options: + display_extenders: + views_ef_fieldset: { } + path: admin/content/auteurs + menu: + type: tab + title: Auteurs + description: '' + expanded: false + parent: system.admin_content + weight: 0 + context: '1' + menu_name: admin + display_description: '' + cache_metadata: + max-age: 0 + contexts: + - 'languages:language_content' + - 'languages:language_interface' + - url.query_args + - user.permissions + tags: { } diff --git a/src/web/modules/custom/enfrancais_graphql/graphql/enfr_extension.base.graphqls b/src/web/modules/custom/enfrancais_graphql/graphql/enfr_extension.base.graphqls index d840fb2..9d5a049 100644 --- a/src/web/modules/custom/enfrancais_graphql/graphql/enfr_extension.base.graphqls +++ b/src/web/modules/custom/enfrancais_graphql/graphql/enfr_extension.base.graphqls @@ -18,7 +18,7 @@ interface TextInterface { fichiers: [File] familles: [Taxoterm] field_titre: String - auteurs: [Taxoterm] + auteurs: [Auteur] edition: Taxoterm } @@ -35,7 +35,7 @@ type Textref implements NodeInterface & TextInterface{ fichiers: [File] familles: [Taxoterm] field_titre: String - auteurs: [Taxoterm] + auteurs: [Auteur] edition: Taxoterm # text_produits: [Textprod] @@ -58,7 +58,7 @@ type Textprod implements NodeInterface & TextInterface { fichiers: [File] familles: [Taxoterm] field_titre: String - auteurs: [Taxoterm] + auteurs: [Auteur] edition: Taxoterm # text_de_depart: [Textref] @@ -74,7 +74,7 @@ type Creation implements NodeInterface { path: String! author: String texte: String - auteurs: [Taxoterm] + auteurs: [Auteur] oeuvre: Link } @@ -116,6 +116,14 @@ type Taxoterm { name: String! } +type Auteur { + id: Int! + uuid: String! + name: String! + first_name: String + last_name: String +} + type VideoLink { url: String } diff --git a/src/web/modules/custom/enfrancais_graphql/graphql/enfr_extension.extension.graphqls b/src/web/modules/custom/enfrancais_graphql/graphql/enfr_extension.extension.graphqls index 34209bb..9a22f0f 100644 --- a/src/web/modules/custom/enfrancais_graphql/graphql/enfr_extension.extension.graphqls +++ b/src/web/modules/custom/enfrancais_graphql/graphql/enfr_extension.extension.graphqls @@ -53,3 +53,11 @@ extend type Query { extend type Query { tagprod(id: Int!): Taxoterm } + +extend type Query { + auteur(id: Int!): Auteur +} + +extend type Query { + allauteurs: [Auteur] +} diff --git a/src/web/modules/custom/enfrancais_graphql/src/Plugin/GraphQL/SchemaExtension/EnFrSchemaExtension.php b/src/web/modules/custom/enfrancais_graphql/src/Plugin/GraphQL/SchemaExtension/EnFrSchemaExtension.php index 95e7c51..5a37bf4 100644 --- a/src/web/modules/custom/enfrancais_graphql/src/Plugin/GraphQL/SchemaExtension/EnFrSchemaExtension.php +++ b/src/web/modules/custom/enfrancais_graphql/src/Plugin/GraphQL/SchemaExtension/EnFrSchemaExtension.php @@ -55,6 +55,8 @@ class EnFrSchemaExtension extends SdlSchemaExtensionPluginBase { // $this->addTaxoterm($registry, $builder); // + $this->addAuteur($registry, $builder); + // // $this->addNote($registry, $builder); // // $this->addSearchResult($registry, $builder); @@ -306,7 +308,7 @@ class EnFrSchemaExtension extends SdlSchemaExtensionPluginBase { $registry->addFieldResolver('Textref', 'auteurs', $builder->produce('entity_reference') ->map('entity', $builder->fromParent()) - ->map('field', $builder->fromValue('field_autheurs')) + ->map('field', $builder->fromValue('field_auteurs')) ); $registry->addFieldResolver('Textref', 'edition', @@ -437,7 +439,7 @@ class EnFrSchemaExtension extends SdlSchemaExtensionPluginBase { $registry->addFieldResolver('Textprod', 'auteurs', $builder->produce('entity_reference') ->map('entity', $builder->fromParent()) - ->map('field', $builder->fromValue('field_autheurs')) + ->map('field', $builder->fromValue('field_auteurs')) ); $registry->addFieldResolver('Textprod', 'edition', @@ -582,7 +584,7 @@ class EnFrSchemaExtension extends SdlSchemaExtensionPluginBase { $registry->addFieldResolver('Creation', 'auteurs', $builder->produce('entity_reference') ->map('entity', $builder->fromParent()) - ->map('field', $builder->fromValue('field_autheurs')) + ->map('field', $builder->fromValue('field_auteurs')) ); $registry->addFieldResolver('Creation', 'oeuvre', @@ -848,5 +850,59 @@ class EnFrSchemaExtension extends SdlSchemaExtensionPluginBase { ); } + protected function addAuteur(ResolverRegistryInterface $registry, ResolverBuilder $builder) { + $registry->addFieldResolver('Query', 'allauteurs', + $builder->compose( + $builder->callback(function($parent, $arg){ + $entity_storage = \Drupal::entityTypeManager()->getStorage('taxonomy_term'); + $query = $entity_storage->getQuery() + ->condition('vid', 'auteurs') + ->accessCheck(TRUE); + $results = $query->execute(); + return $results; + }), + $builder->produce('entity_load_multiple') + ->map('type', $builder->fromValue('taxonomy_term')) + ->map('ids', $builder->fromParent()) + ) + ); + + $registry->addFieldResolver('Query', 'auteur', + $builder->produce('entity_load') + ->map('type', $builder->fromValue('taxonomy_term')) + ->map('bundles', $builder->fromValue(['auteurs'])) + ->map('id', $builder->fromArgument('id')) + ); + + $registry->addFieldResolver('Auteur', 'id', + $builder->produce('entity_id') + ->map('entity', $builder->fromParent()) + ); + + $registry->addFieldResolver('Auteur', 'uuid', + $builder->produce('entity_uuid') + ->map('entity', $builder->fromParent()) + ); + + $registry->addFieldResolver('Auteur', 'name', + $builder->produce('entity_label') + ->map('entity', $builder->fromParent()) + ); + + $registry->addFieldResolver('Auteur', 'first_name', + $builder->produce('property_path') + ->map('type', $builder->fromValue('entity:taxonomy_term')) + ->map('value', $builder->fromParent()) + ->map('path', $builder->fromValue('field_prenom.value')) + ); + + $registry->addFieldResolver('Auteur', 'last_name', + $builder->produce('property_path') + ->map('type', $builder->fromValue('entity:taxonomy_term')) + ->map('value', $builder->fromParent()) + ->map('path', $builder->fromValue('field_nom.value')) + ); + + } }