Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Generic Lists][Touch UI Asset Metadata Editor]- Prefixing /mnt/acs-commons/lists to the name of a generic list in the JSON path of dropdown fields doesn't work #2479

Closed
3 tasks
arpithaar opened this issue Nov 18, 2020 · 4 comments · Fixed by #2485

Comments

@arpithaar
Copy link

  • AEM Version, including Service Packs, Cumulative Fix Packs, etc: AEMaaCS, 6.5, 6.4 (Not really dependent on AEM version I believe)
  • ACS AEM Commons Version: 4.8.0
  • Reproducible on Latest? yes/no : Yes

Steps to reproduce

  1. Navigate to Tools -> Assets->Metadata Schemas
  2. Configure a dropdown field and add the options by configuring a JSON path - /mnt/acs-commons/lists/{name-of-the-generic-list}.json
  3. Go to asset's properties, the dropdown field should list the options configured in the generic list

Actual Behavior

The assets' properties ui is broken because it expects "text" in /mnt/acs-commons/lists/{name-of-the-generic-list}.json instead of "title"

Expected JSON

Screenshot 2020-11-18 at 4 56 58 PM

Actual JSON

image

@shsteimer
Copy link
Contributor

shsteimer commented Nov 18, 2020

@badvision It looks like this was introduced in 4.0.0 as part of https://github.com/Adobe-Consulting-Services/acs-aem-commons/pull/1568/files. Assuming the asset metadata editor is the only thing using that resource provider, which I think is true, the fix should be as simple as adding @SerializedName annotations to the ItemImpl class at https://github.com/Adobe-Consulting-Services/acs-aem-commons/blob/master/bundle/src/main/java/com/adobe/acs/commons/genericlists/impl/GenericListImpl.java#L42 so that the field outputs as text and not title

@badvision
Copy link
Contributor

PR is always welcome. Also, when I asked around how people were using this thing prior to refactoring and nobody spoke up it would have been nice if people actually said something then. I don't have time to work on this at the moment unfortunately, but I have a few minutes to review a PR.

@shsteimer
Copy link
Contributor

If @arpithaar can work on a PR that would be great, if not I can probably do it. Was just checking with you in case you knew of other use cases for this JSON Resource Provider other than for the Assets Metadata Editor.

@badvision
Copy link
Contributor

No, I actually have no idea how people use generic lists other than how it's documented in the documentation usage pages. People have used it in many different ways but there's no notes on it other than people complaining about how it doesn't work like it used to. :/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants