Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hi,
Is there plans to introduce D8 version of this module?
We (@InternetDevels team) would like to help you with development of this version.
Thanks, ksis.
Comment | File | Size | Author |
---|---|---|---|
#23 | webform conditional extra lines.png | 47.34 KB | petednz |
Comments
Comment #1
Liam MorlandI would like there to be. Of course, it will depend on a D8 version of Webform. As well, there is overlap between Webform Validation and Field Validation. We've started the conversation about working together for D8 in #1890308: [meta] Work together with Webform Validation module.
Comment #2
Liam MorlandComment #3
Shawn DeArmond CreditAttribution: Shawn DeArmond as a volunteer commentedThere is now a version of Webform, based on YAML Form.
Comment #4
gusans CreditAttribution: gusans commentedhi! I'd like to know if there is any advance on this port or any alternative to have fields validation on webform 5.x
thanks in advance!
Comment #5
Liam MorlandThere has not yet been any work on this.
Comment #6
Sam152 CreditAttribution: Sam152 as a volunteer and at PreviousNext commentedI've commented on using the field_validation module here: https://www.drupal.org/project/field_validation/issues/1890308#comment-1...
I think it'd be worth investigating with a prototype to see if the entity constraints and validation system provides enough flexibility to work with all of the webform features. I suspect there would be gaps that would need to be filled which wouldn't be appropriate for a general purposes entity validation/constraints UI. At this point I do think 'webform_validation' would still be a good stand-alone project to service the use-case it had for D7.
Possibly have some capacity to help contribute to answer these questions and contribute to a port in the future.
Comment #7
Liam MorlandDuplicate of #2220971: Drupal 9 version.
Comment #8
imclean CreditAttribution: imclean commentedA duplicate of itself? Is the field_validation issue the one to follow?
Comment #9
Liam MorlandSorry, I must have confused it with something else.
Comment #10
malcomio CreditAttribution: malcomio at Capgemini commentedThis would be useful for a project I'm working on. I've made a start at https://github.com/malcomio/webform_validation, but it's in a very early state.
Comment #11
thiagogomesverissimo CreditAttribution: thiagogomesverissimo as a volunteer commentedGuys,
This module https://www.drupal.org/project/webform_extra_field_validation/ has the same idea of webform validation, but implemented in Drupal 8.
Maybe we can merge both.
What do you think?
Comment #12
Liam MorlandSure, I'd like to use existing code and bring in others who are interested in working on this.
@malcomio What is the status if your code? Does it have basic functionality? Did you look at the Drupal core/Symfony namespace Symfony\Component\Validator? Perhaps some of the classes there could be useful.
Comment #13
Liam MorlandThere are two pre-release ports of webform_validation to Drupal 8:
I would like to have a discussion about which should be the basis for the new version. How ready is your code? Perhaps each of you can look at the others' code and give your thoughts. What features does each have that the other is missing?
Comment #14
malcomio CreditAttribution: malcomio at Capgemini commentedI didn't make very much progress at all - it almost certainly makes more sense to start from https://www.drupal.org/project/webform_extra_field_validation
Comment #15
Liam MorlandI have started a 8.x-1.x branch based on the webform_extra_field_validation module by arghajit.lodh.
Comment #16
petednz CreditAttribution: petednz at Fuzion commentedso seem there are now
- webform_extra_field_validation alpha2 (22 sites at 11 March)
- webform_validation alpha1 (317 sites at 11 March)
I am not sure what the nuances are between the two or what is recommended at this point to avoid spending time assessing both?
but i guess i give this one a shot first.
thanks for everyone's time getting things this far
Comment #17
petednz CreditAttribution: petednz at Fuzion commentedI appreciate this is not the best place for this comment, but thought for other's benefit I would just document what i observed when i enabled this module. When editing an Element just below the Form Validation section there is a new section called
Form Extra Validation
- Equal Values
- Some of several
Comment #18
Liam MorlandThe current version, webform_validation 8.x-1.0-alpha3, is developed on top of webform_extra_field_validation 8.x-1.0-alpha2. Development will continue; patches welcome.
Comment #19
Liam MorlandComment #20
AdamEvertsson CreditAttribution: AdamEvertsson as a volunteer and commentedHi guys.
Awesome work on an awesome module. I (nor my clients) couldn't live without it. I'm migrating to Drupal 9 in a while (from Drupal 7) so I wonder if this module will be more than a .dev anytime soon? If not I need to find an alternative....
// Adam
Comment #21
Liam MorlandI don't expect to have much time for this for a while. Does it currently work well enough to be released?
Comment #22
Liam MorlandComment #23
petednz CreditAttribution: petednz at Fuzion commentedI think there is a major issue at this point that if you edit a webform component in the build UI (and don't select any of the extra validation because none is required) then when saved the field gets a whole bunch of additional lines like this in the source/yaml
on a big form this means a lot of extra lines that seem superfluous are added, making tweaking via Source much more painful.
I had hoped we could provide a fix for this but the person who was looking at this is no longer available so just reporting it for now. hopefully we can get some extra capacity for this soon but meanwhile wanted to report. (r26496)
Comment #24
Liam Morland@#23: Thanks for the report. It may be that the defaults need to be NULL to avoid having it store these extra values.
Comment #25
petednz CreditAttribution: petednz commentedThanks for suggestion. i will take a look
Comment #26
petednz CreditAttribution: petednz commented@liam-morland
Maybe i mis-read - do you mean 'maybe the code needs fixing to ensure that defaults have a NULL value', or 'when building your form you need to ensure you set default to be NULL'?
Comment #27
Liam MorlandI mean that something in the code may need to be changed.
Comment #28
Liam MorlandThe extra lines problem is addressed in #3265517: Extra lines added to Source when a component is added or edited even when no validation on that item.
Comment #29
Liam MorlandI have done a bunch of work on this. Testing is appreciated.
I would also welcome a patch to add automated tests. Having automated tests would speed up development. (Currently, there is only a stub test which does not actually test anything more than that that module installs.)
Comment #30
Liam MorlandAn alpha release is available. Testing of the latest development version will help move this towards full release. Further work will be tracked in the issue queue.