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

MCP @FormField doesn't support namespace as property #1868

Closed
jasiwal opened this issue Apr 30, 2019 · 2 comments
Closed

MCP @FormField doesn't support namespace as property #1868

jasiwal opened this issue Apr 30, 2019 · 2 comments
Assignees
Labels
Milestone

Comments

@jasiwal
Copy link
Contributor

jasiwal commented Apr 30, 2019

Required Information

  • [6.4.3 ] AEM Version, including Service Packs, Cumulative Fix Packs, etc: _______
  • [4.0.0 ] ACS AEM Commons Version: _____
  • [Yes ] Reproducible on Latest? yes/no

Expected Behavior

FormField should support sling @named to provide namespace as the property name "xyz:myField".

Actual Behavior

We should be an option to provide a different property name with a namespace "xyz:myField". And FormField should support @named sling annotation.
Example:

  @Inject
  @Named(value = "viacom:requestLabel")
  @FormField(name = "Request Label", category = "General")
  private String requestLabel;

Note: Right now it just takes the name of the variable as the name of the jcr properties.

@badvision
Copy link
Contributor

@gauravjasiwal let me know if this patch works for you, you can find it in the feature branch.

@jasiwal
Copy link
Contributor Author

jasiwal commented May 7, 2019

@badvision Yes it's working, I tried in my local.

@badvision badvision added this to the 4.1.0 milestone May 7, 2019
badvision added a commit that referenced this issue May 23, 2019
… (#1896)

* Added support for Named annotations in MCP Form Processor, fixing #1868
badvision added a commit that referenced this issue May 23, 2019
* Added support for Named annotations in MCP Form Processor, fixing #1868
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants