View more context

 

Ginnie Hench

so for the validation - I looked at the API for SilverStripe\ORM\ValidationResult - I was hoping there might be a removeError method but no

Ginnie Hench

I've used Injector to create class CustomSlideImage extends SlideImage but my validate function is not sufficient to remove the error added by SlideImage

Ginnie Hench

I'm thinking I'm better off forking the module repo and customizing it to suit what we need

wmk

sounds like that. A "Slide" Interface would be good for generating the slides, then you can add it to different dataobjects

Ginnie Hench

hmm, I'm not sure what you mean exactly, but unfortunately I gotta drive somewhere now - thanks for helping me rule out what I was trying to do

andante

SlideInterface would have like a getBody() method for example, so your TextSlide implements SlideInterface, and the getBody() method would return the text, but with an ImageSlide it would return the image