Expected Behaviour
I am trying to update product Retriever Filter Attributes but it is replace the value instead of key. And my requirement is to update/replace the existing attribute key not to set the custom attribute.
Actual Behaviour
After changing the code it is replacing the value of attribute , instead of key.
Expected Query
{products(filter:{my-attribute:{eq:"my-value"},custom-sku:{eq:"123"}})
Generated Query:
{products(filter:{my-attribute:{eq:"my-value"},sku:{eq:"custom-sku"}})
Reproduce Scenario (including but not limited to)
- Extend custom productdetails model and after retrieving the productRetriever I am extending the query to replace the key in grapghql query schema but it is replacing the value instead of key,
Steps to Reproduce
- Extend custom productdetails model and after retrieving the productRetriever I am extending the query to replace the key in grapghql query schema but it is replacing the value instead of key,
Platform and Version
AEM 6.5.12 , CIF core: 2.11.0
Sample Code that illustrates the problem
@PostConstruct
public void initModel() {
productRetriever = product.getProductRetriever();
if (productRetriever != null) {
productRetriever.extendProductFilterWith(f -> new ProductAttributeFilterInput()
.setSku(new FilterEqualTypeInput()
.setEq("custom-sku"))
.setCustomFilter("my-attribute", new FilterEqualTypeInput()
.setEq("my-value")));
}
}
Logs taken while reproducing problem
Expected Behaviour
I am trying to update product Retriever Filter Attributes but it is replace the value instead of key. And my requirement is to update/replace the existing attribute key not to set the custom attribute.
Actual Behaviour
After changing the code it is replacing the value of attribute , instead of key.
Expected Query
{products(filter:{my-attribute:{eq:"my-value"},custom-sku:{eq:"123"}})
Generated Query:
{products(filter:{my-attribute:{eq:"my-value"},sku:{eq:"custom-sku"}})
Reproduce Scenario (including but not limited to)
Steps to Reproduce
Platform and Version
AEM 6.5.12 , CIF core: 2.11.0
Sample Code that illustrates the problem
@PostConstruct
public void initModel() {
productRetriever = product.getProductRetriever();
Logs taken while reproducing problem