function getDefaultData() { $cats = TestCategory::get(); if (!$cats->Count()) { return array(); } // not initialized yet $firstCat = $cats->offsetGet(0); $thirdCat = $cats->offsetGet(2); return array('Readonly' => 'My value (ä!)', 'Textarea' => 'My value (ä!)', 'Required' => 'My required value (delete to test)', 'Validated' => '1', 'Text' => 'My value (ä!)', 'Textarea' => 'My value (ä!)', 'HTMLField' => 'My value (ä!)', 'Email' => '*****@*****.**', 'Password' => 'My value (ä!)', 'Number' => 99, 'Price' => 99.98999999999999, 'MoneyAmount' => 99.98999999999999, 'MoneyCurrency' => 'EUR', 'PhoneNumber' => '021 1235', 'CreditCard' => '4000400040004111', 'Checkbox' => 1, 'CheckboxSetID' => $firstCat->ID, 'DropdownID' => $firstCat->ID, 'GroupedDropdownID' => $firstCat->ID, 'ListboxFieldID' => $firstCat->ID, 'MultipleListboxFieldID' => join(',', array($thirdCat->ID, $firstCat->ID)), 'OptionSet' => join(',', array($thirdCat->ID, $firstCat->ID)), 'Date' => "2002-10-23", 'CalendarDate' => "2002-10-23", 'DMYDate' => "2002-10-23", 'Time' => "23:59", 'TimeWithDropdown' => "23:59", 'DateTime' => "2002-10-23 23:59", 'DateTimeWithCalendar' => "2002-10-23 23:59"); }