Open EneldoDev opened 3 years ago
Hey @EneldoDev
Thanks for reporting this. I'll try to reproduce and let you know how we'll progress once I have :)
Emma
Hey @EneldoDev
Yep - I have exactly this problem on both 8.11.0 and later releases. We'll label this up for grabs so someone can fix it 😁 Of course, you're very welcome to submit a pr if you have the inclination.
Emma
Hi @EneldoDev,
We're writing to let you know that we would love some help with this issue. We feel that this issue is ideal to flag for a community member to work on it. Once flagged here, folk looking for issues to work on will know to look at yours. Of course, please feel free work on this yourself ;-). If there are any changes to this status, we'll be sure to let you know.
For more information about issues and states, have a look at this blog post
Thanks muchly, from your friendly Umbraco GitHub bot :-)
For the person picking up this issue - please also look at #9727 The numeric prop editor exhibits the same behaviour
Emma
Not specific fixing this issue, but related to the integer/numeric datatype validation if a step size has been set: https://github.com/umbraco/Umbraco-CMS/pull/10039
@Shazwazza maybe you have an idea why an invalid value doesn't prevent the form from being submitted. In case the format is invalid the value isn't saved though, but I would expect an notification error and/or highlight of the invalid property. Nore sure if the worked previous if the value was invalid and the property wasn't mandatory.
I stumbled upon this as well in v9.0.1 and v9.2.0. It looks like the Mandatory Validation will prevent both save and publish when the data is missing, but the Custom Validation by regex will allow the data to be saved but not published. The behavior of the two types of validation are inconsistent. Both display all the right messages to the content editor, but that almost makes it even more confusing when they don't behave consistently.
See my closed todo here for how I described the problem: https://github.com/umbraco/Umbraco-CMS/issues/11884
I closed out my issue already because I realized after creating it that it was a duplicate of this issue.
I missed a bunch of recent comments, I'm checking to see to what extent this is still an issue and if there's anything left that needs to be fixed.
There was an intentional change to allow invalid content to be saved but not published, so users could save progress with validation errors: https://github.com/umbraco/Umbraco-CMS/pull/9691 so it seems like the bug is just that validation errors don't prevent publishing, not that they don't prevent saving.
Going to take a stab at fixing this. It looks like there's still an issue at least with inline block lists. For whatever reason, maybe because there's an update missing, my local version of Umbraco-CMS will catch maxChars errors on a textbox if the parent block is open, but not when it's closed. And my version for another project won't catch it even when it's open, unless there's also a server-side error present.
Jumping in here to say that this is still an issue in later versions too, I can reproduce this on V10 😁 A good point here is brought up by @eden-jh that there was an intentional change to allow invalid content to be saved, so I will pass this by the front-end team for a decision on how we should go about this issue.
Alright following up here: so you should still be able to save (even with an invalid email) but it should not delete the value you put in there, nor should you be able to publish with an invalid value 👍
Still not fixed in v13? Seems to affect all property validation?
When editing content node with property using Email address property editor, frontend email validation doesn't block postback when email is provided in wrong format.
Umbraco version
I am seeing this issue on Umbraco version: 8.11.0
Reproduction
Steps to reproduce
Expected result
Invalid email error message is shown and postback on save is blocked. No page reload.
Actual result
Once Save/Save and publish button is clicked validation message "Invalid email" is shown but form postback isn't blocked. Content node is saved, page reloaded. Email address field is empty though what means backend validation works correctly.
Validation is working properly only when "Field is mandatory" checkbox is checked.