Hi ya,
Ok got a weird one here, I'm trying to add some fields to the summary_fields list so that i can see them in Model Admin and i'm getting an 'Uncaught Exception: Unable to traverse to related object field [NiceTime] on [Course]' error.
Now the weird bit, if i upload the code and don't refresh the browser it all works fine, the moment i refresh i get the error now i'm sure my code is correct, please tell me if I'm wrong.
static $db = array(
'DateTaken' => 'Date'
);
static $summary_fields = array(
'Skill.Title' => 'Skill',
'NiceTime' => 'Date Passed',
);
public function getNiceTime() {
return $this->obj('DateTaken')->Nice();
}
This is just a simple function there is another function i want to use which calculates the expiry date of a course which also doesn't work, same error so is this a bug or am i being an idiot?
Hope someone can help, oh this is on 2.4.5.
Mick