Skip to content
This repository has been archived by the owner on Dec 13, 2021. It is now read-only.

Validation on mandatory fields #21

Open
leekelleher opened this issue Mar 26, 2018 · 6 comments
Open

Validation on mandatory fields #21

leekelleher opened this issue Mar 26, 2018 · 6 comments
Labels
rfc Request for Comment

Comments

@leekelleher
Copy link
Contributor

Let's explore if we can have cursory validation on mandatory fields within Inner Content.

This would only be for client-side validation - server-side would open a can-of-worms!

@leekelleher leekelleher added the rfc Request for Comment label Mar 26, 2018
@leekelleher
Copy link
Contributor Author

@mattbrailsford I've spent a few hours investigating how this would work, but I can't figure out how to trigger the validation on the submit event. Any ideas would be appreciated - no rush though.

@markadrake
Copy link

Hi @leekelleher and @mattbrailsford - any progress on adding validation to inner content? Or any knowledge you have to share about how Umbraco's default editor validates the models? All the best!

@leekelleher
Copy link
Contributor Author

@markadrake In all honestly, I wasn't able to figure out how to do it. I couldn't see where Umbraco was triggering the client-side validation - which I wanted to trigger when the overlay panel was closed (or the "Done" button was pressed).

At this point, I'm open to any suggestions! 😃

@markadrake
Copy link

markadrake commented Oct 9, 2018

@leekelleher is it me or has something changed in Umbraco v7.12.3?

image

image

Just a quick test tonight. But above I set a textbox to required and it validated all by itself.

Looks like the media picker doesn't have client-side validation (it doesn't as a regular content node either this actually validates on the POST).

I could have sworn just days ago this didn't work.

@leekelleher
Copy link
Contributor Author

Interesting! I'm pretty sure that this didn't work previously too.

I'm hoping to get chance to look at this again, at this weekend's CodeCabin!

@markadrake
Copy link

In the meantime, I'm going to open up a discussion on the forums about adding client side validation to the media picker. But my first couple of tests looks like something's been released to run validation automatically. High five! haha

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
rfc Request for Comment
Development

No branches or pull requests

2 participants