nextcloud / server

☁️ Nextcloud server, a safe home for all your data
https://nextcloud.com
GNU Affero General Public License v3.0
26.69k stars 4k forks source link

Capability for comments #20612

Open tobiasKaminsky opened 4 years ago

tobiasKaminsky commented 4 years ago

Comments can be disabled by occ app:disable comments Therefore we need a capability that allows clients to react on it in a proper way

stefan-niedermann commented 4 years ago

If this has been implemented in the capabilities-endpoint, it would be very nice if the one who implemented this could post a sample JSON-response with enabled and disabled capabilities here (would make the implementation way easier, at least for us :wink:).

rullzer commented 4 years ago

No comments on desktop ;)

tobiasKaminsky commented 4 years ago

No comments on desktop ;)

not yet :-D

blizzz commented 4 years ago

Comments can be disabled by occ app:disable comments

It disables only the web UI, but the functionality and the API is there itself. Still, it is reasonable to indicate that file comments ain't offered anywhere.

stefan-niedermann commented 4 years ago

To be honest i don't see the point of "disabling" the comments app if it is still possible to post comments via API...

What's the use case? Either i don't want people to comment, then i should deny it on all levels, or i don't care at all.

szaimen commented 4 years ago

To be honest i don't see the point of "disabling" the comments app if it is still possible to post comments via API...

The biggest point of disabling the comments app imo is, that you get a simpler web interface (the sidebar is already really overpopulated with tabs) and e.g. you have talk for chatting and comments for chatting.

Since talk enables videochat on files and is more useful imo, I have disabled the comments app and only allow talk on the webinterface...

stefan-niedermann commented 4 years ago

But can't this lead to missed comments which might be posted by a 3rd-party-app via API? I get the point, but without actually disabling and denying comments this might be dangerous as more and more integrations-apps are coming 😉

szaimen commented 4 years ago

But can't this lead to missed comments which might be posted by a 3rd-party-app via API? I get the point, but without actually disabling and denying comments this might be dangerous as more and more integrations-apps are coming

Potentially yes, and I actually wouldn't disable the comments app if it was well integrated into the activities tab like it was already suggested by jancborchardt elsewhere and as it already is implemented in the Nextcloud Android app.

stefan-niedermann commented 4 years ago

cc @jancborchardt and @nextcloud/designers

nickvergessen commented 4 years ago

No, when the comments app is disabled the API does not allow to comment on files. But e.g. you can still comment on announcements, deck, and others.

This issue here was opened, so the mobile clients for the files don't show the comments tab when you can't comment on files.

szaimen commented 4 years ago

Reopen for client implementation?

nickvergessen commented 4 years ago

Just for the record as Deck is in the list. The capability is only for file comments, so I guess it does not affect deck, right?

stefan-niedermann commented 4 years ago

As far as i know it does affect deck. @juliushaertl implemented the server side check somehow without using the capabilities endpoint but with a server side php call, and we (Deck Android) will need the information for feature parity - that's why we need the info in the capabilities (or any other) endpoint.

nickvergessen commented 4 years ago

No, it registers it's own entity type, so deck comments can be made without the comments app: https://github.com/nextcloud/deck/blob/master/lib/AppInfo/Application.php#L152-L164

stefan-niedermann commented 4 years ago

@nickvergessen i referred to this PR in the deck app repo: https://github.com/nextcloud/deck/pull/1734

But according to your comment the Deck app needs to provide a own REST API then to expose the enabled / disabled status of its comments then?

Hmm @juliushaertl can you clearify this please?

juliushaertl commented 4 years ago

I was under the impression that the comments app would actually handle the server api and the dav plugins as well, but if it is only caring about files comments, we can actually just always keep them available in deck.

stefan-niedermann commented 4 years ago

we can actually just always keep them available in deck.

@juliushaertl can you please give me an update whether or not you will keep them always available in deck? In this case this issue is obsolete for the deck android app.

juliushaertl commented 4 years ago

Since the Api is always enabled I think it makes most sense to just always have comments enabled in deck then.

https://github.com/nextcloud/deck/issues/2126