RISReferenceNormalizer.php in Bibliography & Citation 2.0.x
File
modules/bibcite_ris/src/Normalizer/RISReferenceNormalizer.php
View source
<?php
namespace Drupal\bibcite_ris\Normalizer;
use Drupal\bibcite_entity\Entity\ReferenceInterface;
use Drupal\bibcite_entity\Normalizer\ReferenceNormalizerBase;
class RISReferenceNormalizer extends ReferenceNormalizerBase {
protected function extractFields(ReferenceInterface $reference, $format) {
$attributes = parent::extractFields($reference, $format);
$isbn = $this
->extractScalar($reference
->get('bibcite_isbn'));
$issn = $this
->extractScalar($reference
->get('bibcite_issn'));
if ($isbn || $issn) {
$attributes['SN'] = trim($isbn . '/' . $issn, '/');
}
return $attributes;
}
}