FORM : Views Entity Form Field

Created on 3 October 2024, 3 months ago

Problem/Motivation

I am using following module a lot views_entity_form_field β†’

Using this module you can create a drupal VIEW but instead of the standard fields you can use "form" fields which means you are able to update fields directly in view using "Save" button as follow:

However that save button is a different one: instead of standard id "edit-submit" it uses id element : "edit-actions-submit"

And instead of entity type like : node, taxonomy etc , this one uses views.

The main problem is that it seems validation does not work for such views forms. I have used following guide :
ECA content_validation
which works fine for me for standards edit pages, however I am unable to make it for for such "view" pages.

I am not sure what needs to be added to validate form as restriction. I have tried id of the form, id of view, or keep all restrictions disabled, however still once I setup ECA validation and try to save that views form it does not verify it and save normally. When I use the same with the standard content type edit - it does work.

Can anyone try ECA with this awesome " views_entity_form_field β†’ " field and determine what is preventing to validate such view page form ?

πŸ’¬ Support request
Status

Active

Version

2.1

Component

Documentation

Created by

πŸ‡ΈπŸ‡°Slovakia coaston

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @coaston
  • πŸ‡ΈπŸ‡°Slovakia coaston

    Note: Once I enabled debug, I can see error : Access denied to Build node from submitted values (Activity_0lyc17w) from ECA Validation so basically it fails at the begging, but why such access is denied?

  • πŸ‡ΈπŸ‡°Slovakia coaston

    It looks like the form in views with this module "views_entity_form_field" is being built , so no need to build it again.

    Now I am getting issue to get the current nid. My url of view is "/form-field-verification-test/3651"
    Everything works fine as expected with this form now when I add "Entity:Load" and configure : Load entity form : TYPE and ID and Entity type is Content and entityID =3651

    Of course this one works because there is exact ID. When I change Load entity form to "Current scope" I am unable to get ID, which is logical i guess, however my question is : How can I get the current node id when using form?

    I am trying to use parameter from URL, but I am not sure how to configure it in views. When i tried anything like :"/form-field-verification-test/myparemeter=3651" the view was not displayed :(

    So I believe once I can get the ID from URL I will be able to complete my task...

    Any help here?

  • πŸ‡©πŸ‡ͺGermany jurgenhaas Gottmadingen

    Access denied to Build node from submitted values (Activity_0lyc17w) from ECA Validation

    This error indicates that you're using the "Build entity from form" action plugin which most certainly can't be used with that other module, because that doesn't provide an entity form, it provides a form with data from many entities. Therefore, this action can not be executed,

    My question is > Is there possibility to add token to "Restrict by form ID" of Validate form ?

    In event configuration, you can't use tokens, because no tokens exist yet at that point.

    Or at least to allow * in so I can use "views-form-vform-field-verification-test-page-1-*" ?

    That's not possible, but you can leave that field blank so that the event applies to all forms, and then you can add a condition afterwards to verify the form id against any sort of patterns you can think of.

  • πŸ‡ΈπŸ‡°Slovakia coaston

    Thank You,

    I am using this views_entity_form_field because of BULK updates of content types.

    So I am experiencing now different type of issue. I wanted to use QUERY:Views to get nid of all nodes so system (ECA) can validate them one by one.
    - It works and do validation, however I am unable to click save button even I have changed/add required values because every time when there is a new loop - it will take another one will determine still the old value (empty field) and system things it is still empty even I am trying to change/add value so cannot get rid of verification error message once everything should be OK.

    Looks like that :form build is missing here and I won't be able to continue.

  • πŸ‡©πŸ‡ͺGermany jurgenhaas Gottmadingen

    Unfortunately, I don't know that other module and have no idea how that works and what context it creates, which may be important to how the ECA model would have to be built. You may have to debug that on your own to see what's causing the problem.

  • πŸ‡ΈπŸ‡°Slovakia coaston

    Well now I know the reason. It

    I am trying to change/add value so cannot get rid of verification error message once everything should be OK.

    It is not Ok ,because the Form could not be build correctly because of 15818966 πŸ› Illegal offset type Active issue, so now I can try to work on that issue again.

  • Status changed to Postponed: needs info 14 days ago
  • πŸ‡©πŸ‡ͺGermany jurgenhaas Gottmadingen

    What's the status on this one?

Production build 0.71.5 2024