Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

DataObjectManager Module

Discuss the DataObjectManager module, and the related ImageGallery module.

Moderators: martimiz, UncleCheese, Sean, biapar, Willr, Ingo, swaiba, simon_w

New Features


Go to End
Reply

35 Posts   12784 Views

Avatar
UncleCheese

12 June 2009 at 3:58am (Last edited: 12 June 2009 3:59am), 4085 Posts

Subscribe to this thread to receive notifications about new features for DataObjectManager, ImageGallery, and SWFUpload.

Avatar
UncleCheese

12 June 2009 at 4:02am 4085 Posts

Just checked in:

SWFUploadField: Now has speed calculation and countdown timer for uploads once five seconds have elapsed.

FileDataObjectManager: Now disables imports for file types that are not allowed.

DataObjectManager: Now has a "deselect all" option for HasOne/HasMany managers. This is especially useful for the HasOne manager, since it allows you to set a null value by clearing the radio buttons.

Avatar
UncleCheese

26 June 2009 at 7:30am (Last edited: 26 June 2009 7:30am), 4085 Posts

Just Checked In:

AssetManager: Allows management of files directly to a page. No need to go through a dataobject. Usage:

$field->addFieldsToTab("Root.Content.Files", new AssetManager($this,"Files","MyFileClass"));

Where "Files" is the name of the file relation, and MyFileClass is the subclass of File that has a $has_one relationship with your page. If you want to use the File class directly, it would require modifying the File class to have that has_one relation, which requires a decorator. Still possible, though. If you choose to do if that way, the third argument defaults to "File" so all you need is:

new AssetManager($this,"Files");

AssetAdmin Support:

Because we can now manage files directly, it is now possible to use the AssetManager in the AssetAdmin interface. By default, this is turned on in the latest version of DataObjectManager in dataobject_manager/_config.php. Just set true/false with:

DataObjectManager::allow_assets_override($bool);

CSS Overrides

Not much to speak of here, but over time I'm going to be making updates to some of the weaker points of the Silverstripe core stylesheet. These updates will come in through dataobjectmanager_override.css. By default these overrides are turned off, but can be enabled in the config file.

DataObjectManager::allow_css_override(true);

Marking Permissions

For relation DataObjectManagers, you can now set the permissions required to alter the checked state of each item. Usage:

$my_relation_dataobjectmanager->setMarkingPermission("CMS_ACCESS_CMSMain");

By default, there are no permission restrictions on altering relations.

Avatar
UncleCheese

16 July 2009 at 9:28am 4085 Posts

Just Checked In:

SimpleWysiwygField

I would like this to eventually replace SimpleHTMLEditorField. It uses the HTMLbox jQuery plugin, and I've found it incredibly easy to use. Check out the docs here:

http://doc.silverstripe.com/doku.php?id=simplewysiwygfield

Avatar
UncleCheese

17 August 2009 at 9:16am (Last edited: 17 August 2009 12:32pm), 4085 Posts

Just Checked In:

Nested DataObjectManager support

Still in testing. Manages relationships between two dataobjects, allowing DOMs to be used in DOM popups! Check out the video!

http://www.youtube.com/watch?v=eeXOTlXFmQQ

SimpleTinyMCEField

A jQuery based, lightweight version of TinyMCE to use in your DOM popups. Make it as complex or simple as you want using static methods for global settings or their instance-level counterparts for instance-based configuration, e.g.

To affect all SimpleTinyMCEFields, enter in _config.php:

SimpleTinyMCEField::set_default_buttons(array(
'cut,paste,|,undo,code',
'bold,italic,underline,|,justifyleft,justifyright'
));

To affect just one SimpleTinyMCEField:

$myfield = new SimpleTinyMCEField('ContentField','Content Label');
$myfield->setButtons(array(
'cut,paste,|,undo,code',
'bold,italic,underline,|,justifyleft,justifyright'
));

More docs to come!

Avatar
UncleCheese

25 August 2009 at 6:33am 4085 Posts

DatePickerField now works in the CMS just like a CalendarDateField. For MDY date formats, use DatePickerField::set_date_format('mdy') in your _config.php.

Avatar
dospuntocero

8 September 2009 at 4:18am Community Member, 54 Posts

do you know how to disable the validation on a DatePickerField?? it keeps telling me : Please enter a valid date format (DD/MM/YYYY).

thanks

Avatar
UncleCheese

8 September 2009 at 7:12am 4085 Posts

Never had this happen before. Can you replicate on the demo site? http://dataobjectmanager.carlinowebdesign.com

All my page types have a date field for testing purposes.

Go to Top