Hi folks,
I have an action class where i try to get the amount of left credits.
so i'll try to make a function for that in the CreditsPeer.php file
which is generated by propel. I call this function with this: "$this-
>creditsLeft = CreditsPeer::getLeftCredits();"
that function looks like this:
public function getLeftCredits()
{
$c = new Criteria();
$c->addAlias('SUM('.self::AMOUNT.')', 'total');
$c->add(self::USER_ID, $this->getUser()->getMemberId());
$c->addGroupByColumn(CreditsPeer::USER_ID);
$credits = self::doSelectOne($c);
var_dump($credits);
return $credits;
}
And here is my problem, as you see I try to access the sfUser to call
an own written function from the self written file myUser.class.php in
the lib folder which looks like this:
class myUser extends sfBasicSecurityUser
{
public function getMemberId()
{
return 1; # later will be a bit more of code..
}
}
now finaly I get these two error:
- a strict standard (yeah logical, but how can I resolf this?)
- a symfony error called "Call to undefined method
sfUser::getMemberId"
what can I do?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"symfony users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/symfony-users?hl=en
-~----------~----~----~----~------~----~------~--~---