Closed (fixed)
Project:
Table Field
Version:
2.0.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
11 Aug 2022 at 18:45 UTC
Updated:
11 Jul 2023 at 20:24 UTC
Jump to comment: Most recent
Comments
Comment #2
kaszarobertBefore doing this it would be good to discuss what advantages does it bring for us. Will we benefit easier maintainability, usability or speed with introducing this new dependency? Because it sounds a lot of extra work: we need to change widgets' and formatters' code to a new field type & also create upgrade path with field migration to the new JSON type. Also, we don't need to query separate things from the JSON structure. The JSON data is loaded only when we render the form widget and the table. I only want to do this if it's really worth it.
Comment #3
pcate commentedThat would be the primary purpose I had in mind for adding JSON field support. It would allow capabilities like this which would be very powerful.
For instance, I could see it being useful for content editors to enter spreadsheet-like data that Views could then query/filter and display in ways other than an HTML table.
Comment #4
kaszarobertOK, then why not. I'm not familiar with JSON field module, so we need to investigate:
- if we need a new widget based on the current one, or can it be modified to support this other field type from JSON field module (without breaking backwards compatibility)
- for the formatters, it should be easier: maybe we don't need to json_decode a string during processing the output - if that field type gives us the JSON right away. I can't tell now, so this must be checked.
- also if that JSON field module defines multiple field types, we should consider if we want to support everything, or select a few.
- also we have to keep in mind that this should be an optional dependency right now. Existing code should continue to work.
Comment #6
kaszarobertWell, it was easier than I expected. Will be out in the latest release.