I have a 3.1 site that for the last year has been fine and now has started throwing a 'Not found' error when I try to save a particular Dataobject through Model Admin.
To try to resolve this I have updated the site to 3.1.8 this morning,but still no luck.
The Dataobject's code is:
class Instructor extends DataObject {
public static $db = array (
'Name' => 'Text',
'Initials' => 'Text',
'Qualifications' => 'Text',
'Background' => 'HTMLText',
'Active' => 'Int',
'SortOrder' => 'Int'
);
public static $has_one = array(
'Image' => 'Image'
);
public static $summary_fields = array(
'Name' => 'Name',
'ActiveNice' => 'Show on website?'
);
public function ActiveNice() {
return $this->Active ? 'Yes' : 'No';
}
function getCMSFields(){
$fields = new FieldList();
$fields->push(new CheckboxField('Active', 'Show this instructor on website?'));
$fields->push(new TextField('Name'));
$fields->push(new TextField('Initials', 'Initials for timetable page'));
$fields->push(new TextField('Qualifications'));
$fields->push(new UploadField('Image', 'Image'));
$fields->push(new HTMLEditorField('Background', 'Experience & Background'));
return $fields;
}
}
I have also tried removing the image field altogether but that has not worked either.
Hoping someone has come across this before and can help me out.
/****UPDATE****/
I have just tried attaching the dataobject to a page with a gridfield and they work fine. Not sure what is going on