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.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

DataObjectManager Module /

Discuss the DataObjectManager module, and the related ImageGallery module.

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

Uploadify: remove permissions


Go to End


1082 Views

Avatar
hammuh

Community Member, 15 Posts

10 February 2011 at 11:15pm

Hi UC.
I created a website with a frondend DOM, so registrated users can create en modify their objects without logging in in the CMS. The object has a 'has_many' relation with the object 'VillaImages' managed by a IDOM. If you click on an object in the IDOM there is an uploadify ImageUploadField. The problem is that people can remove the image by clicking the 'x' in de ImageUploadField and after that saving the 'VillaImage' object. Than there is an Object with just a title and no image. Is there a way to remove the delete permission in the uploas field? I tried $uploadfield->allowed_actions = array('upload', 'refresh'); But that didn't do anything. In the defaults there is no such thing as 'canDelete', so the method setVal is no option.
Do you have a solution?

Thanks in advance,
Frank van der Hammen