Problem/Motivation

Both Recipe and Article have a field_tags for tagging content with terms from the Tags vocabulary. The field on articles is set to create referenced entities if they don't already exist, whereas the field on recipes is not.

There is no reason for this inconsistency.

Proposed resolution

Set field_tags on recipe to create referenced entities if they don't already exist.

Remaining tasks

All the things.

User interface changes

Users will be able to free tag recipes.

API changes

None.

Data model changes

None

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Eli-T created an issue. See original summary.

Eli-T’s picture

Status: Active » Needs review
FileSize
0 bytes
Eli-T’s picture

Sorry, previous patch is empty.

The last submitted patch, 2: 2992380_2_auto_create_recipe_tags.patch, failed testing. View results

JayKandari’s picture

#3 Applies perfectly and the "Tags" field in Recipe content type is set to "create referenced entities if they don't already exist " - works good. 👍

However, I have a question about "field_recipe_category" && "field_author" fields of recipe content type. The latter one we can ignore as of now as it is being removed in #2991473: Remove the field_author from Umami recipe content type. The field "field_recipe_category" is also set to "auto_create: false".

Can we also make this inconsistency addressed for other entity referenced fields as well?

Eli-T’s picture

Thanks for taking a look @jaykandari!

With respect to Recipe Category, I don't think it's a given that we should auto create terms in that vocabulary. It makes sense to have a fixed set of categories rather than define them on them on the fly as you would do for a tags vocabulary which is potentially far more wide ranging.

Maybe changing the widget would be more appropriate, but I would put that in another issue.

JayKandari’s picture

Status: Needs review » Reviewed & tested by the community

#6 makes sense as to why not auto-create recipe category. Thanks, @eli-t.
Marking it as RTBC.

  • lauriii committed 6803dcc on 8.7.x
    Issue #2992380 by Eli-T, JayKandari: Umami content types are...

  • lauriii committed 65c5eba on 8.6.x
    Issue #2992380 by Eli-T, JayKandari: Umami content types are...
lauriii’s picture

Status: Reviewed & tested by the community » Fixed

Committed 6803dcc and pushed to 8.7.x. Also, cherry-picked 65c5eba and pushed to 8.6.x. Thanks! 🚀

lauriii’s picture

Saved the commit-credit

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.