Follow up for #1953404: Add config schema to field and instance config entities
Problem/motivation
#1866610: Introduce Kwalify-inspired schema format for configuration introduced the idea of config schema. The changelog leads to (hopefully extensive) documentation on the format at http://drupal.org/node/1905070. As a part of schema addition to field module(#1953404: Add config schema to field and instance config entities), found that we have to provide schema for field types, field widgets and field storage.
Proposed solution
Create a configuration schema for field types, field widget and field storage (if applicable) defined in options module.
Schema in place
Schema not yet in place
field.list_integer.settings
field.list_integer.instance_settings
field.list_integer.value
field.list_float.settings
field.list_float.instance_settings
field.list_float.value
field.list_text.settings
field.list_text.instance_settings
field.list_text.value
field.list_boolean.settings
field.list_boolean.instance_settings
field.list_boolean.value
field_widget.options_select.settings
field_widget.options_buttons.settings
field_widget.options_onoff.settings
field_widget.options_list.settings
Comment | File | Size | Author |
---|---|---|---|
#7 | config-schema-field-options-followup-1973448-7.patch | 1.43 KB | yched |
#3 | field.field_.list_text.form_.png | 37.92 KB | vyasamit2007 |
#3 | field.field_.file_.form_.png | 29.1 KB | vyasamit2007 |
#3 | field.field_.datetime.form_.png | 26.66 KB | vyasamit2007 |
#2 | config-schema-field-options-2.patch | 4.28 KB | vijaycs85 |
Comments
Comment #1
vijaycs85Comment #2
vijaycs85Initial patch with config_inspector screenshots...
Comment #3
vyasamit2007 CreditAttribution: vyasamit2007 commentedComment #4
Gábor HojtsyPutting on sprint for tracking :)
Comment #5
webchickWow. This was a much bigger patch than I was picturing when I clicked into this issue. :) Nevertheless, looks good in my quick eyeball, and it looks like it was very thoroughly tested, so good job for that.
Committed and pushed to 8.x. Thanks!
Comment #6
yched CreditAttribution: yched commentedThanks @vijaycs85 !
This doesn't correspond to any actual setting.
Did you include it because you find it saved in actual CMI files ? That would be a bug...
Comment #7
yched CreditAttribution: yched commentedHm, right, 'allowed_values_function_display' is just an informational '#type' => 'item' element in the field settings $form, but this ends up as an empty string in the submitted form values.
I opened #1985386: Crufty 'allowed_values_function_display' ends up in list field stored config for this. Meanwhile, we should remove those entries.
Comment #8
swentel CreditAttribution: swentel commentedGood to go.
Comment #9
Gábor HojtsyThe role of the schema is to describe the data format as is available, not to describe what we want it to be. The schema sections should be removed as the data itself is fixed in #1985386: Crufty 'allowed_values_function_display' ends up in list field stored config . Removing it prior would leave that unexplained. I'm going to upload this patch there so it can continue from there.
Comment #10
Gábor Hojtsy@vyasamit2007: can you help review the numerous other schema issues for fields at http://drupal.org/project/issues/search/drupal?issue_tags=Field%20config...? That would be amazing! Thanks!
Comment #11
Gábor HojtsyRemove sprint tag.
Comment #12.0
(not verified) CreditAttribution: commentedUpdated issue summary.