File Browsing for Editors

Are you responsible for making OJS work -- installing, upgrading, migrating or troubleshooting? Do you think you've found a bug? Post in this forum.

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

Forum rules
The Public Knowledge Project Support Forum is moving to http://forum.pkp.sfu.ca

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.
JZief
Posts: 11
Joined: Wed Dec 06, 2006 1:38 pm
Contact:

File Browsing for Editors

Postby JZief » Wed Dec 13, 2006 12:42 pm

Hello,

Is there any way to allow an editor of a journal to use the file browsing features that the journal manager can do? The editors of our journal will be dealing with documents relating to submitted articles and reviews that should not be available to authors or reviewers - so a convenient way to store them would be to create subfolders using the File Browser.

Or is there another way to accomplish this?

Thanks,

Joel

asmecher
Posts: 10015
Joined: Wed Aug 10, 2005 12:56 pm
Contact:

Postby asmecher » Wed Dec 13, 2006 12:55 pm

Hi Joel,

Have you considered granting your editors Journal Manager access? This would be the easiest way, as it doesn't require modifying OJS. Otherwise, I can suggest a few code changes, although you'll need PHP experience.

Regards,
Alec Smecher
Open Journal Systems Team
---
Don't miss the First International PKP Scholarly Publishing Conference
July 11 - 13, 2007, Vancouver, BC, Canada
http://ocs.sfu.ca/pkp2007/

JZief
Posts: 11
Joined: Wed Dec 06, 2006 1:38 pm
Contact:

Postby JZief » Wed Dec 13, 2006 1:07 pm

Alec,

Do you mean to make the editors also journal managers? I don't think that the journal managers would like that. My PHP skills are ok - I would appreciate your code change suggestions .

Thanks,
Joel

asmecher
Posts: 10015
Joined: Wed Aug 10, 2005 12:56 pm
Contact:

Postby asmecher » Wed Dec 13, 2006 1:51 pm

Hi Joel,

OK, here's what I'd suggest:
  • In pages/manager/FilesHandler.inc.php, change all calls to parent::validate() to FilesHandler::validate().
  • Add a new function to FilesHandler:

    Code: Select all

            function validate() {
                    parent::validate();
                    $journal =& Request::getJournal();
                    if (!$journal || (!Validation::isJournalManager() && !Validation::isSiteAdmin() && !Validation::isEditor())) {
                            Validation::redirectLogin();
                    }
            }
  • Add a new link to the Editor's index.tpl page (in templates/editor/index.tpl):

    Code: Select all

    <li>» <a href="{url page="manager" op="files"}">{translate key="manager.filesBrowser"}</a></li>
This hasn't been tested but should work.

Regards,
Alec Smecher
Open Journal Systems Team
---
Don't miss the First International PKP Scholarly Publishing Conference
July 11 - 13, 2007, Vancouver, BC, Canada
http://ocs.sfu.ca/pkp2007/

JZief
Posts: 11
Joined: Wed Dec 06, 2006 1:38 pm
Contact:

Postby JZief » Thu Dec 14, 2006 10:42 am

Alec,

Thanks for the code. I will implement it.

Joel


Return to “OJS Technical Support”

Who is online

Users browsing this forum: Google [Bot] and 3 guests