-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'addMetricsImport-784' into 'main'
Import journal metrics See merge request softwares-pkp/plugins_ojs/fullJournalTransfer!53
- Loading branch information
Showing
11 changed files
with
375 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright (c) 2014-2021 Simon Fraser University | ||
* Copyright (c) 2000-2021 John Willinsky | ||
* Copyright (c) 2014-2024 Lepidus Tecnologia | ||
* Distributed under the GNU GPL v3. For full terms see the file docs/COPYING. | ||
*/ | ||
|
||
import('plugins.importexport.native.filter.NativeXmlPublicationFilter'); | ||
|
||
class NativeXmlExtendedPublicationFilter extends NativeXmlPublicationFilter | ||
{ | ||
public function getClassName() | ||
{ | ||
return 'plugins.importexport.fullJournalTransfer.filter.import.NativeXmlExtendedPublicationFilter'; | ||
} | ||
|
||
public function handleChildElement($n, $publication) | ||
{ | ||
$deployment = $this->getDeployment(); | ||
if ($n->tagName == 'article_galley') { | ||
$articleGalleys = $this->parseArticleGalley($n, $publication); | ||
$articleGalley = array_shift($articleGalleys); | ||
if (is_a($articleGalley, 'ArticleGalley')) { | ||
for ($childNode = $n->firstChild; $childNode !== null; $childNode = $childNode->nextSibling) { | ||
if ( | ||
is_a($childNode, 'DOMElement') | ||
&& $childNode->tagName == 'id' | ||
&& $childNode->getAttribute('type') == 'internal' | ||
) { | ||
$deployment->setRepresentationDBId($childNode->textContent, $articleGalley->getId()); | ||
} | ||
} | ||
} | ||
return; | ||
} | ||
parent::handleChildElement($n, $publication); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.