-
Notifications
You must be signed in to change notification settings - Fork 53
Cannot Save (without publishing) when archetype contains errors #151
Comments
Are you wanting the Archetype to save if invalid? Just not publish? I'm not sure that will be possible. |
At the moment all validation is performed client side. That does have the
|
@kjac well put. I think the status quo will have to persist. |
I think this is a fairly major issue - the ability to save "Work in progress" content has been available in all versions of Umbraco. How do the built-in property editors allow the save to complete with validation failures? Is it because they have server side validation registered? If issue U4-4782 is the blocker for this, can anyone affected by this vote for that issue please? |
@abriggs-eduserv To summarize what I think your issue is trying to state, you'd like to be able to save a document even if validation fails. I just created a document with a MNTP with max nodes of 2 (like your OP). I am unable to save a non-Archetype document as 'work in progress' with your example. From my tests Archetype works just like core properties when it comes to validation. Both the MNTP and Archetype prevent saving or save/publish if validation fails. I would suggest you create an Umbraco core issue if you'd like different behavior. I am unaware of any server-side validation that occurs in Umbraco 7. |
Thanks for looking into this Kevin - I had only tested this with a required "Umbraco.MediaPicker" property. You can leave this empty and the node is saved which was the behavior I was expecting so I didn't investigate any further - the validation message does come from the server in this scenario I look at the behavior of some more of the built-in property editors later in the week. Cheers, |
Hey ... whoa my email reply from the lousy hotel WiFi actually made it here, cool :) Just to clarify... it's indeed U4-4782 that's causing the duplicate content, whenever server side validation fails. Due to the potentially complex nature of an Archetype, the probability of server side validation errors must be considered higher than for normal property editors. Thus, as long as this issue has not been resolved, the probability of Archetype being the initial cause for duplicate content must be considered equally higher. In my opinion we shouldn't consider implementing server side validations until U4-4782 has been solved. As for the general mess of server/client side validation... if you take a simple text string property editor (the built-in one) and make it mandatory, the validation is performed client side - you can't save the document unless you enter something. However, regex validation of the same field is done server side. Go figure. As @abriggs-eduserv correctly states, this has the effect that you can save an invalid draft of a document. Personally I like the ability to save draft versions, if nothing else then to provide the editors with that flexibility. It's also somewhat of a rewrite to implement (partial) server side validation, but on the upside, server side validation might give us more options to write custom validations for specific property editors as the need arises. |
This is kind of annoying, I'm trying to save a new Node without all the data and I just can't. |
@kipusoep Could you set your Archetype to start with no nodes at all? Config->Check |
I have a fix that depends on a core PR: umbraco/Umbraco-CMS#949 |
Hi,
Archetype appears to be preventing Umbraco from saving changes when a field in the archetype has failed validation.
E.g. you cannot save a work-in-progress page unless you complete all the mandatory fields within an archetype.
The behavior is the same if it's built-in validation (required field) or property editor specific validation (e.g. max nodes in a MNTP)
I'm on Umbraco 7.1.4 with Archetype v1.2.1-beta.
Thanks,
The text was updated successfully, but these errors were encountered: