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

Bug(on-prem): FieldUserRenderer -> GetPropertiesFor call #468

Closed
Matej4386 opened this issue Jan 21, 2020 · 2 comments
Closed

Bug(on-prem): FieldUserRenderer -> GetPropertiesFor call #468

Matej4386 opened this issue Jan 21, 2020 · 2 comments
Labels
status:fixed-next-drop Issue will be fixed in upcoming release. type:bug
Milestone

Comments

@Matej4386
Copy link

Category

[ ] Enhancement

[X ] Bug

[ ] Question

Version

Please specify what version of the library you are using: [ 1.16.0 ]

Expected / Desired Behavior / Question

FieldUserRenderer - after hover on name, additional info should be rendered (mail, tel, position, etc.) after 2 SP calls:

  1. _api/web/getUserById(ID)
  2. api/SP.UserProfiles.PeopleManager/GetPropertiesFor

Observed Behavior

implementation of api/SP.UserProfiles.PeopleManager/GetPropertiesFor is not working on on-prem Sharepoint 2019:
current implementation in SPHelper.js in SPHelper.getUserProperties function is:
...
url += "/_api/SP.UserProfiles.PeopleManager/GetPropertiesFor('" + encodeURIComponent(loginName) + "')";
...
this call gets null returned.

Steps to Reproduce

Sharepoint on-prem 2019

Thanks!

@ghost
Copy link

ghost commented Jan 21, 2020

Thank you for reporting this issue. We will be triaging your incoming issue as soon as possible.

@ghost ghost added the Needs: Triage 🔍 label Jan 21, 2020
@Matej4386
Copy link
Author

After change in SPHelper.js in SPHelper.getUserProperties function from:
...
url += "/_api/SP.UserProfiles.PeopleManager/GetPropertiesFor('" + encodeURIComponent(loginName) + "')";
...

to:
...
url += "/_api/SP.UserProfiles.PeopleManager/GetPropertiesFor(accountName=@v)?@v='" + encodeURIComponent(loginName) + "'";
...

everything works great ;-)

Matej4386 pushed a commit to Matej4386/sp-dev-fx-controls-react that referenced this issue Jan 27, 2020
@AJIXuMuK AJIXuMuK added status:fixed-next-drop Issue will be fixed in upcoming release. type:bug and removed Needs: Triage 🔍 labels Feb 19, 2020
@AJIXuMuK AJIXuMuK added this to the 1.17.0 milestone Feb 19, 2020
@estruyf estruyf closed this as completed Mar 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status:fixed-next-drop Issue will be fixed in upcoming release. type:bug
Projects
None yet
Development

No branches or pull requests

3 participants