I get this error when trying to save a DataObject with a many_many. Error at line 92 of /home/pnew/public_html/test/framework/model/ManyManyList.php
I can view the Personnel Dataobject and am able to list out the different Departments as check boxes but if I try to save with a checkbox checked I get the error, if I do not try to select a checkbox it will save just fine.
My Code:
Personnel.php
class Personnel extends DataObject{
public static $db = array(
'Salutation' => 'Varchar(5)',
'FirstName' => 'Varchar(50)',
'LastName' => 'Varchar(50)',
'Campus' => 'Varchar(255)',
'College' => 'Varchar(255)',
'School' => 'Varchar(255)',
'WebTitle' => 'Varchar(255)',
'Phone' => 'Varchar(15)',
'BoxNumber' => 'Varchar(6)',
'EmailAddress' => 'Varchar(255)',
'Description' => 'HTMLText',
);
public static $has_one = array(
'Photo' => 'Image',
);
public static $many_many = array(
'Department' => 'Department',
);
...
}
Department.php
class Department extends DataObject{
public static $db = array(
'Name' => 'Varchar(50)',
'AboutDepartment' => 'HTMLText',
'Active' => 'Enum(array("Active","Disabled"))',
);
public static $has_one = array(
'ParentSchool' => 'School',
);
public static $belongs_many_many = array(
'Personnel' => 'Personnel',
);
...
}