There is a plugin that will let you do this for relationship fields, but I cannot find anything available to allow doing this with terms.
This is not something that can be done in ACF without a lot of work. For example, if you wanted to do the modal thing for editing.
If I had to do this what I would probably do is the following…. I don’t have code and there would be a lot of it, so I can’t really provide it without actually building this.
1) I would create a fields, I would probably use a “Group” field. This field would be conditional on the taxonomy field having any value. Alternately you could have an “update the term” true false field and and make the group conditional on this field.
2) In the group field I would add the fields that need to be updated in the term. I would make these fields required, but this would be more difficult because you wouldn’t know if the term is new or not, if the term already has these values you’d probably not want to update them, but more on this later.
3) I would create an acf/prepare_field filter. In this filter I would get the value from the taxonomy field and I would use this to get the values from the term and populate the group field with these values if they exist.
3) I would then add an acf/save_post filter. In this filter I would get the value from the taxonomy field and the fields that need to be updated in the term and I would update the term with these values. After updating the term I would delete the values from group field values from the post, they will be populated again when the post is reloaded (see #3)
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
© 2022 Advanced Custom Fields.