continue to build frontpage

This commit is contained in:
Bachir Soussi Chiadmi 2019-05-24 13:07:50 +02:00
parent 72dca11b5e
commit c8829ee539
75 changed files with 613 additions and 110 deletions

View File

@ -35,6 +35,7 @@
"drupal/entity_clone": "^1.0", "drupal/entity_clone": "^1.0",
"drupal/error_log": "^1.0", "drupal/error_log": "^1.0",
"drupal/genpass": "1.x-dev", "drupal/genpass": "1.x-dev",
"drupal/image_delta_formatter": "1.x-dev",
"drupal/login_history": "1.x-dev", "drupal/login_history": "1.x-dev",
"drupal/mailgun": "1.x-dev", "drupal/mailgun": "1.x-dev",
"drupal/mailsystem": "^4.1", "drupal/mailsystem": "^4.1",

57
composer.lock generated
View File

@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically" "This file is @generated automatically"
], ],
"content-hash": "b8885355b53124506546f75d8e3d43c8", "content-hash": "fdf4dd3a621ca2c7754d1fc8ee5ee311",
"packages": [ "packages": [
{ {
"name": "alchemy/zippy", "name": "alchemy/zippy",
@ -6363,6 +6363,60 @@
"source": "https://git.drupalcode.org/project/honeypot" "source": "https://git.drupalcode.org/project/honeypot"
} }
}, },
{
"name": "drupal/image_delta_formatter",
"version": "dev-1.x",
"source": {
"type": "git",
"url": "https://git.drupalcode.org/project/image_delta_formatter.git",
"reference": "1c6eefadabe83faa6d28d35de6e41e793f393ec0"
},
"require": {
"drupal/core": "*"
},
"type": "drupal-module",
"extra": {
"branch-alias": {
"dev-1.x": "1.x-dev"
},
"drupal": {
"version": "8.x-1.0+0-dev",
"datestamp": "1521667080",
"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": "bojanz",
"homepage": "https://www.drupal.org/user/86106"
},
{
"name": "fgm",
"homepage": "https://www.drupal.org/user/27985"
},
{
"name": "jsacksick",
"homepage": "https://www.drupal.org/user/972218"
},
{
"name": "mglaman",
"homepage": "https://www.drupal.org/user/2416470"
}
],
"description": "Provides a formatter that displays a specific delta of a multivalue imagefield.",
"homepage": "https://www.drupal.org/project/image_delta_formatter",
"support": {
"source": "https://git.drupalcode.org/project/image_delta_formatter"
},
"time": "2018-03-21T21:15:57+00:00"
},
{ {
"name": "drupal/imagemagick", "name": "drupal/imagemagick",
"version": "2.4.0", "version": "2.4.0",
@ -16127,6 +16181,7 @@
"drupal/commerce_variation_cart_form": 20, "drupal/commerce_variation_cart_form": 20,
"drupal/computed_field": 10, "drupal/computed_field": 10,
"drupal/genpass": 20, "drupal/genpass": 20,
"drupal/image_delta_formatter": 20,
"drupal/login_history": 20, "drupal/login_history": 20,
"drupal/mailgun": 20, "drupal/mailgun": 20,
"drupal/migrate_plus": 20, "drupal/migrate_plus": 20,

View File

@ -9,22 +9,37 @@ display:
submit_button: Filtrer submit_button: Filtrer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
expose: expose:
items_per_page_label: 'Éléments par page' items_per_page_label: 'Éléments par page'
items_per_page_options_all_label: '- Tout -' items_per_page_options_all_label: '- Tout -'
offset_label: Décalage offset_label: Décalage
tags:
previous:
next:
fields: fields:
nothing: nothing:
admin_label: Icône admin_label: Icône
severity: severity:
label: Importance label: Importance
type:
label: Type
timestamp:
label: Date
message:
label: Message
name: name:
label: Utilisateur label: Utilisateur
separator: ', '
link: link:
label: Actions label: Actions
filters: filters:
type:
expose:
label: Type
severity: severity:
expose: expose:
label: Importance label: Importance
@ -33,3 +48,5 @@ display:
area: area:
admin_label: 'Aucune entrée du journal n''est disponible.' admin_label: 'Aucune entrée du journal n''est disponible.'
content: 'Aucune entrée du journal n''est disponible.' content: 'Aucune entrée du journal n''est disponible.'
page:
display_title: Page

View File

@ -20,7 +20,6 @@ dependencies:
- datetime_range - datetime_range
- image - image
- link - link
- options
- text - text
- user - user
- video_embed_field - video_embed_field
@ -32,12 +31,12 @@ content:
body: body:
label: hidden label: hidden
type: text_default type: text_default
weight: 101 weight: 0
settings: { } settings: { }
third_party_settings: { } third_party_settings: { }
region: content region: content
field_date: field_date:
weight: 112 weight: 6
label: above label: above
settings: settings:
separator: '-' separator: '-'
@ -47,29 +46,7 @@ content:
type: daterange_default type: daterange_default
region: content region: content
field_linked_materials: field_linked_materials:
weight: 113 weight: 7
label: above
settings:
link: true
third_party_settings: { }
type: entity_reference_label
region: content
field_memo:
weight: 108
label: above
settings: { }
third_party_settings: { }
type: basic_string
region: content
field_migration:
weight: 109
label: above
settings: { }
third_party_settings: { }
type: list_default
region: content
field_showroom:
weight: 111
label: above label: above
settings: settings:
link: true link: true
@ -77,7 +54,7 @@ content:
type: entity_reference_label type: entity_reference_label
region: content region: content
field_source: field_source:
weight: 102 weight: 1
label: above label: above
settings: settings:
trim_length: 80 trim_length: 80
@ -89,7 +66,7 @@ content:
type: link type: link
region: content region: content
field_tags: field_tags:
weight: 106 weight: 5
label: above label: above
settings: settings:
link: true link: true
@ -97,7 +74,7 @@ content:
type: entity_reference_label type: entity_reference_label
region: content region: content
field_thesaurus: field_thesaurus:
weight: 105 weight: 4
label: above label: above
settings: settings:
link: true link: true
@ -105,7 +82,7 @@ content:
type: entity_reference_label type: entity_reference_label
region: content region: content
field_video: field_video:
weight: 104 weight: 3
label: above label: above
settings: settings:
responsive: true responsive: true
@ -116,7 +93,7 @@ content:
type: video_embed_field_video type: video_embed_field_video
region: content region: content
field_visuel: field_visuel:
weight: 103 weight: 2
label: above label: above
settings: settings:
image_style: '' image_style: ''
@ -124,17 +101,14 @@ content:
third_party_settings: { } third_party_settings: { }
type: image type: image
region: content region: content
field_workflow:
weight: 110
label: above
settings: { }
third_party_settings: { }
type: list_default
region: content
links: links:
weight: 100 weight: 8
region: content
settings: { } settings: { }
third_party_settings: { } third_party_settings: { }
region: content
hidden: hidden:
field_memo: true
field_migration: true
field_showroom: true
field_workflow: true
langcode: true langcode: true

View File

@ -6,6 +6,7 @@ dependencies:
- core.entity_view_mode.node.teaser - core.entity_view_mode.node.teaser
- field.field.node.article.body - field.field.node.article.body
- field.field.node.article.field_date - field.field.node.article.field_date
- field.field.node.article.field_linked_materials
- field.field.node.article.field_memo - field.field.node.article.field_memo
- field.field.node.article.field_migration - field.field.node.article.field_migration
- field.field.node.article.field_showroom - field.field.node.article.field_showroom
@ -15,8 +16,10 @@ dependencies:
- field.field.node.article.field_video - field.field.node.article.field_video
- field.field.node.article.field_visuel - field.field.node.article.field_visuel
- field.field.node.article.field_workflow - field.field.node.article.field_workflow
- image.style.medium
- node.type.article - node.type.article
module: module:
- image_delta_formatter
- text - text
- user - user
id: node.article.teaser id: node.article.teaser
@ -27,16 +30,27 @@ content:
body: body:
label: hidden label: hidden
type: text_summary_or_trimmed type: text_summary_or_trimmed
weight: 101 weight: 0
settings: settings:
trim_length: 600 trim_length: 200
third_party_settings: { } third_party_settings: { }
region: content region: content
field_visuel:
type: image_delta_formatter
weight: 1
region: content
label: hidden
settings:
deltas: '0'
image_style: medium
image_link: content
deltas_reversed: 0
third_party_settings: { }
links: links:
weight: 100 weight: 2
region: content
settings: { } settings: { }
third_party_settings: { } third_party_settings: { }
region: content
hidden: hidden:
field_date: true field_date: true
field_linked_materials: true field_linked_materials: true
@ -47,6 +61,5 @@ hidden:
field_tags: true field_tags: true
field_thesaurus: true field_thesaurus: true
field_video: true field_video: true
field_visuel: true
field_workflow: true field_workflow: true
langcode: true langcode: true

View File

@ -16,22 +16,33 @@ targetEntityType: node
bundle: frontpage bundle: frontpage
mode: default mode: default
content: content:
computed_articles_reference:
label: hidden
weight: 6
region: content
settings:
view_mode: teaser
link: false
third_party_settings: { }
type: entity_reference_entity_view
computed_materials_reference: computed_materials_reference:
weight: 2 weight: 2
region: content region: content
settings: settings:
view_mode: teaser
link: false link: false
third_party_settings: { } third_party_settings: { }
type: entity_reference_label type: entity_reference_entity_view
label: hidden label: hidden
computed_showrooms_reference: computed_showrooms_reference:
label: hidden label: hidden
weight: 4 weight: 4
region: content region: content
settings: settings:
link: true view_mode: default
link: false
third_party_settings: { } third_party_settings: { }
type: entity_reference_label type: entity_reference_entity_view
field_a_database: field_a_database:
weight: 1 weight: 1
label: above label: above

View File

@ -23,29 +23,31 @@ dependencies:
- field.field.node.materiau.field_thesaurus - field.field.node.materiau.field_thesaurus
- field.field.node.materiau.field_video - field.field.node.materiau.field_video
- field.field.node.materiau.field_workflow - field.field.node.materiau.field_workflow
- image.style.medium
- node.type.materiau - node.type.materiau
module: module:
- text - image_delta_formatter
- user - user
id: node.materiau.teaser id: node.materiau.teaser
targetEntityType: node targetEntityType: node
bundle: materiau bundle: materiau
mode: teaser mode: teaser
content: content:
body: field_materiau_images:
type: image_delta_formatter
weight: 0
region: content
label: hidden label: hidden
type: text_summary_or_trimmed
weight: 101
settings: settings:
trim_length: 600 deltas: '0'
third_party_settings: { } image_style: medium
region: content image_link: ''
links: deltas_reversed: 0
weight: 100
region: content
settings: { }
third_party_settings: { } third_party_settings: { }
hidden: hidden:
body: true
computed_materials_reference: true
computed_showrooms_reference: true
field_attachments: true field_attachments: true
field_distributor: true field_distributor: true
field_famille: true field_famille: true
@ -54,7 +56,6 @@ hidden:
field_linked_materials: true field_linked_materials: true
field_localisation_old: true field_localisation_old: true
field_manufacturer: true field_manufacturer: true
field_materiau_images: true
field_memo: true field_memo: true
field_migration: true field_migration: true
field_reference: true field_reference: true
@ -65,3 +66,4 @@ hidden:
field_video: true field_video: true
field_workflow: true field_workflow: true
langcode: true langcode: true
links: true

View File

@ -12,7 +12,7 @@ dependencies:
- taxonomy.vocabulary.showroom - taxonomy.vocabulary.showroom
module: module:
- address - address
- options - telephone_formatter
- text - text
id: taxonomy_term.showroom.default id: taxonomy_term.showroom.default
targetEntityType: taxonomy_term targetEntityType: taxonomy_term
@ -26,20 +26,6 @@ content:
region: content region: content
settings: { } settings: { }
third_party_settings: { } third_party_settings: { }
field_memo:
weight: 4
label: above
settings: { }
third_party_settings: { }
type: basic_string
region: content
field_migration:
weight: 6
label: above
settings: { }
third_party_settings: { }
type: list_default
region: content
field_public_address: field_public_address:
weight: 2 weight: 2
label: above label: above
@ -52,21 +38,20 @@ content:
label: above label: above
settings: { } settings: { }
third_party_settings: { } third_party_settings: { }
type: basic_string type: email_mailto
region: content region: content
field_public_phone: field_public_phone:
weight: 1 weight: 1
label: above label: above
settings: { } settings:
format: 1
link: true
default_country: null
third_party_settings: { } third_party_settings: { }
type: basic_string type: telephone_formatter
region: content
field_workflow:
weight: 5
label: above
settings: { }
third_party_settings: { }
type: list_default
region: content region: content
hidden: hidden:
field_memo: true
field_migration: true
field_workflow: true
langcode: true langcode: true

View File

@ -72,6 +72,7 @@ module:
help: 0 help: 0
honeypot: 0 honeypot: 0
image: 0 image: 0
image_delta_formatter: 0
inline_entity_form: 0 inline_entity_form: 0
interval: 0 interval: 0
jsonapi: 0 jsonapi: 0

View File

@ -0,0 +1 @@
label: 'Par défaut'

View File

@ -0,0 +1 @@
label: 'Par défaut'

View File

@ -0,0 +1 @@
label: 'Par défaut'

View File

@ -0,0 +1 @@
label: 'Par défaut'

View File

@ -0,0 +1 @@
label: 'Par défaut'

View File

@ -0,0 +1 @@
label: 'Par défaut'

View File

@ -0,0 +1 @@
label: 'En ligne'

View File

@ -0,0 +1 @@
label: Page

View File

@ -0,0 +1 @@
label: RSS

View File

@ -0,0 +1 @@
label: Compact

View File

@ -1 +1,2 @@
extlink_alert_text: 'Ce lien vous dirige vers un site externe. Nous ne sommes pas responsables de son contenu.' extlink_alert_text: 'Ce lien vous dirige vers un site externe. Nous ne sommes pas responsables de son contenu.'
extlink_label: '(le lien est externe)'

View File

@ -0,0 +1 @@
label: 'Eléments de la commande'

View File

@ -0,0 +1 @@
label: 'Eléments de la commande'

View File

@ -0,0 +1 @@
label: Variations

View File

@ -1,6 +1,12 @@
default_config: default_config:
tags: tags:
page_breaker:
pages: pages:
prefix_label: Page
first: «
previous:
next:
last: »
page_current_title: 'Page courante' page_current_title: 'Page courante'
page_title: 'Aller à la page @number' page_title: 'Aller à la page @number'
first_title: 'Aller à la première page' first_title: 'Aller à la première page'
@ -8,14 +14,23 @@ default_config:
next_title: 'Aller à la page suivante' next_title: 'Aller à la page suivante'
last_title: 'Aller à la dernière page' last_title: 'Aller à la dernière page'
page_current_reader: 'Page courante' page_current_reader: 'Page courante'
page_reader: Page
first_reader: 'Première page' first_reader: 'Première page'
previous_reader: 'Page précédente' previous_reader: 'Page précédente'
next_reader: 'Page suivante' next_reader: 'Page suivante'
last_reader: 'Dernière page' last_reader: 'Dernière page'
items: items:
prefix_label: Élément prefix_label: Élément
first: «
previous:
next:
last: »
page_reader: Élément page_reader: Élément
first_reader: 'Premier élément' first_reader: 'Premier élément'
item_ranges: item_ranges:
prefix_label: Éléments prefix_label: Éléments
first: «
previous:
next:
last: »
page_reader: Éléments page_reader: Éléments

View File

@ -1,6 +1,10 @@
default_config: default_config:
tags: tags:
pages: pages:
first: «
previous:
next:
last: »
first_title: 'Aller à la première page' first_title: 'Aller à la première page'
previous_title: 'Aller à la page précédente' previous_title: 'Aller à la page précédente'
next_title: 'Aller à la page suivante' next_title: 'Aller à la page suivante'
@ -10,4 +14,13 @@ default_config:
next_reader: 'Page suivante' next_reader: 'Page suivante'
last_reader: 'Dernière page' last_reader: 'Dernière page'
items: items:
first: «
previous:
next:
last: »
first_reader: 'Premier élément' first_reader: 'Premier élément'
item_ranges:
first: «
previous:
next:
last: »

View File

@ -1,6 +1,11 @@
default_config: default_config:
tags: tags:
pages: pages:
prefix_label: Page
first: «
previous:
next:
last: »
page_current_title: 'Page courante' page_current_title: 'Page courante'
first_title: 'Aller à la première page' first_title: 'Aller à la première page'
previous_title: 'Aller à la page précédente' previous_title: 'Aller à la page précédente'
@ -13,4 +18,8 @@ default_config:
last_reader: 'Dernière page' last_reader: 'Dernière page'
items: items:
prefix_label: Élément prefix_label: Élément
first: «
previous:
next:
last: »
first_reader: 'Premier élément' first_reader: 'Premier élément'

View File

@ -1,6 +1,12 @@
default_config: default_config:
tags: tags:
page_breaker:
pages: pages:
prefix_label: Page
first: «
previous:
next:
last: »
page_current_title: 'Page courante' page_current_title: 'Page courante'
page_title: 'Aller à la page @number' page_title: 'Aller à la page @number'
first_title: 'Aller à la première page' first_title: 'Aller à la première page'
@ -8,14 +14,23 @@ default_config:
next_title: 'Aller à la page suivante' next_title: 'Aller à la page suivante'
last_title: 'Aller à la dernière page' last_title: 'Aller à la dernière page'
page_current_reader: 'Page courante' page_current_reader: 'Page courante'
page_reader: Page
first_reader: 'Première page' first_reader: 'Première page'
previous_reader: 'Page précédente' previous_reader: 'Page précédente'
next_reader: 'Page suivante' next_reader: 'Page suivante'
last_reader: 'Dernière page' last_reader: 'Dernière page'
items: items:
prefix_label: Élément prefix_label: Élément
first: «
previous:
next:
last: »
page_reader: Élément page_reader: Élément
first_reader: 'Premier élément' first_reader: 'Premier élément'
item_ranges: item_ranges:
prefix_label: Éléments prefix_label: Éléments
first: «
previous:
next:
last: »
page_reader: Éléments page_reader: Éléments

View File

@ -1,6 +1,11 @@
default_config: default_config:
tags: tags:
pages: pages:
prefix_label: Page
first: «
previous:
next:
last: »
page_current_title: 'Page courante' page_current_title: 'Page courante'
page_title: 'Aller à la page @number' page_title: 'Aller à la page @number'
first_title: 'Aller à la première page' first_title: 'Aller à la première page'
@ -8,14 +13,23 @@ default_config:
next_title: 'Aller à la page suivante' next_title: 'Aller à la page suivante'
last_title: 'Aller à la dernière page' last_title: 'Aller à la dernière page'
page_current_reader: 'Page courante' page_current_reader: 'Page courante'
page_reader: Page
first_reader: 'Première page' first_reader: 'Première page'
previous_reader: 'Page précédente' previous_reader: 'Page précédente'
next_reader: 'Page suivante' next_reader: 'Page suivante'
last_reader: 'Dernière page' last_reader: 'Dernière page'
items: items:
prefix_label: Élément prefix_label: Élément
first: «
previous:
next:
last: »
page_reader: Élément page_reader: Élément
first_reader: 'Premier élément' first_reader: 'Premier élément'
item_ranges: item_ranges:
prefix_label: Éléments prefix_label: Éléments
first: «
previous:
next:
last: »
page_reader: Éléments page_reader: Éléments

View File

@ -1,6 +1,11 @@
default_config: default_config:
tags: tags:
pages: pages:
prefix_label: Page
first: «
previous:
next:
last: »
page_current_title: 'Page courante' page_current_title: 'Page courante'
first_title: 'Aller à la première page' first_title: 'Aller à la première page'
previous_title: 'Aller à la page précédente' previous_title: 'Aller à la page précédente'
@ -13,6 +18,14 @@ default_config:
last_reader: 'Dernière page' last_reader: 'Dernière page'
items: items:
prefix_label: Élément prefix_label: Élément
first: «
previous:
next:
last: »
first_reader: 'Premier élément' first_reader: 'Premier élément'
item_ranges: item_ranges:
prefix_label: Éléments prefix_label: Éléments
first: «
previous:
next:
last: »

View File

@ -1,6 +1,8 @@
default_config: default_config:
tags: tags:
page_breaker:
pages: pages:
prefix_label: Page
first: '« Premier' first: '« Premier'
previous: ' Précédent' previous: ' Précédent'
next: 'Suivant ' next: 'Suivant '
@ -12,6 +14,7 @@ default_config:
next_title: 'Aller à la page suivante' next_title: 'Aller à la page suivante'
last_title: 'Aller à la dernière page' last_title: 'Aller à la dernière page'
page_current_reader: 'Page courante' page_current_reader: 'Page courante'
page_reader: Page
first_reader: 'Première page' first_reader: 'Première page'
previous_reader: 'Page précédente' previous_reader: 'Page précédente'
next_reader: 'Page suivante' next_reader: 'Page suivante'

View File

@ -0,0 +1 @@
label: 'Supprimer la commande'

View File

@ -0,0 +1 @@
label: 'Supprimer un produit'

View File

@ -0,0 +1 @@
label: 'Publier un produit'

View File

@ -0,0 +1 @@
label: 'Supprimer une boutique'

View File

@ -0,0 +1 @@
label: 'Dépublier un produit'

View File

@ -0,0 +1 @@
label: 'Épingler un contenu en haut des listes'

View File

@ -0,0 +1 @@
label: 'Retirer un contenu du haut des listes'

View File

@ -0,0 +1 @@
label: 'Promouvoir le contenu en page d''accueil'

View File

@ -0,0 +1 @@
label: 'Publier un contenu'

View File

@ -0,0 +1 @@
label: 'Retirer un contenu de la page d''accueil'

View File

@ -0,0 +1 @@
label: 'Dépublier un contenu'

View File

@ -7,24 +7,41 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
expose: expose:
items_per_page_label: 'Éléments par page' items_per_page_label: 'Éléments par page'
items_per_page_options_all_label: '- Tout -' items_per_page_options_all_label: '- Tout -'
offset_label: Décalage offset_label: Décalage
tags:
previous:
next:
fields: fields:
job_id:
label: 'Identifiant (ID) de Travail'
state: state:
label: État label: État
type:
label: 'Catégorie de travail'
payload: payload:
label: Charges label: Charges
message:
label: Message
operations: operations:
label: Actions label: Actions
filters: filters:
type:
expose:
label: 'Catégorie de travail'
state: state:
expose: expose:
label: État label: État
title: Travaux
arguments: arguments:
queue_id: queue_id:
exception: exception:
title: Tout title: Tout
page_1:
display_title: Page

View File

@ -10,11 +10,18 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
expose: expose:
items_per_page_label: 'Éléments par page' items_per_page_label: 'Éléments par page'
items_per_page_options_all_label: '- Tout -' items_per_page_options_all_label: '- Tout -'
offset_label: Décalage offset_label: Décalage
tags:
previous:
next:
block_1: block_1:
display_title: Bloc display_title: Bloc
page_1:
display_title: Page

View File

@ -8,9 +8,17 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
fields: fields:
created:
label: Date
separator: ', '
rendered_entity:
label: Message
uid: uid:
label: Utilisateur label: Utilisateur
separator: ', '
arguments: arguments:
source_entity_id: source_entity_id:
exception: exception:

View File

@ -8,6 +8,15 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
fields:
quantity:
separator: ', '
title:
separator: ', '
total_price__number:
separator: ', '
arguments: arguments:
order_id: order_id:
exception: exception:

View File

@ -1,3 +1,4 @@
label: 'Formulaire du panier'
display: display:
default: default:
display_title: Maître display_title: Maître
@ -7,15 +8,22 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
fields: fields:
purchased_entity: purchased_entity:
label: Élément label: Élément
separator: ', '
unit_price__number: unit_price__number:
label: Prix label: Prix
separator: ', '
edit_quantity: edit_quantity:
label: Quantité label: Quantité
remove_button: remove_button:
label: Retirer label: Retirer
total_price__number:
label: Total
separator: ', '
arguments: arguments:
order_id: order_id:
exception: exception:

View File

@ -1,3 +1,4 @@
label: Paniers
display: display:
default: default:
display_title: Maître display_title: Maître
@ -7,6 +8,8 @@ display:
submit_button: Filtrer submit_button: Filtrer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
expose: expose:
@ -21,13 +24,36 @@ display:
fields: fields:
commerce_order_bulk_form: commerce_order_bulk_form:
action_title: 'Pour cette sélection' action_title: 'Pour cette sélection'
type:
label: Type
separator: ', '
store_id: store_id:
label: Boutique label: Boutique
separator: ', '
uid: uid:
label: Client label: Client
separator: ', '
mail: mail:
label: Courriel label: Courriel
separator: ', '
total_price__number:
label: Total
separator: ', '
changed: changed:
label: 'Mis à jour' label: 'Mis à jour'
separator: ', '
operations: operations:
label: Actions label: Actions
filters:
type:
expose:
label: Type
title: Paniers
empty:
area_text_custom:
content: 'Aucune commande n''est disponible.'
page_1:
display_title: Page
display_options:
menu:
title: Paniers

View File

@ -7,6 +7,15 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
fields:
quantity:
separator: ', '
purchased_entity:
separator: ', '
total_price__number:
separator: ', '
arguments: arguments:
order_id: order_id:
exception: exception:

View File

@ -8,9 +8,13 @@ display:
submit_button: Filtrer submit_button: Filtrer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
tags: tags:
previous:
next:
first: '« Premier' first: '« Premier'
last: 'Dernier »' last: 'Dernier »'
expose: expose:
@ -20,18 +24,24 @@ display:
fields: fields:
license_id: license_id:
label: 'Identifiant (ID)' label: 'Identifiant (ID)'
separator: ', '
label: label:
label: Étiquette label: Étiquette
type: type:
label: 'Type de licence' label: 'Type de licence'
separator: ', '
uid: uid:
label: Propriétaire label: Propriétaire
separator: ', '
state: state:
label: État label: État
separator: ', '
changed: changed:
label: 'Mis à jour' label: 'Mis à jour'
separator: ', '
granted: granted:
label: Accordé(e) label: Accordé(e)
separator: ', '
operations: operations:
label: 'Liens d''actions' label: 'Liens d''actions'
filters: filters:
@ -39,3 +49,5 @@ display:
expose: expose:
label: État label: État
title: Licences title: Licences
page_1:
display_title: Page

View File

@ -1,3 +1,4 @@
label: 'Eléments de la commande'
display: display:
default: default:
display_title: Maître display_title: Maître
@ -7,15 +8,21 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
fields: fields:
title: title:
label: Titre label: Titre
separator: ', '
unit_price__number: unit_price__number:
label: 'Prix unitaire' label: 'Prix unitaire'
separator: ', '
quantity: quantity:
label: Quantité label: Quantité
separator: ', '
total_price__number: total_price__number:
label: 'Prix total' label: 'Prix total'
separator: ', '
arguments: arguments:
order_id: order_id:
exception: exception:

View File

@ -8,6 +8,8 @@ display:
submit_button: Filtrer submit_button: Filtrer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
expose: expose:
@ -22,25 +24,48 @@ display:
fields: fields:
commerce_order_bulk_form: commerce_order_bulk_form:
action_title: 'Pour cette sélection' action_title: 'Pour cette sélection'
order_number:
label: '#'
separator: ', '
placed:
label: Date
separator: ', '
type:
label: Type
separator: ', '
store_id: store_id:
label: Boutique label: Boutique
separator: ', '
uid: uid:
label: Client label: Client
separator: ', '
mail: mail:
label: Courriel label: Courriel
separator: ', '
state: state:
label: État label: État
separator: ', '
total_price__number:
label: Total
separator: ', '
operations: operations:
label: Actions label: Actions
filters: filters:
order_number: order_number:
expose: expose:
label: 'Numéro de commande' label: 'Numéro de commande'
type:
expose:
label: Type
state: state:
expose: expose:
label: État label: État
title: Commandes title: Commandes
empty:
area_text_custom:
content: 'Aucune commande n''est disponible.'
page_1: page_1:
display_title: Page
display_options: display_options:
menu: menu:
title: Commandes title: Commandes

View File

@ -8,6 +8,8 @@ display:
submit_button: Filtrer submit_button: Filtrer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
expose: expose:
@ -24,17 +26,31 @@ display:
action_title: 'Pour cette sélection' action_title: 'Pour cette sélection'
title: title:
label: Titre label: Titre
separator: ', '
type:
label: Type
separator: ', '
status: status:
label: Etat label: Etat
settings: settings:
format_custom_true: Publié format_custom_true: Publié
format_custom_false: 'Non publié' format_custom_false: 'Non publié'
separator: ', '
changed: changed:
label: 'Mis à jour' label: 'Mis à jour'
separator: ', '
operations: operations:
label: Actions label: Actions
filters: filters:
type:
expose:
label: Type
title: title:
expose: expose:
label: Titre label: Titre
title: Produits title: Produits
empty:
area_text_custom:
content: 'Aucun produit disponible.'
page_1:
display_title: Page

View File

@ -8,6 +8,8 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
expose: expose:
@ -24,6 +26,16 @@ display:
action_title: 'Pour cette sélection' action_title: 'Pour cette sélection'
name: name:
label: Nom label: Nom
separator: ', '
type:
label: Type
separator: ', '
operations: operations:
label: Actions label: Actions
filters:
type:
expose:
label: Type
title: Boutiques title: Boutiques
page_1:
display_title: Page

View File

@ -7,6 +7,8 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
tags: tags:
@ -21,11 +23,24 @@ display:
fields: fields:
order_id: order_id:
label: 'Identifiant (ID)' label: 'Identifiant (ID)'
separator: ', '
order_number: order_number:
label: 'Numéro de commande' label: 'Numéro de commande'
separator: ', '
placed:
label: Date
separator: ', '
total_price__number:
label: Total
separator: ', '
state: state:
label: État label: État
separator: ', '
title: Commandes title: Commandes
empty:
area:
content:
value: 'Vous ne nous avez encore rien commandé.'
arguments: arguments:
uid: uid:
exception: exception:

View File

@ -8,6 +8,8 @@ display:
submit_button: Filtrer submit_button: Filtrer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
tags: tags:
@ -20,6 +22,7 @@ display:
label: Titre label: Titre
type: type:
label: 'Type de contenu' label: 'Type de contenu'
separator: ', '
name: name:
label: Auteur label: Auteur
status: status:
@ -63,3 +66,4 @@ display:
tab_options: tab_options:
title: Contenu title: Contenu
description: 'Trouver et gérer le contenu' description: 'Trouver et gérer le contenu'
display_title: Page

View File

@ -9,6 +9,11 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
fields:
changed:
separator: ', '
title: 'Contenu récent' title: 'Contenu récent'
empty: empty:
area_text_custom: area_text_custom:

View File

@ -7,9 +7,13 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
tags: tags:
previous:
next:
first: '« Premier' first: '« Premier'
last: 'Dernier »' last: 'Dernier »'
expose: expose:
@ -19,8 +23,10 @@ display:
fields: fields:
title: title:
label: Titre label: Titre
separator: ', '
langcode: langcode:
label: 'A partir de' label: 'A partir de'
separator: ', '
translation_target_language: translation_target_language:
label: À label: À
translation_status: translation_status:
@ -40,3 +46,5 @@ display:
translation_status: translation_status:
expose: expose:
label: 'Statut de la traduction' label: 'Statut de la traduction'
page_1:
display_title: Page

View File

@ -9,6 +9,8 @@ display:
submit_button: Filtrer submit_button: Filtrer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
expose: expose:
@ -20,6 +22,7 @@ display:
label: 'Identifiant (FID)' label: 'Identifiant (FID)'
filename: filename:
label: Nom label: Nom
separator: ', '
filemime: filemime:
label: 'Type MIME' label: 'Type MIME'
filesize: filesize:
@ -28,6 +31,7 @@ display:
label: Etat label: Etat
settings: settings:
format_custom_false: Temporaire format_custom_false: Temporaire
format_custom_true: Permanent
created: created:
label: 'Date de transfert' label: 'Date de transfert'
changed: changed:

View File

@ -13,6 +13,8 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
expose: expose:
@ -27,3 +29,5 @@ display:
display_title: Maître display_title: Maître
feed_1: feed_1:
display_title: Flux display_title: Flux
page_1:
display_title: Page

View File

@ -1,3 +1,4 @@
label: Glossary
description: 'Tous les contenus, triés par lettre.' description: 'Tous les contenus, triés par lettre.'
display: display:
default: default:
@ -8,12 +9,17 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
expose: expose:
items_per_page_label: 'Éléments par page' items_per_page_label: 'Éléments par page'
items_per_page_options_all_label: '- Tout -' items_per_page_options_all_label: '- Tout -'
offset_label: Décalage offset_label: Décalage
tags:
previous:
next:
fields: fields:
title: title:
label: Titre label: Titre
@ -23,3 +29,8 @@ display:
label: 'Dernière mise à jour' label: 'Dernière mise à jour'
attachment_1: attachment_1:
display_title: 'Fichier attaché' display_title: 'Fichier attaché'
page_1:
display_title: Page
display_options:
menu:
title: Glossary

View File

@ -7,9 +7,13 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
tags: tags:
previous:
next:
first: '« Premier' first: '« Premier'
last: 'Dernier »' last: 'Dernier »'
expose: expose:
@ -19,10 +23,14 @@ display:
fields: fields:
title: title:
label: Titre label: Titre
separator: ', '
type: type:
label: 'Type de contenu' label: 'Type de contenu'
separator: ', '
timestamp: timestamp:
label: 'Date / Heure du verrouillage' label: 'Date / Heure du verrouillage'
name:
separator: ', '
operations: operations:
label: Actions label: Actions
filters: filters:
@ -42,3 +50,5 @@ display:
title: title:
expose: expose:
label: Titre label: Titre
page_1:
display_title: Page

View File

@ -7,6 +7,8 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
expose: expose:
@ -19,9 +21,15 @@ display:
first: "«\_premier" first: "«\_premier"
last: "dernier\_»" last: "dernier\_»"
fields: fields:
idmaillog:
label: '#'
sent_date:
label: Date
subject: subject:
label: Objet label: Objet
header_from: header_from:
label: 'A partir de' label: 'A partir de'
header_to: header_to:
label: À label: À
page_1:
display_title: Page

View File

@ -8,6 +8,8 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
arguments: arguments:
uid: uid:
exception: exception:

View File

@ -8,6 +8,8 @@ display:
submit_button: Filtrer submit_button: Filtrer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
tags: tags:
@ -24,6 +26,7 @@ display:
action_title: 'Pour cette sélection' action_title: 'Pour cette sélection'
redirect_source__path: redirect_source__path:
label: 'A partir de' label: 'A partir de'
separator: ', '
created: created:
label: Créé label: Créé
filters: filters:
@ -57,3 +60,5 @@ display:
expose: expose:
label: 'Langue d''origine' label: 'Langue d''origine'
title: Rediriger title: Rediriger
page_1:
display_title: Page

View File

@ -7,6 +7,8 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
expose: expose:
@ -17,9 +19,14 @@ display:
node_bulk_form: node_bulk_form:
label: 'Formulaire des opérations en masse sur les nœuds' label: 'Formulaire des opérations en masse sur les nœuds'
action_title: 'Pour cette sélection' action_title: 'Pour cette sélection'
simplenews_issue:
separator: ', '
status: status:
label: Publié label: Publié
separator: ', '
created: created:
label: 'Mis à jour' label: 'Mis à jour'
operations: operations:
label: 'Liens d''actions' label: 'Liens d''actions'
page_1:
display_title: Page

View File

@ -7,6 +7,8 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
tags: tags:
@ -23,6 +25,8 @@ display:
label: Courriel label: Courriel
user_name: user_name:
label: 'Nom d''utilisateur' label: 'Nom d''utilisateur'
subscriptions:
separator: ', '
status: status:
label: Actif label: Actif
created: created:
@ -39,3 +43,5 @@ display:
subscriptions_status: subscriptions_status:
expose: expose:
label: Etat label: Etat
page_1:
display_title: Page

View File

@ -9,15 +9,22 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
expose: expose:
items_per_page_label: 'Éléments par page' items_per_page_label: 'Éléments par page'
items_per_page_options_all_label: '- Tout -' items_per_page_options_all_label: '- Tout -'
offset_label: Décalage offset_label: Décalage
tags:
previous:
next:
arguments: arguments:
tid: tid:
exception: exception:
title: Tout title: Tout
feed_1: feed_1:
display_title: Flux display_title: Flux
page_1:
display_title: Page

View File

@ -9,6 +9,8 @@ display:
submit_button: Filtrer submit_button: Filtrer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
tags: tags:
@ -38,6 +40,8 @@ display:
label: 'Dernier accès' label: 'Dernier accès'
operations: operations:
label: Actions label: Actions
mail:
separator: ', '
filters: filters:
combine: combine:
expose: expose:
@ -62,6 +66,7 @@ display:
content: 'Personne n''est disponible.' content: 'Personne n''est disponible.'
use_more_text: plus use_more_text: plus
page_1: page_1:
display_title: Page
display_options: display_options:
menu: menu:
title: Lister title: Lister

View File

@ -9,6 +9,8 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
title: 'Nouveaux membres' title: 'Nouveaux membres'
block_1: block_1:
display_title: 'Nouveaux membres' display_title: 'Nouveaux membres'

View File

@ -9,6 +9,8 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
filters: filters:
access: access:
expose: expose:

View File

@ -7,21 +7,36 @@ display:
submit_button: Appliquer submit_button: Appliquer
reset_button_label: Réinitialiser reset_button_label: Réinitialiser
exposed_sorts_label: 'Trier par' exposed_sorts_label: 'Trier par'
sort_asc_label: Asc
sort_desc_label: Desc
pager: pager:
options: options:
expose: expose:
items_per_page_label: 'Éléments par page' items_per_page_label: 'Éléments par page'
items_per_page_options_all_label: '- Tout -' items_per_page_options_all_label: '- Tout -'
offset_label: Décalage offset_label: Décalage
tags:
previous:
next:
fields: fields:
hid:
separator: ', '
timestamp: timestamp:
label: Horodatage label: Horodatage
separator: ', '
field_name: field_name:
label: 'Nom du champ' label: 'Nom du champ'
separator: ', '
from_sid:
separator: ', '
to_sid:
separator: ', '
uid: uid:
label: 'Identifiant (ID) utilisateur' label: 'Identifiant (ID) utilisateur'
separator: ', '
comment: comment:
label: 'Message de journal' label: 'Message de journal'
separator: ', '
operations: operations:
label: Actions label: Actions
arguments: arguments:

View File

@ -29,20 +29,21 @@ use Drupal\mymodule\Plugin\Field\FieldType\MyFieldComputed;
* @param array $base_field_definitions * @param array $base_field_definitions
* @return array * @return array
*/ */
// function materio_home_entity_bundle_field_info(EntityTypeInterface $entity_type, $bundle, array $base_field_definitions) { function materio_home_entity_bundle_field_info(EntityTypeInterface $entity_type, $bundle, array $base_field_definitions) {
function materio_home_entity_base_field_info_alter(&$fields, EntityTypeInterface $entity_type) { // function materio_home_entity_base_field_info_alter(&$fields, EntityTypeInterface $entity_type) {
// $fields = array(); // $fields = array();
// if ($entity_type->id() == 'node' && $bundle === 'frontpage') { // if ($entity_type->id() == 'node' && $bundle === 'frontpage') {
if ($entity_type->id() == 'node') { // \Drupal::logger('materio_home')->notice('bundle: '.$bundle);
if ($entity_type->id() == 'node' && $bundle == 'frontpage') {
$fields['computed_materials_reference'] = BaseFieldDefinition::create('entity_reference') $fields['computed_materials_reference'] = BaseFieldDefinition::create('entity_reference')
->setName('computed_materials_reference') ->setName('computed_materials_reference')
->setLabel(t('Computed Materials References')) ->setLabel(t('Computed Materials References'))
->setDescription(t('Computed Materials References.')) ->setDescription(t('Computed Materials References.'))
// // The Entity Type this field belongs to. // // The Entity Type this field belongs to.
->setSetting('target_type', 'node') ->setTargetEntityTypeId($entity_type->id())
// // The Entity Type bundle this field belongs to. // // The Entity Type bundle this field belongs to.
->setTargetBundle('frontpage') ->setTargetBundle($bundle)
->setTargetEntityTypeId('node') ->setSetting('target_type', 'node')
->setCardinality(FieldStorageDefinitionInterface::CARDINALITY_UNLIMITED) ->setCardinality(FieldStorageDefinitionInterface::CARDINALITY_UNLIMITED)
->setComputed(TRUE) ->setComputed(TRUE)
->setRevisionable(FALSE) ->setRevisionable(FALSE)
@ -58,11 +59,11 @@ function materio_home_entity_base_field_info_alter(&$fields, EntityTypeInterface
->setName('computed_showrooms_reference') ->setName('computed_showrooms_reference')
->setLabel(t('Computed Showrooms References')) ->setLabel(t('Computed Showrooms References'))
->setDescription(t('Computed Showrooms References.')) ->setDescription(t('Computed Showrooms References.'))
->setSetting('target_type', 'taxonomy_term')
// // The Entity Type this field belongs to. // // The Entity Type this field belongs to.
->setTargetEntityTypeId('node') ->setTargetEntityTypeId($entity_type->id())
// // The Entity Type bundle this field belongs to. // // The Entity Type bundle this field belongs to.
->setTargetBundle('frontpage') ->setTargetBundle($bundle)
->setSetting('target_type', 'taxonomy_term')
->setCardinality(FieldStorageDefinitionInterface::CARDINALITY_UNLIMITED) ->setCardinality(FieldStorageDefinitionInterface::CARDINALITY_UNLIMITED)
->setComputed(TRUE) ->setComputed(TRUE)
->setRevisionable(FALSE) ->setRevisionable(FALSE)
@ -73,9 +74,30 @@ function materio_home_entity_base_field_info_alter(&$fields, EntityTypeInterface
'weight' => -5, 'weight' => -5,
]) ])
->setClass(\Drupal\materio_home\Plugin\Field\FieldType\ComputedShowroomsReferences::class); ->setClass(\Drupal\materio_home\Plugin\Field\FieldType\ComputedShowroomsReferences::class);
}
$fields['computed_articles_reference'] = BaseFieldDefinition::create('entity_reference')
->setName('computed_articles_reference')
->setLabel(t('Computed Articles References'))
->setDescription(t('Computed Articles References.'))
// // The Entity Type this field belongs to.
->setTargetEntityTypeId($entity_type->id())
// // The Entity Type bundle this field belongs to.
->setTargetBundle($bundle)
->setSetting('target_type', 'node')
->setCardinality(FieldStorageDefinitionInterface::CARDINALITY_UNLIMITED)
->setComputed(TRUE)
->setRevisionable(FALSE)
->setTranslatable(FALSE)
->setDisplayConfigurable('view', TRUE)
->setDisplayOptions('view', [
'label' => 'hidden',
'weight' => -5,
])
->setClass(\Drupal\materio_home\Plugin\Field\FieldType\ComputedArticlesReferences::class);
return $fields; return $fields;
} }
}
// /** // /**
// * implements hook_entity_extra_field_info // * implements hook_entity_extra_field_info

View File

@ -0,0 +1,49 @@
<?php
namespace Drupal\materio_home\Plugin\Field\FieldType;
use Drupal\Core\Entity\FieldableEntityInterface;
use Drupal\Core\Field\EntityReferenceFieldItemList;
use Drupal\Core\Field\EntityReferenceFieldItemListInterface;
use Drupal\Core\Field\FieldItemList;
use Drupal\Core\TypedData\TypedDataInterface;
use Drupal\Core\Field\BaseFieldDefinition;
use Drupal\Core\TypedData\ComputedItemListTrait;
// https://www.drupal.org/node/2112677
// https://www.cornel.co/article/entity-reference-computed-field-example-drupal
// https://www.caxy.com/blog/drupal-custom-form-and-computed-fields
class ComputedArticlesReferences extends EntityReferenceFieldItemList
{
use ComputedItemListTrait;
/**
* The entity type manager.
*
* @var \Drupal\Core\Entity\EntityTypeManagerInterface
*/
protected $entityTypeManager;
/**
* {@inheritdoc}
*/
public function __construct(BaseFieldDefinition $definition, $name, TypedDataInterface $parent) {
parent::__construct($definition, $name, $parent);
$this->entityTypeManager = \Drupal::entityTypeManager();
}
/**
* Compute the values.
*/
protected function computeValue() {
$query = \Drupal::entityQuery('node')
->condition('status', 1)
->sort('created', 'DESC')
->range(0,5)
->condition('type', 'article');
$nids = $query->execute();
foreach ($nids as $key => $nid) {
$this->list[$key] = $this->createItem($key, $nid);
}
}
}

View File

@ -44,13 +44,8 @@ class ComputedMaterialsReferences extends EntityReferenceFieldItemList
->range(0,200); ->range(0,200);
$results = $query->execute(); $results = $query->execute();
$nids = array_rand($results, 20); $nids = array_rand($results, 20);
$nodes = entity_load_multiple('node', $nids); foreach ($nids as $key => $nid) {
// \Drupal::logger('materio_home')->notice(print_r($nodes, true)); $this->list[$key] = $this->createItem($key, $nid);
$key = 0;
foreach ($nodes as $nid => $node) {
// \Drupal::logger('materio_home')->notice($nid);
$this->list[$key] = $this->createItem($key, $node->id());
$key++;
} }
} }

View File

@ -40,13 +40,8 @@ class ComputedShowroomsReferences extends EntityReferenceFieldItemList
->condition('vid', 'showroom'); ->condition('vid', 'showroom');
$tids = $query->execute(); $tids = $query->execute();
shuffle($tids); shuffle($tids);
$terms = entity_load_multiple('taxonomy_term', $tids); foreach ($tids as $key => $tid) {
// \Drupal::logger('materio_home')->notice(print_r($nodes, true)); $this->list[$key] = $this->createItem($key, $tid);
$key = 0;
foreach ($terms as $tid => $term) {
// \Drupal::logger('materio_home')->notice($nid);
$this->list[$key] = $this->createItem($key, $term->id());
$key++;
} }
} }