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

Expose capability to deny access in OCS API #1949

Closed
wants to merge 5 commits into from

Conversation

labkode
Copy link
Member

@labkode labkode commented Aug 3, 2021

@phil-davis will need help on this one to pass the tests.

@labkode
Copy link
Member Author

labkode commented Aug 5, 2021

Refactor the code to use additional attributes rather than playing with the permission bits:

{
  "ocs": {
    "meta": {
      "status": "ok",
      "statuscode": 200,
      "message": null,
      "totalitems": "",
      "itemsperpage": ""
    },
    "data": [
      {
        "id": "125266",
        "share_type": 0,
        "uid_owner": "jfd",
        "displayname_owner": "Jörn Friedrich Dreyer",
        "permissions": 1,
        "stime": 1624566341,
        "parent": null,
        "expiration": null,
        "token": null,
        "uid_file_owner": "jfd",
        "displayname_file_owner": "Jörn Friedrich Dreyer",
        "additional_info_owner": null,
        "additional_info_file_owner": null,
        "path": "/test.odp",
        "mimetype": "application/vnd.oasis.opendocument.presentation",
        "storage_id": "home::jfd",
        "storage": 20,
        "item_type": "file",
        "item_source": 5429442,
        "file_source": 5429442,
        "file_parent": 4065,
        "file_target": "/Shared/test.odp",
        "share_with": "fschade",
        "share_with_displayname": "Florian Schade",
        "share_with_additional_info": null,
        "mail_send": 0,
        "attributes": "[{\"scope\":\"permissions\",\"key\":\"download\",\"enabled\":false},{\"scope\":\"richdocuments\",\"key\":\"view-with-watermark\",\"enabled\":true},{\"scope\":\"richdocuments\",\"key\":\"print\",\"enabled\":true}]"
      }
    ]
  }
}

@ishank011
Copy link
Contributor

Duplicate of #2733

@ishank011 ishank011 marked this as a duplicate of #2733 Jun 13, 2022
@ishank011 ishank011 closed this Jun 13, 2022
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 this pull request may close these issues.

3 participants