OJS OCS OMP OHS

You are viewing the PKP Support Forum | PKP Home Wiki



Where is the template file for list of papers?

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

Moderators: jmacgreg, michael, John

Forum rules
What to do if you have a technical problem with OCS:

1. Search the forum. You can do this from the Advanced Search Page or from our Google Custom Search, which will search the entire PKP site. If you are encountering an error, we especially recommend searching the forum for said error.

2. Check the FAQ to see if your question or error has already been resolved. Please note that this FAQ is OJS-centric, but most issues are applicable to both platforms.

3. Post a question, but please, only after trying the above two solutions. If it's a workflow or usability question you should probably post to the OCS Conference Support and Discussion subforum; if you have a development question, try the OCS Development subforum.

Where is the template file for list of papers?

Postby nahrizuladib » Tue Feb 12, 2008 1:44 pm

hi

would very much appreciate it if someone could direct me where i can find the template file for the list of papers (unassigned, in review, etc).

i need it to change the type of information displayed on the page, e.g. i'd like to display the country.

many thanks in advance.

-nahrizul
nahrizuladib
 
Posts: 19
Joined: Sat Aug 11, 2007 5:10 pm

Re: Where is the template file for list of papers?

Postby smiri » Tue Feb 12, 2008 9:38 pm

Hi There,

I assume you're using OCS 2.x. The templates you're looking for are in "templates/director/".

Regards,
smiri
 
Posts: 183
Joined: Thu Sep 06, 2007 7:01 pm

Re: Where is the template file for list of papers?

Postby nahrizuladib » Wed Feb 13, 2008 6:01 am

thanks for the prompt reply!

another thing: is there a list where i can look up all the function names and its usage e.g getTitle(), getAuthor(), etc.?

if there isn't, then could you please let me know what are the function names to print these details:
1. email of principal author
2. full name of principal author
3. country of principal author
4. full paper title (not truncated with ...)


cheers
nahrizul
nahrizuladib
 
Posts: 19
Joined: Sat Aug 11, 2007 5:10 pm

Re: Where is the template file for list of papers?

Postby smiri » Wed Feb 13, 2008 8:23 pm

Hi nahrizul,

I would suggest looking at the appropriate files to find the available functions. For example,

For Author info, take a look at this file: classes/user/User.inc.php
and for Paper info, look at: classes/paper/Paper.inc.php

Regards,
smiri
 
Posts: 183
Joined: Thu Sep 06, 2007 7:01 pm

Re: Where is the template file for list of papers?

Postby nahrizuladib » Thu Feb 14, 2008 1:23 pm

hi

thanks again for the reply. but in the classes/paper/Paper.inc.php there's only getUserId() that prints the user ID of the submitter.

is there a way to print the email, full name (first and last names), and country of the submitter?

sorry for these questions, i'm pretty much a noob with php :-P

thanks.
nahrizuladib
 
Posts: 19
Joined: Sat Aug 11, 2007 5:10 pm

Re: Where is the template file for list of papers?

Postby smiri » Thu Feb 14, 2008 3:36 pm

Hi nahrizul,

All the user info is in the User.inc.php file. there are many user functions like:

getCountry(), getEmail(), getFirstName(), getLastName() and more.

Regards,
smiri
 
Posts: 183
Joined: Thu Sep 06, 2007 7:01 pm

Re: Where is the template file for list of papers?

Postby nahrizuladib » Fri Feb 15, 2008 8:49 am

hi

thanks, but i think i don't make myself clear. i've looked up classes/paper/User.inc.php and have seen the functions. but my problem is how do i use it to print e.g. first name of the submitter for the unassigned papers list?

in templates/director/submissionsUnassigned.tpl there is a loop for printing the details:

Code: Select all
   {iterate from=submissions item=submission}
   <tr valign="top">
      <td>{$submission->getPaperId()}</td>
      <td>{$submission->getDateSubmitted()|date_format:$dateFormatTrunc}</td>
      <td>{$submission->getTrackTitle()|escape}</td>
      <td>{$submission->getPresenterString(true)|escape}</td>
      <td><a href="{url op="submission" path=$submission->getPaperId()}" class="action">{$submission->getPaperTitle()|strip_unsafe_html}</a></td>
   </tr>
   <tr>
      <td colspan="5" class="{if $submissions->eof()}end{/if}separator">&nbsp;</td>
   </tr>
{/iterate}


... and to follow your answer in the previous post, this is what i did (i added an extra line to put in getFirstName()):

Code: Select all
   {iterate from=submissions item=submission}
   <tr valign="top">
      <td>{$submission->getPaperId()}</td>
      <td>{$submission->getDateSubmitted()|date_format:$dateFormatTrunc}</td>
      <td>{$submission->getTrackTitle()|escape}</td>
      <td>{$submission->getPresenterString(true)|escape}</td>
      <td><a href="{url op="submission" path=$submission->getPaperId()}" class="action">{$submission->getPaperTitle()|strip_unsafe_html}</a></td>
      <td>{$submission->getFirstName(true)|escape}</td>
   </tr>
   <tr>
      <td colspan="5" class="{if $submissions->eof()}end{/if}separator">&nbsp;</td>
   </tr>
{/iterate}


but i got this error message instead:
Code: Select all
Fatal error: Call to undefined function: getfirstname() in C:\Domains\nahrizuladib.com\wwwroot\biomed2008\ocs-ori\cache\t_compile\%%2D^2DF^2DF52775%%submissionsUnassigned.tpl.php on line 42


let me know where i went wrong.

cheers
nahrizul
nahrizuladib
 
Posts: 19
Joined: Sat Aug 11, 2007 5:10 pm

Re: Where is the template file for list of papers?

Postby smiri » Fri Feb 15, 2008 8:29 pm

Hi nahrizul,

You can't run getFirstName() on the submission. You would first have to get an instance of the user object and then you can get its info.

So you would have to use something like the line below inside the submissions loop to get an instance of the User to work with and then use the getFirstName() function on this new user object.

{assign var="user" value=$submission->getUser()}

There's an example of this in templates/director/submissionsAccepted.tpl to get the paperId value.

Regards,
smiri
 
Posts: 183
Joined: Thu Sep 06, 2007 7:01 pm

Re: Where is the template file for list of papers?

Postby hakangulerce » Sat Dec 08, 2012 10:09 am

Hello,

I need the same help,

Here :

/director/submissions/submissionsInReview

I want to see the FULL NAME and the country of the Autgot, not only the last name. Is there anybody who will help us? Which codes should we add to the submissionsInReview.tpl

All the best and thanks a lot.
hakangulerce
 
Posts: 7
Joined: Tue Nov 13, 2012 8:28 am


Return to OCS Technical Support

Who is online

Users browsing this forum: Yahoo [Bot] and 4 guests

cron