Missing basic fields from biblio reference node

Created on 21 August 2024, 3 months ago

The reference owner should be set to the node owner, it's a bug that data this isn't migrated. The "created" and "changed" values should also be migrated.

πŸ› Bug report
Status

Needs review

Version

2.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States DamienMcKenna NH, USA

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @DamienMcKenna
  • Status changed to Needs review 3 months ago
  • πŸ‡ΊπŸ‡ΈUnited States DamienMcKenna NH, USA
  • πŸ‡ΊπŸ‡ΈUnited States DamienMcKenna NH, USA
  • πŸ‡«πŸ‡·France Toki Caen, Normandy

    I have just migrated 2500+ references from D7 Biblio to D10 Bibcite and uid is 0 for all of them.
    If we change the yml file (uid: node_uid), we should also add something in the source plugin Reference.php?
    Thanks for any tip here, migrate from Biblio is critical now that D7 EOL is close.

  • πŸ‡«πŸ‡·France Toki Caen, Normandy

    I can't get uid from D7 node table.
    I have tried this :

    bibcite_migrate_bibliography.yml

    id: bibcite_migrate_reference
    label: Reference
    migration_tags:
      - Drupal 6
      - Drupal 7
    source:
      plugin: bibcite_reference
    destination:
      plugin: entity:bibcite_reference
    process:
      # Adtitional fields:
      # biblio_full_text
      # biblio_coins
      # biblio_md5
      # biblio_formats
      # biblio_sort_title
      title: title
      uid: uid
      created: created
      changed: changed
      bibcite_year:...

    Reference.php

     public function query() {
        $query = $this->select('biblio', 'b');
        $query->join('node', 'n', 'b.vid = n.vid');
        $query->distinct();
    
        $query->fields('b');
        $query->fields('n',['uid','title','created','changed']);
    
        return $query;
      }
     /**
       * {@inheritdoc}
       */
      public function fields() {
        $fields = [
          'nid' => $this->t('Node ID'),
          'vid' => $this->t('Revision ID'),
          'uid' => $this->t('User ID (Author)'),
          'created' => $this->t('Created date'),
          'changed' => $this->t('Changed date'),
          'biblio_type' => $this->t('Type'),
          'biblio_number' => $this->t('Number'),
    .....
    
Production build 0.71.5 2024