Redesign reviewers list (review assignment task)

OJS development discussion, enhancement requests, third-party patches and plug-ins.

Moderators: jmacgreg, btbell, michael, bdgregg, barbarah, asmecher

Forum rules
The Public Knowledge Project Support Forum is moving to

This forum will be maintained permanently as an archived historical resource, but all new questions should be added to the new forum. Questions will no longer be monitored on this old forum after March 30, 2015.
Posts: 4
Joined: Thu Jun 25, 2009 1:46 am

Redesign reviewers list (review assignment task)

Postby jkana » Sun Sep 27, 2009 3:50 am

I was asked for redesign reviewers list: Home > User > Editor > Submissions > #14 > Review > Reviewers
In the column ACTIVE our editors want to have dates of all active assigned reviews (each on a new line).
They also want to add new column REQUESTS where will be dates of all Review requests still unanswered.

I want to do it similar way as is done Home > User > Reviewer > Active Submissions , function index in file pages/reviewer/

But I was not able to do it. In function selectReviewer in file pages/sectionEditor/ I can't find way, how to get reviewers Id for calling (it is copy from function index in file pages/reviewer/

Code: Select all

$submissions = $reviewerSubmissionDao->getReviewerSubmissionsByReviewerId($user->getUserId(), $journal->getJournalId(), $active, $rangeInfo);

The reviewers id is assigned later in template:

Code: Select all

{iterate from=reviewers item=reviewer}
{assign var="userId" value=$reviewer->getUserId()}

Which is not very useful for me.

So my question is, how to get list of reviews assigned to an each reviewer in selectReviewer function?
Then I think I will be able to modify template, but I need $submissions (as described above) array or anything similar with all data I need.

Thanks for any suggestions.

Posts: 952
Joined: Mon May 05, 2008 10:29 am
Location: Vancouver, BC

Re: Redesign reviewers list (review assignment task)

Postby mcrider » Wed Sep 30, 2009 10:39 am

Hi jkana,

Well, what you're trying to do here is quite complicated; it involves getting the right data, then displaying correctly in the right template (templates/sectionEditor/selectReviewer.tpl). That said, you'll see in the selectReviewer function of, a $reviewers variable being defined that is used in the template. With that $reviewers 'array' (its actually an object that behaves much like an array), you can iterate through it using foreach ($reviewers as $reviewer), and within that call $reviewerSubmissionDao->getReviewerSubmissionsByReviewerId($reviewer->getUserId(), $journal->getJournalId());. You can assign the result of that to a different array (i.e. where the index equals the reviewer's ID, so it can be easily accessed in the template), and refer to that array in the template file. I know that sounds ridiculously confusing, but you'll really have to play around with these different arrays and objects to get it to work; there is no simple solution. Please let us know if you have any more specific questions.


Return to “OJS Development”

Who is online

Users browsing this forum: No registered users and 2 guests