Hey there,
I have a banal problem but didn't find a working solution though googling it...
I have a simple DataObject and want to make sure that people using the CMS fill every field.
class ProgramItem extends DataObject {
public static $has_one = array('AdditionalProgram' => 'AdditionalProgram');
public static $db = array('Headline' => "Varchar", 'Description' => "HTMLText", 'ArchivingDate' => "Date");
function getCMSValidator() {
return new RequiredFields(array('Headline', 'Description', 'ArchivingDate'));
}
}
I tried overwriting the getCMSValidator()-Function but it didn't work. How does it work using Silverstripe 3.1 ?
Regards,
henrik