spicywebau / craft-neo

A Matrix-like field type for Craft CMS that uses existing fields
Other
403 stars 63 forks source link

Getting this message "Entries can only be created after the Neo block has been saved." if autoSaveDrafts is false #903

Closed ayush000 closed 4 days ago

ayush000 commented 1 week ago

Bug Description

If I try to add a neo block to a new entry, all matrix fields within that neo block cannot be added unless a draft is saved first. In craft-neo 5.0.1, it was possible to populate matrix fields within neo block without needing to save a draft (unless there was some error in the form). But something changed in later versions. In 5.0.4, it's not possible to populate matrix fields nested within neo block. If it's a required field, there is no way to create an entry without saving a draft first image

Once I save a draft, I'm able to create matrix within neo block. image

Steps to reproduce

  1. Set autoSaveDrafts to false in CMS config
  2. Create a new entry
  3. Add a neo block that contains a matrix field
  4. The matrix field shows this message "Entries can only be created after the Neo block has been saved."

Expected behaviour

I should be able to create matrix fields within neo blocks without having to save a draft.

Neo version

5.0.4

Craft CMS version

5.2.0

What is the affected Neo field's propagation method?

No response

Does this issue involve templating, and if so, is eager-loading used?

This is not a templating issue

ttempleton commented 4 days ago

Thanks for reporting that - fixed now in 5.0.5.