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

Share directory Upload + Read only #6620

Closed
jee-r opened this issue Sep 22, 2017 · 29 comments
Closed

Share directory Upload + Read only #6620

jee-r opened this issue Sep 22, 2017 · 29 comments
Labels
1. to develop Accepted and waiting to be taken care of design Design, UI, UX, etc. enhancement feature: sharing

Comments

@jee-r
Copy link

jee-r commented Sep 22, 2017

Hello,

Would it be possible to add an upload + read-only option for a shared folder.

capture d ecran_2017-09-22_22-29-35

Use case
This would allow sharing photos (read-only) with a friend who does not have a nextcloud account, but also to upload his own.

Problem with read and write is that my friend can modify or delete files that i have uploaded.

Thank's

@blizzz
Copy link
Member

blizzz commented Sep 25, 2017

iirc upload requires write. @nextcloud/sharing

@rullzer
Copy link
Member

rullzer commented Sep 25, 2017

Yes upload requires write. But delete and update are separate permissions. I think this is more about how do we show yet another use case to the user. I'm sure @jancborchardt would kill me if we just extend that list with every possible option.

@jancborchardt
Copy link
Member

I mean, it is a good point cause we also have files drop. The current workaround would be to share your own pictures with a read-only link and give the friend a files drop, or fully editable folder link.

This would be the options, with the new one in bold:

  • Editing – default
  • Read-only
  • Upload-only (no reading)
  • Read-only with upload

In this new mode, uploaded files with the same name would automatically need to have a " (2)" appended.

We could change it from radio buttons to a dropdown instead … what do @nextcloud/designers think?

@jancborchardt jancborchardt added the design Design, UI, UX, etc. label Sep 25, 2017
@rullzer
Copy link
Member

rullzer commented Sep 25, 2017

@jancborchardt your solution currently won't work as we don't have multiple link shares as an option.

@pixelipo
Copy link
Contributor

What about simply having 3 independent (checkbox) items:

  • view (read)
  • upload
  • edit

@Schmuuu
Copy link

Schmuuu commented Apr 30, 2018

I'm glad somebody opened an issue for this already. I haven't noticed this until a user of mine (family member) informed me about an "accident". When he shared photos via a public link to his friends, he wanted to allow his friends to view the photos and upload additional photos. One person who accessed the public link deleted the photos however.
At first I was confused why he would allow the deletion of files via a public link, but when I checked, I saw that there are not the same options for public sharing like for internal sharing.

To be protected against further accidents, it would be nice if this feature request could be implemented soon. I really like the idea of @pixelipo

@nextcloud-bot nextcloud-bot added the stale Ticket or PR with no recent activity label Jun 20, 2018
@jancborchardt jancborchardt added this to the Nextcloud 15 milestone Jul 16, 2018
@jeyca
Copy link

jeyca commented Jul 16, 2018

What about simply having 3 independent (checkbox) items:

view (read)
upload
edit

I wonder why this hasn't already been in the first place, kind of this has been established already decades ago in linux filesystems.

@nextcloud-bot nextcloud-bot removed the stale Ticket or PR with no recent activity label Jul 16, 2018
@billetj
Copy link

billetj commented Jul 19, 2018

Does anyone know if something has been done for that ?

@jwillmer
Copy link

jwillmer commented Jul 19, 2018

I found a tutorial on the internet a couple of months ago of a guy who edited the database in order to get this functionality - can't find the link anymore.

Basically there is a table with all shared folders and there permission levels. The permission level is a number and if u sum the number for upload + view permission and set the result for a folder you get a folder that people can upload to and view the uploaded files. I did this for my Nextcloud instance as well and it works without a problem.

So this feature contains really not much work. There is basically only the GUI missing to make this wok for all people. For me it is too much of a hassle to setup the development environment only to add this feature and make a pull request - sorry.

@jancborchardt
Copy link
Member

As you can see from the set milestone, it’s currently planned to probably have it in Nextcloud 15 (which is the release after the one we are currently finishing up).

So this feature contains really not much work. There is basically only the GUI missing to make this wok for all people. For me it is too much of a hassle to setup the development environment only to add this feature and make a pull request - sorry.

@jwillmer That’s really a bummer, we would be very happy to help you set it up. Just saw you are in Stuttgart – we regularly have hackweeks there and you are very welcome to join us. :)

@rullzer rullzer removed this from the Nextcloud 15 milestone Nov 5, 2018
@skjnldsv skjnldsv added the 1. to develop Accepted and waiting to be taken care of label Jun 12, 2019
@arman-sydikov
Copy link

As you can see from the set milestone, it’s currently planned to probably have it in Nextcloud 15 (which is the release after the one we are currently finishing up).

So this feature contains really not much work. There is basically only the GUI missing to make this wok for all people. For me it is too much of a hassle to setup the development environment only to add this feature and make a pull request - sorry.

@jwillmer That’s really a bummer, we would be very happy to help you set it up. Just saw you are in Stuttgart – we regularly have hackweeks there and you are very welcome to join us. :)

It's been more than one year since the last comment, is there any progress on adding this functionality ?

@muellerlukas
Copy link

muellerlukas commented Oct 4, 2019

Fun fact: It's already possible when you set the "permissions"-value in "oc_share", only a option in the GUI is missing. :(

Available options can be found in lib/public/Constants.php

@arman-sydikov
Copy link

Fun fact: It's already possible wehen you set the "permissions"-value in "oc_share", only a option in the GUI is missing. :(

Available options can be found in lib/public/Constants.php

Thank you, that's exactly what I was looking for :)
Changing permission value from 15 to 5 manually in the database did the trick.

@skjnldsv
Copy link
Member

Duplicate of #8479 (comment)

@skjnldsv skjnldsv marked this as a duplicate of #8479 Oct 30, 2019
@najtin
Copy link

najtin commented Mar 9, 2020

Duplicate of #8479 (comment)

this is not a duplicate
this issue is about having the option to upload + read-only
and if i understand it correctly the referenced issue does not solve this. as pointed out before this is only a gui issue.

@szaimen
Copy link
Contributor

szaimen commented Mar 9, 2020

@najtin you are right!
@skjnldsv please reopen the issue :)

@huuub
Copy link

huuub commented Apr 5, 2020

Giving nextcloud a serious chance, pretty disappointed 1 day after installation that this is not possible. Really weird

@skjnldsv skjnldsv reopened this Apr 5, 2020
@skjnldsv
Copy link
Member

skjnldsv commented Apr 5, 2020

Ah no, still a duplicate of #8479 (comment)

@skjnldsv skjnldsv closed this as completed Apr 5, 2020
@szaimen
Copy link
Contributor

szaimen commented Apr 5, 2020

@skjnldsv why shouls this be a duplicate of #8479 (comment)?
There is nothing written about "filedrop and seeing already uploaded files" at the same time....

@szaimen
Copy link
Contributor

szaimen commented Apr 5, 2020

This option here is about files drop (can add and list files but not edit them)

@skjnldsv
Copy link
Member

skjnldsv commented Apr 5, 2020

There is nothing written about "filedrop and seeing already uploaded files" at the same time....

Yes, this is just about wording here.
The underlying issues is the available permissions on link shares.
This is covered by #8479

@gloomytree
Copy link

Fun fact: It's already possible when you set the "permissions"-value in "oc_share", only a option in the GUI is missing. :(

Available options can be found in lib/public/Constants.php

Came here via https://help.nextcloud.com/t/allow-public-upload-and-show-but-not-delete/2874/22 and this page should be indexed higher by google. Permission 5 is neccessary for a lot of usecases and i hope to see a GUI option in the future.

@jee-r
Copy link
Author

jee-r commented Aug 15, 2020

Ah no, still a duplicate of #8479 (comment)

I don't understand your reasoning, why you're closing this issue when it's older. If indeed the two issue are similar then the other one is a duplicate of this one.

@marvinjuette
Copy link

I like the options you get offered when sharing internally. Why don't use them for public link sharing?

@JanKerbl
Copy link

Fun fact: It's already possible when you set the "permissions"-value in "oc_share", only a option in the GUI is missing. :(

Available options can be found in lib/public/Constants.php

Is there a guide how to do this?

@muellerlukas
Copy link

Is there a guide how to do this?

First create a link share, you shoudl get sth like "https://NEXTCLOUDDOMAIN/s/TOKEN". You'll need the token later.

In Constants.php you can find the permissions

public const PERMISSION_CREATE = 4;
public const PERMISSION_READ = 1;
public const PERMISSION_UPDATE = 2;
public const PERMISSION_DELETE = 8;
public const PERMISSION_SHARE = 16;
public const PERMISSION_ALL = 31;

Just sum the values to "build" your permission. E.g: Create + read -> 4 + 1 -> 5

Then open your database with phpmyadmin or sth, open the table "oc_share" and search for the row where the token-column matches your token.
Then set the column "permissions" for the row to the persmission you calculated in the step before.

Hope this helps.

@VChernenkoRT
Copy link

VChernenkoRT commented Apr 10, 2021

Is there a guide how to do this?

First create a link share, you shoudl get sth like "https://NEXTCLOUDDOMAIN/s/TOKEN". You'll need the token later.

In Constants.php you can find the permissions

public const PERMISSION_CREATE = 4;
public const PERMISSION_READ = 1;
public const PERMISSION_UPDATE = 2;
public const PERMISSION_DELETE = 8;
public const PERMISSION_SHARE = 16;
public const PERMISSION_ALL = 31;

Just sum the values to "build" your permission. E.g: Create + read -> 4 + 1 -> 5

Then open your database with phpmyadmin or sth, open the table "oc_share" and search for the row where the token-column matches your token.
Then set the column "permissions" for the row to the persmission you calculated in the step before.

Hope this helps.

how fluent, user-friendly is this solution for generic issue noted 5 or more years ago.
disappointed 1 day after installation by this too

... I wish I could do it myself by simply editing few lines in apps/files_sharing/ but there is some "build" magic involved between me and the solution =(

@VChernenkoRT
Copy link

VChernenkoRT commented Apr 10, 2021

I have changed files_sharing_tab.js* files for PUT /ocs/v2.php/apps/files_sharing/api/v1/shares/10 with permissions: "23" or "7" payload, but server still response with permissions: 31.
This could be overriden by commenting a line after "normalize to correct public upload permissions" comment in apps/files_sharing/lib/Controller/ShareAPIController.php @~1080 line
someone plz do something for this to be fixed+released <3
could possibly mess with 955635c

@Ashu11-A
Copy link

É incrivelmente decepcionante como isso não foi implementado ainda, era pra ter saído no Nextcloud 15? Mas se passaram anos e ainda não foi implementado por pura preguiça.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1. to develop Accepted and waiting to be taken care of design Design, UI, UX, etc. enhancement feature: sharing
Projects
None yet
Development

No branches or pull requests