Validation in SiteConfig

25 views
Skip to first unread message

Patrick Nelson

unread,
Jun 30, 2015, 8:28:07 PM6/30/15
to silverst...@googlegroups.com
Is there any way to setup validation in SiteConfig? See issue here: https://github.com/silverstripe/silverstripe-cms/issues/556

I tried this myself and I noticed that the core CMS code doesn't perform any sort of validation and I can see this being very useful for other people as well. Should this be dropped into the core somehow or just done via custom extensions? Either way -- how? I'm stumped!

- Patrick

Patrick Nelson

unread,
Jul 1, 2015, 3:34:00 PM7/1/15
to silverst...@googlegroups.com
If anyone is interested, I setup this PR to fix the bug. https://github.com/silverstripe/silverstripe-cms/pull/1238

I think the issue was caused by a specific commit which was, itself, a fix to another bug. https://github.com/silverstripe/silverstripe-cms/commit/b74178e7fd2a0ba2b08cd11b41f0085b1dd4eee6

Basically, standard form validation will return content for just the form itself (via "CurrentForm" JSON field, a fragment of the page) but that is replacing the entire "Content" fragment instead of just the form.
Reply all
Reply to author
Forward
0 new messages