Rebuild form configuration and new options

Created on 25 November 2022, almost 2 years ago
Updated 14 March 2023, over 1 year ago

Problem/Motivation

  • Several problems have been detected when saving and rendering the form.
  • Missing required options, like hide the submit/reset button on different regions.
  • Missing js and template to make Exposed Form Region standalone

After this contribution, we hope that the form works as it should.

Steps to reproduce

  • Create view and add some exposed filters
  • Change exposed form type to Exposed Form Region
  • Configure regions as you want
  • Change some filter identifier and try to relocate form elements to some region.
  • Also, you can try to remove some form element from some region, it won't work, it only saves if new element is added, not removed.
  • This also affects the rendering of the form, it doesn't remove the form element with different filter identifier, so the form element will be quadriplicated (as 4 regions)

Proposed resolution

Fix some issues from code. The form and rendering was using $filter->field instead instead of $filter->identifier.

In addition to fixing these issues, we have implemented new options to exposed form region configuration
We rebuild the form configuration in 4 details (1 per each region) that contains these new options:

  • Layout of view sections
  • Hide submit button
  • Hide reset button
  • Enable autosubmit
  • Include region form elements in the global form submit
📌 Task
Status

Fixed

Version

2.0

Component

Code

Created by

Live updates comments and jobs are added and updated live.
  • views

    Involves, uses, or integrates with views. In Drupal 8 core, use the “VDC” tag instead.

Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024