This is a sub-issue of #1910606: Improve the configurations schemas for Views significantly.

Problem/motivation

#1866610: Introduce Kwalify-inspired schema format for configuration introduced some config schema coverage for views and #1910606: Improve the configurations schemas for Views significantly extended it, but it is not complete. The changelog leads to (hopefully extensive) documentation on the format at http://drupal.org/node/1905070. While there are little cleanups planned for the format overall, the current format is a result of months of back and forths, so it should be perfectly fine to apply it more widely to core.

Proposed solution

Figure out the missing pieces that are not yet covered. Write schema file sections for them. Clean up / fix any issues in current schema.

Create a configuration schema for missing view filters plugins

Schema in place
Please refer core/modules/views/config/schema/views.filters.schema.yml
BooleanOperator.php
BooleanOperatorString.php
Broken.php
Bundle.php
Combine.php
Date.php
InOperator.php
String.php
Numeric.php
Equality.php
ManyToOne.php

Schema not yet in place
GroupByNumeric.php
Standard.php

Steps to review

Check Steps to check on meta.

Files: 
CommentFileSizeAuthor
#14 2019085-diff-5-14.txt537 bytesvijaycs85
#14 2019085-config-schema-views-filter-14.patch1.09 KBvijaycs85
PASSED: [[SimpleTest]]: [MySQL] 59,294 pass(es). View
#11 2019085-config-schema-views-filter-11.patch860 bytesvijaycs85
PASSED: [[SimpleTest]]: [MySQL] 57,615 pass(es). View
#11 2019085-diff-3-11.txt673 bytesvijaycs85
#5 2019085-config-schema-views-filter-3.patch472 bytesSharique
PASSED: [[SimpleTest]]: [MySQL] 56,459 pass(es). View
#3 2019085-config-schema-views-filter-2.patch589 bytesneetu morwani
PASSED: [[SimpleTest]]: [MySQL] 56,900 pass(es). View
#1 2019085-config-schema-views-filter-1.patch0 bytesneetu morwani
PASSED: [[SimpleTest]]: [MySQL] 56,274 pass(es). View

Comments

neetu morwani’s picture

Status: Active » Needs review
FileSize
0 bytes
PASSED: [[SimpleTest]]: [MySQL] 56,274 pass(es). View

Issuing initial patch for remaining filter types..

neetu morwani’s picture

Issuing initial patch for remaining filter types..

neetu morwani’s picture

FileSize
589 bytes
PASSED: [[SimpleTest]]: [MySQL] 56,900 pass(es). View

Issuing initial patch for remaining filter types(REVISED)..

aspilicious’s picture

+++ b/core/modules/views/config/schema/views.filter.schema.ymlundefined
@@ -118,3 +118,7 @@ views.filter.group_items.string:
diff --git a/sites/default/default.settings.php b/sites/default/default.settings.php

diff --git a/sites/default/default.settings.php b/sites/default/default.settings.php
old mode 100644

You should remove the settings.php part out of your patch

Sharique’s picture

FileSize
472 bytes
PASSED: [[SimpleTest]]: [MySQL] 56,459 pass(es). View

Here is corrected patch.

Status: Needs review » Needs work
Issue tags: -Configuration system, -D8MI, -language-config, -VDC, -Configuration schema, -views configuration schema

The last submitted patch, 2019085-config-schema-views-filter-3.patch, failed testing.

aspilicious’s picture

Status: Needs work » Needs review
Issue tags: +Configuration system, +D8MI, +language-config, +VDC, +Configuration schema, +views configuration schema
vijaycs85’s picture

Status: Needs review » Reviewed & tested by the community

As GroupByNumeric is not a filter and standard doesn't have any additional field, patch in #5 seems the complete patch for this issue. Looks good to me.

YesCT’s picture

Issue tags: +RTBC July 1

This issue was RTBC and passing tests on July 1, the beginning of API freeze.

alexpott’s picture

Status: Reviewed & tested by the community » Needs work

There is a GroupByNumeric filter afaics... see core/modules/views/lib/Drupal/views/Plugin/views/filter/GroupByNumeric.php

Considering the issue title I think we should also fix the incorrect labels in views.filter.schema.yml...

views.filter.bundle:
  type: views.filter.in_operator
  label: 'Broken'
views.filter.equality:
  type: views.filter.numeric
  label: 'Broken'
vijaycs85’s picture

Status: Needs work » Needs review
Issue tags: +LONDON_2013_JULY
FileSize
673 bytes
860 bytes
PASSED: [[SimpleTest]]: [MySQL] 57,615 pass(es). View

@alexpott, GroupByNumeric is more operation than filter. we checked and found nothing can be added for it. Updated label in this patch...

mtift’s picture

Status: Needs review » Reviewed & tested by the community

This one looks good to me.

alexpott’s picture

Status: Reviewed & tested by the community » Needs work

@vijaycs I'm not sure what you mean by " GroupByNumeric is more operation than filter." - it extends the numeric filter so it is configurable, can do everything that can do and more.

vijaycs85’s picture

Issue summary: View changes

Updated issue summary.

vijaycs85’s picture

Issue summary: View changes
Status: Needs work » Needs review
Issue tags: +LONDON_2013_DECEMBER
FileSize
1.09 KB
PASSED: [[SimpleTest]]: [MySQL] 59,294 pass(es). View
537 bytes
dawehner’s picture

Status: Needs review » Reviewed & tested by the community
+++ b/core/modules/views/config/schema/views.filter.schema.yml
@@ -30,6 +30,10 @@ views.filter.date:
+  type: views.filter.numeric
+  label: 'Group by numeric'

This label pretty much describes what this is doing.

vijaycs85’s picture

Status: Reviewed & tested by the community » Closed (duplicate)
Related issues: +#2167623: Add test for all default configuration to ensure schema exists and is correct

The patch on this issue has been updated as part of #2167623: Add test for all default configuration to ensure schema exists and is correct. As this issue doesn't have any test to confirm/validate the schema, making this change and closing this issue as duplicate of #2167623: Add test for all default configuration to ensure schema exists and is correct. The contributors of this issue (in commit message) is copied to #2167623: Add test for all default configuration to ensure schema exists and is correct.