It was stated a few years back that supporting Field Groups isn't really the intent of this module and that Field Collection module could be used instead (https://www.drupal.org/node/1852788), which can be added as a single field. Field Collection still has scores of outstanding issues (I'm sure due to its popularity and thus multi-faceted applications) and also supposedly comes with an everyday performance hit by loading another entity.

While Field Groups would have been useful (and easy enough to implement I would guess), for my own custom applications, I instead decided to experiment adding a comma separated list of fields to the URL path.

For example,
http://www.example.com/admin/field/edit/node/442/body,field_city,author,created?destination=node/442

Note that I extended multi-field support to include the 3 supported non-fields (title, author, created).

In my case, many fields would have no meaning on their own and are often concatenated into rendered fields within panels. For example, "first_name last_name" is the product of first_name and last_name and you'd want to edit them together. A currency unit would be editable along with the number itself as another example.

A greater concern is how this module out-of-the-box appears to allow any client to attempt editing a single field directly. If no restrictions are put in place by the developer, many nodes can be broken this way due to node edit form modification never taking place (for example, the Date Repeat Entity module produces a secondary submission form that is bypassed by FAPE). I should probably post this as a separate issue just so people are aware of the pitfalls.

I've quickly hacked together something that appears to work (which other developers can manipulate for their own purposes). The formatting is still messed up (sorry about that) and I've left redundant code in so that single fields would be treated pretty closely to the pre-patched state.

Comments

cmonnow’s picture

cmonnow’s picture

cmonnow’s picture

Issue summary: View changes
captainack’s picture

Status: Active » Needs review
StatusFileSize
new11.18 KB

cmonnow, great idea and approach! I needed this too, so your patch gave me a huge head start.

I made it accept an array in addition to a comma-separated list too. I also got a little carried away refactoring and making some changes to make it a little easier to read by the maintainers if they git diff -b (less changes to look at).

Status: Needs review » Needs work

The last submitted patch, 4: fape-2451015-support_multiple_fields-4.patch, failed testing.

captainack’s picture

Status: Needs work » Needs review

Silly testbot...

The last submitted patch, 1: support_multiple_fields_FAPE-2451015-1.patch, failed testing.