I have a homepage which has a pageHome ACF group. This group has an ACF group field called productCategories in the schema. This group field has a Taxonomy field, also called productCategories inside. The Taxonomy field correctly saves the translated Term IDs in the database, but when fetching the translated version of the homepage, both the original (Dutch) version and the translated (English) versions return Dutch taxonomy terms.
The below query is an example that should return the Dutch homepage and the English homepage, with taxonomy terms with different database IDs attached to each version.
query TestPageHome {
page(id: "/", idType: URI) {
...PageHome
translated {
...PageHome
}
}
}
fragment PageHome on Page {
locale {
locale
}
pageHome {
productCategories {
productCategories {
databaseId
}
}
}
}
{
"data": {
"page": {
"locale": {
"locale": "nl_NL"
},
"pageHome": {
"productCategories": {
"productCategories": [
{
"databaseId": 40
},
{
"databaseId": 38
},
{
"databaseId": 39
}
]
}
},
"translated": [
{
"locale": {
"locale": "en_US"
},
"pageHome": {
"productCategories": {
"productCategories": [
{
"databaseId": 40
},
{
"databaseId": 38
},
{
"databaseId": 39
}
]
}
}
}
]
}
}
}
Relevant plugins:
| Plugin name |
Version |
| WPGraphQL |
1.14 |
| WPGraphQL for ACF |
0.6.1 |
| WPGraphQL WPML |
1.1.0 |
| ACFML |
2.0.3 |
| WPML CMS |
4.6.0 |
| WPML String Translation |
3.2.4 |
I have a homepage which has a
pageHomeACF group. This group has an ACF group field calledproductCategoriesin the schema. This group field has a Taxonomy field, also calledproductCategoriesinside. The Taxonomy field correctly saves the translated Term IDs in the database, but when fetching the translated version of the homepage, both the original (Dutch) version and the translated (English) versions return Dutch taxonomy terms.The below query is an example that should return the Dutch homepage and the English homepage, with taxonomy terms with different database IDs attached to each version.
{ "data": { "page": { "locale": { "locale": "nl_NL" }, "pageHome": { "productCategories": { "productCategories": [ { "databaseId": 40 }, { "databaseId": 38 }, { "databaseId": 39 } ] } }, "translated": [ { "locale": { "locale": "en_US" }, "pageHome": { "productCategories": { "productCategories": [ { "databaseId": 40 }, { "databaseId": 38 }, { "databaseId": 39 } ] } } } ] } } }Relevant plugins: