Early Bird Registration for DrupalCon Portland 2024 is open! Register by 23:59 PST on 31 March 2024, to get $100 off your ticket.
Comment | File | Size | Author |
---|---|---|---|
#12 | 2234769-multifield-field-type-12.patch | 75.61 KB | Jelle_S |
Comment | File | Size | Author |
---|---|---|---|
#12 | 2234769-multifield-field-type-12.patch | 75.61 KB | Jelle_S |
Comments
Comment #1
Dave ReidThis at least will make the transition easier to one unified 'Multifield' field type.
Comment #2
attiks CreditAttribution: attiks commented@Dave Reid do you want to commit this first, before #2041533: Add Views API integration for the multifield field type and/or #2102265: Features integration? Just so we know how to reroll everything
Comment #3
Dave ReidI'd like to get the Views integration in first, but looking at the Features integration, and reviewing what Field collection does, makes me kind of like that no special magic is needed for exporting Field collections. You just have to export the field collection field, and the subfields, and it just works. If we had one 'Multifield' field type, we could do the same, and we wouldn't even need the multifield table itself, which I would be ok with.
Comment #4
Dave ReidOk looks like this is all that's needed to deprecate the old field type and start to encourage people to use the official 'Multifield' field type.
Comment #5
Dave ReidMade sure to update field schema when adding instances to the new multifield type.
Comment #8
Dave ReidOk this one has even more test coverage, and workaround for a core bug with field_update_field() "remembering" old indexes in field schema that are no longer wanted.
Comment #9
Dave ReidFound an interesting core bug as a result of this: #2311095: field_update_field() fails if a field schema removes an index
Comment #10
Dave ReidComment #11
Dave ReidAdded very basic Features integration so that a multifield is exported properly.
Comment #12
Jelle_SThis patch includes the (rerolled) patch from #2041533-49: Add Views API integration for the multifield field type.
Views integration seems to work as it did before with that patch.
Comment #13
Dave ReidCommitted #11 to 7.x-1.x.
Comment #16
DamienMcKenna@tufy: There's no point in re-testing a patch that has already been committed, just grab the latest -dev release.
Comment #17
MixologicI have a question on this. Is there some reason that 'no_ui' => TRUE is needed in there? it makes it so that you cannot re-use a multifield on different bundles, or even have multiple instances of the same multifield on the same entity, like you could before this patch.
Comment #18
ciss CreditAttribution: ciss commented@Mixologic: From what I understand it only affects instances that have been created in an earlier version of multifield. This would be the deprecation of the old field type that has been mentioned in several places.
Comment #19
Dave ReidCorrect, using 'no_ui' only apples to the old, deprecated field type. You can still use the field API functions to create instances, adjust settings, etc. if needed.
Comment #21
ciss CreditAttribution: ciss commented