-
Notifications
You must be signed in to change notification settings - Fork 447
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[pkp-lib] #3261 review assignments export #3722
base: main
Are you sure you want to change the base?
Conversation
function assignAssocTypeAndIdToFile($fileId, $assocType, $assocId) { | ||
// Update the file in the database. | ||
$this->update( | ||
'UPDATE submission_files |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Beware that this will set the assoc information for all revisions. Is that intentional?
* @param $reviewId integer | ||
* @return array | ||
*/ | ||
function getByReviewId($reviewId) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The getBy
convention generally returns an object of the DAO's newDataObject
function's return type. Since you're returning IDs here, I'd suggest renaming the function.
* @return string | ||
*/ | ||
function getPluralElementName() { | ||
return 'review assignments'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think this is expected where it's called to include spaces. See lib/pkp/plugins/importexport/native/filter/NativeImportFilter.inc.php
.
* @return string | ||
*/ | ||
function getSingularElementName() { | ||
return 'review assignment'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(as above)
* @return string | ||
*/ | ||
function getPluralElementName() { | ||
return 'review rounds'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(as commented before, also below)
foreach ($submissionFileDoc->documentElement->childNodes as $childNode) { | ||
if (!is_a($childNode, 'DOMElement')) continue; | ||
if ($childNode->tagName == 'revision') $revisionNode = $childNode; | ||
if ($submissionFileDoc) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should there be an else
with an error condition?
4924cd3
to
bc3930b
Compare
No description provided.