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

Add an OCS endpoint for the hovercard contact actions #29269

Merged

Conversation

nickvergessen
Copy link
Member

Ref #28751
Ref nextcloud/files-clients#1

Alternate attempt to #29249

  • Less intrusive
  • Only populating data that is needed now (since OCS has to stay compatible 3 years)
  • Instead of shareTypes and POST, the userId is a url parameter and therefor much more straight forward
  • In case hovercards get extended in the future, we can add more details to it and just bump the version parameter in the URL

@nickvergessen nickvergessen added this to the Nextcloud 23 milestone Oct 15, 2021
@nickvergessen nickvergessen force-pushed the feature/28751/provide-contactsmenu-as-ocs-simple branch 2 times, most recently from d1639a7 to 5c2a166 Compare October 15, 2021 19:38
@Pytal Pytal mentioned this pull request Oct 15, 2021
28 tasks
@skjnldsv skjnldsv force-pushed the feature/28751/provide-contactsmenu-as-ocs-simple branch 3 times, most recently from 8a8c131 to 8b809b6 Compare October 18, 2021 16:41
@tobiasKaminsky
Copy link
Member

curl --request GET \
  --url 'http://localhost/nc/ocs/v2.php/hovercard/v1/admin?format=json' \
  --header 'Authorization: Basic dG9iaTpTSGZ6ZC04YkQyNC1xOUtSaS1zU2NRay03ZHh4eA==' \
  --header 'OCS-APIRequest: true'

I receive a 404:

{
  "ocs": {
    "meta": {
      "status": "failure",
      "statuscode": 404,
      "message": null
    },
    "data": []
  }
}

I think I understood that @skjnldsv said that addressbook is populated too late…?

@skjnldsv skjnldsv force-pushed the feature/28751/provide-contactsmenu-as-ocs-simple branch from 8b809b6 to 2384e2d Compare October 19, 2021 08:59
@skjnldsv
Copy link
Member

I think I understood that @skjnldsv said that addressbook is populated too late…?

occ dav:sync-system-addressbook

@tobiasKaminsky
Copy link
Member

I think I understood that @skjnldsv said that addressbook is populated too late…?

occ dav:sync-system-addressbook

Tried it, still the same 🤔

@skjnldsv
Copy link
Member

I think I understood that @skjnldsv said that addressbook is populated too late…?

occ dav:sync-system-addressbook

Tried it, still the same thinking

No errors in log?

@Pytal Pytal mentioned this pull request Oct 19, 2021
20 tasks
@tobiasKaminsky

This comment has been minimized.

Signed-off-by: Joas Schilling <coding@schilljs.com>
@skjnldsv

This comment has been minimized.

@skjnldsv skjnldsv force-pushed the feature/28751/provide-contactsmenu-as-ocs-simple branch from 2384e2d to b6036bd Compare October 20, 2021 08:47
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
@skjnldsv skjnldsv force-pushed the feature/28751/provide-contactsmenu-as-ocs-simple branch from b6036bd to 5e23800 Compare October 20, 2021 09:54
@skjnldsv skjnldsv added 4. to release Ready to be released and/or waiting for tests to finish and removed 3. to review Waiting for reviews labels Oct 20, 2021
Signed-off-by: Joas Schilling <coding@schilljs.com>
@tobiasKaminsky
Copy link
Member

tobiasKaminsky commented Oct 20, 2021

I think I understood that @skjnldsv said that addressbook is populated too late…?

occ dav:sync-system-addressbook

Tried it, still the same thinking

No errors in log?

Problem was that admin user had only local visible properties in "personal info" and thus not in addressbook.

@nickvergessen
Copy link
Member Author

Same issue happens btw with the current avatar menu.

  • As user 1 go to personal settings
  • Set all privacies to "Local"
  • occ dav:sync-system-addressbook
  • As user 2 open the avatar menu of user 1
  • 💥

@nickvergessen
Copy link
Member Author

Reported at #29338 as the system-address book entry is basically missing and therefor it's a generic problem and should be fixed outside of this pull request

@nickvergessen nickvergessen merged commit 0e951eb into master Oct 20, 2021
@nickvergessen nickvergessen deleted the feature/28751/provide-contactsmenu-as-ocs-simple branch October 20, 2021 14:25
@skjnldsv skjnldsv mentioned this pull request Oct 25, 2021
25 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4. to release Ready to be released and/or waiting for tests to finish enhancement feature: contacts menu
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants