OJS OCS OMP OHS

You are viewing the PKP Support Forum | PKP Home Wiki



Bug in viewPayment.tpl

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.

Bug in viewPayment.tpl

Postby springday » Sat Oct 27, 2012 3:55 am

Hello PKP team,

I think I've encountered a bug in /templates/payments/viewPayment.tpl. There's a call to an undefined function OJSCompletedPayment::getUsername() in lines 38 to 40:

Code: Select all
<a class="action" href="{url op="userProfile" path=$payment->getUserId()}">{$payment->getUsername()|escape}</a>
         {else}
            {$payment->getUsername()|escape}


I couldn neither find this function in /classes/payment/ojs/OJSCompletedPayment.inc.php nor in /lib/pkp/classes/payment/Payment.inc.php.

Regards,
Kai
springday
 
Posts: 111
Joined: Wed Jul 25, 2012 2:56 pm
Location: Munich, Germany

Re: Bug in viewPayment.tpl

Postby JasonNugent » Sat Oct 27, 2012 2:11 pm

Hi Kai,

Which version of OJS are you using? I had found this and committed a fix for it about a month ago, as http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=7933

There are links to commits for OJS master and also OJS 2.4.
JasonNugent
Site Admin
 
Posts: 910
Joined: Tue Jan 10, 2006 6:20 am

Re: Bug in viewPayment.tpl

Postby springday » Sat Oct 27, 2012 3:05 pm

Hi Jason,

well, I thought I was using OJS 2.4.1, but as I have quite a few modifications in the code, so I have to manually work on the parts where the patch fails. Therefore it could be that I have missed something. I'll check that. Thanks for pointing me to the bugfix.

Regards,
Kai
springday
 
Posts: 111
Joined: Wed Jul 25, 2012 2:56 pm
Location: Munich, Germany

Re: Bug in viewPayment.tpl

Postby springday » Sat Oct 27, 2012 3:18 pm

Hi again, Jason,

your patch only works on the template "viewPayments.tpl", my report referred to "viewPayment.tpl". The calls to $payment->getUsername() and $payment->getUserId() still survived in the singular payment template, even in OJS 2.4.1.

Regards,
Kai
springday
 
Posts: 111
Joined: Wed Jul 25, 2012 2:56 pm
Location: Munich, Germany

Re: Bug in viewPayment.tpl

Postby JasonNugent » Sat Oct 27, 2012 4:10 pm

Ah, cool. I will fix that up.

Cheers,
Jason
JasonNugent
Site Admin
 
Posts: 910
Joined: Tue Jan 10, 2006 6:20 am


Return to OJS Technical Support

Who is online

Users browsing this forum: Bing [Bot], Yahoo [Bot] and 3 guests