Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[RFC][WIP] Introduce Symfony Forms #332

Closed
wants to merge 14 commits into from
Closed

Conversation

JarJak
Copy link
Member

@JarJak JarJak commented Feb 22, 2019

Let's use Symfony Forms everywhere.

Advantages:

  • CQRS security by default
  • unit testable
  • front-end and back-end validation
  • allows adding custom validation to any field
  • ability to use form themes for fields
  • allow adding more field types (by extensions?)

TODO:

  • frontend / Vue components need to follow up
  • Manual tests: Check if all fields, relations, taxonomies are saved correctly. Test if validation works as expected.
  • E2E tests won't pass until some frontend dev will fix forms in twig.

Closes #331

@bobdenotter
Copy link
Member

When the other open stuff is merged in, i'll take a closer lok at this, and see if I can help out with the "frontend" stuff as well. Neat!

@JarJak JarJak changed the base branch from feature/related-content to master February 27, 2019 15:08
@JarJak
Copy link
Member Author

JarJak commented Mar 20, 2019

Reminder: I have to rebase this PR and resolve conflicts.

@bobdenotter
Copy link
Member

bobdenotter commented Mar 22, 2019

This is the error i'm getting now, when trying to edit an existing or new record.

Schermafbeelding 2019-03-22 om 14 11 32

@bobdenotter
Copy link
Member

Getting a bit further than before now.. Currently getting this error when trying to edit any record:

Schermafbeelding 2019-03-27 om 09 07 54

@bobdenotter
Copy link
Member

@JarJak Gentle nudge.. Any progress on this PR? :-)

@JarJak
Copy link
Member Author

JarJak commented Apr 3, 2019

@bobdenotter This error might be related to ConfigParser. Looks like field definition is parsed into an invalid collection class. FieldType and DeepCollection are both collections. Can you debug it?

@bobdenotter
Copy link
Member

This error might be related to ConfigParser. Looks like field definition is parsed into an invalid collection class. FieldType and DeepCollection are both collections. Can you debug it?

My plan for this weekend was to do this refactoring for the configparser (with tests) we discussed earlier. When that's done, I'm fairly certain I can sort this one out to.
(First we need to merge #376 though.. *hint* *hint*)

@bobdenotter
Copy link
Member

This error might be related to ConfigParser. Looks like field definition is parsed into an invalid collection class. FieldType and DeepCollection are both collections. Can you debug it?

Thinking about this some more.. I quickly edited the typehints to be a general Collection, so both types would pass.

Next error is this one:

Screenshot 2019-04-05 at 07 16 21

I will keep working on cleaning up the configparsers in the meantime.

@bobdenotter bobdenotter added this to the Bolt 4 beta 2 milestone Apr 10, 2019
@bobdenotter
Copy link
Member

Bumping this to a later version. When you have time to work on this again, we can schedule it for the then-next upcoming milestone

@bobdenotter
Copy link
Member

This PR has been more than half a year ago. @JarJak , if you want to finish it, let me know what I can do to help.

@JarJak
Copy link
Member Author

JarJak commented Oct 21, 2019

@bobdenotter this PR needs a follow-up by Vue components to make them compatible with Symfony Forms templates. Please relate to https://symfony.com/doc/current/form/form_themes.html

I can fix conflicts in next week

@bobdenotter
Copy link
Member

@JarJak I don't think just fixing the conflicts is enough.. This is currently not something that somebody else can pick up and fix. It needs to actually work, before we can task someone to build upon it.

@bobdenotter bobdenotter marked this pull request as draft August 24, 2020 12:31
@bobdenotter
Copy link
Member

This PR has been lingering for two and a half years now. I think it's time to close it. 😔

@I-Valchev I-Valchev deleted the feature/symfony-forms branch November 18, 2021 15:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement Symfony Forms and Validation in backend
2 participants