-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Move/copy file picker: Remeber last destination and start in current folder #12381
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
Conversation
|
please review @jancborchardt |
|
Aaaalright @rummatee, sorry for the belated reply but welcome to Nextcloud! 👋 🎉 Will get right to reviewing, also cc other @nextcloud/designers, and this definitely also needs a JS review from @nextcloud/javascript. |
|
@rummatee also, could you rebase onto latest master, as there were some changes? Let me know if you have questions how to do that – I generally also search and find the answer on StackOverflow 😅 |
|
Hmm, just tested it and it doesn’t seem to work? Still starts in the root folder every time. Do I need to compile anything? :) |
indeed I would appreciate some help on this. I see that there is a button to resolve conflicts, but when I do that, it shows me a warning that I am committing to master and I was afraid to confirm that.
I don't think it should require to compile anything. I just tested it again and for me it works. I created a folder called "test" and a file in this folder. When I want to move this file the dialog starts in folder "test". |
It’s fine – that is referring to your master branch. It’s not possible for anyone to commit directly to master or any stable branches as we have branch protection enabled. :) |
kesselb
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great improvement 👍
okay thank you for clarifying that there are 2 different menus that need this feature. The new commit should add it also to the multiselect menu. |
|
Thanks @rummatee! We definitely need a code review on this from someone in @nextcloud/javascript :) |
|
Select two or more files, use top three dot menu and pick "move or copy". Please note the two buttons "move" and "copy". When you go a directory higher or lower the button label is changed like below even when you are in the same folder again. I think the button labels should be the same @jancborchardt |
Yes, true. Is it possible to make it so that in the folder where the files are right now, they are simply "Copy" and "Move"? Ideally they should also be disabled there, and a tooltip (also visible on click) on the buttons should say "This folder is the current place of the files." |
Well that would be related to issue #11313 #9931 and PR #10825 so I am not completely sure how these would interact. Of course it would be possible to change the label or grey out the buttons, but maybe it is better to leave that out of this PR to avoid conflicts with other PRs? |
Good point, yes let’s do it separately! Still waiting for a code review from @nextcloud/javascript :) @juliushaertl @danxuliu @kevgathuku @ChristophWurst anyone? |
02dda9c to
00032b2
Compare
ChristophWurst
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
:)
apps/files/js/filelist.js
Outdated
|
|
||
| var actions = this.isSelectedMovable() ? OC.dialogs.FILEPICKER_TYPE_COPY_MOVE : OC.dialogs.FILEPICKER_TYPE_COPY; | ||
| var dialogDir = self.getCurrentDirectory(); | ||
| if (typeof self.dirInfo.dirLastCopiedTo !== undefined) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| if (typeof self.dirInfo.dirLastCopiedTo !== undefined) { | |
| if (typeof self.dirInfo.dirLastCopiedTo !== 'undefined') { |
17d9b9a to
6aa505b
Compare
ChristophWurst
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code looks good!
|
Here too @rullzer @MorrisJobke what about the Drone failure? Is it just unrelated? |
|
The failures are fixed on master already (issue with the PHP 7.0 to 7.3 compatibility). Either rebase or we can just assume that they will work and this is then ready for review and merge. |
|
@rummatee It seems that your force push closed this PR 🙈 Could you open a new one? |
|
yeah, I didn't see the rebase conflicts and accidentally pushed to remove all my commits |
|
hmm does it show my commits again when I click on reopen? |
now that I reopened it, it doesn't seem to run the checks. Do I have to create a new PR? |
Or rebase again 🙈 |
db81573 to
cc8d539
Compare
juliusknorr
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Small nitpick. Otherwise works as expected and the code looks fine 👍
Signed-off-by: Florian Schunk <[email protected]>
Signed-off-by: Florian Schunk <[email protected]>
Signed-off-by: Florian Schunk <[email protected]>
Signed-off-by: Florian Schunk <[email protected]>
|
Signed-off messages are fine. DCO bot seems to have some issues. 😉 |




This my first time contributing to Nextcloud and using Pull Requests, so please tell me, if I did something wrong.
This Pull Request intends to solve Issue #11314 .
I changed the signature of the filepicker, but made sure that the behavior doesn't change in case it gets called without the additional argument.