nextcloud / nextcloud/picker

Hide creating a new file as it can not be edited

Open
#57 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
JavaScript
Stars
8
Forks
1
PR merge metrics
No merged PRs in 30d

Description

Beyond uploading a file, the picker app also offers to create a document.

Expected behaviour

If we offer to create a document (text, table, presentation, ...), then this should open the editor.

Actual behaviour

The open editor dialog does not start. This is independent if a user is logged in or anonymous.

XHRPUT
https://cloud.myorg.net/public.php/dav/files/EcwtD73DcwgKDoE/Testdatei2.md
[HTTP/2 400  152ms]

Uncaught (in promise) Error: Invalid response: 400 
    et index.js:2
    tt index.js:2
    u index.js:2
    promise callback*1822/en< index.js:2
    en index.js:2
    putFileContents index.js:2
    createFile TemplatePicker.vue:161
    onSubmit TemplatePicker.vue:214
    open TemplatePicker.vue:106
    open newFromTemplate.ts:28
    handler newFromTemplate.ts:65
    onClick index-DdKmqUaK.mjs:1408
    click index-DdKmqUaK.mjs:1516
    VueJS 4
    onClick actionText-fFcUPi2g.mjs:77
    handleClick NcActionButton-rjMoymt-.mjs:143
    VueJS 33
index.js:2:80655
Server configuration

Database: 10.11.15

PHP version: 8.3

Nextcloud version: 31.0.10

Screenshots

Being able to start writing a document would be a nice additional feature, but as reported above, it does not work.

Image

If I change the link to editable, then I see the full folder including the permission to delete other documents, which likely is not intended in a drop folder.

Image

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in TemplatePicker.vue at createFile, onSubmit, and open, then follow the newFromTemplate.ts entry points shown in the stack trace. Reproduce the 400 response for creating a document and inspect how the picker handles the create-document action. Done means the documented action has an intentional, working behavior without the failed editor-opening request.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.