Repository navigation
Permalinks - #24434
Permalinks#24434
Conversation
|
By analyzing the blame information on this pull request, we identified @ChristophWurst, @LukasReschke and @tanghus to be potential reviewers |
|
Note: there is no UI yet to create such links, for testing please create these manually. |
|
|
Okay, delay aside, I found a way to replace the URL after the current folder was loaded. So if you observe the URL (when no fileid) present, it will appear without fileid until the folder is loaded, then the fileid will pop into the URL.
The fileid will now appear in all URLs under "All files" ! |
|
Basically if we detect a URL change, and the only change is appending the fileid, then we use |
|
|
|
Okay, looks like |
|
|
|
well, actually... activity app could also use the new URL format |
|
Just added: email about internal share now uses the shortened permalink. Would be good to get some feedback whether it works usability-wise @owncloud/designers |
|
More fixes:
|
|
There was a problem hiding this comment.
Undefined index in the unit test :)
10:20:05 1) MailNotificationsTest::testSendInternalShareMail
10:20:05 Undefined index: item_source
10:20:05
10:20:05 /ssd/jenkins/workspace/server-master-linux-php7-ci/database/sqlite/label/SLAVE/lib/private/Share/MailNotifications.php:124
10:20:05 /ssd/jenkins/workspace/server-master-linux-php7-ci/database/sqlite/label/SLAVE/tests/lib/share/MailNotificationsTest.php:250
|
Most useful feature ever. Code looks good and works. Great stuff!!!! 🚀 💘 ❤️ 🎉 |
|
I think this is ready for review @MorrisJobke @nickvergessen @guruz @rullzer @icewind1991 @schiesbn @VicDeo @georgehrke @Xenopathic @blizzz @ChristophWurst @LukasReschke mind checking the endpoint ? (disabled CSRF, etc) |
That's fine :) |
|
|
I love the local link thingy... but can't we just copy it to the clipboard directly? |
|
@rullzer copy to clipboard requires flash, see how Github does it with its copy link button. No flash, no button. |
|
Aaaah ok then never mind :) |
|
@rullzer (else we'd probably have that button for all link fields) |
There was a problem hiding this comment.
So fileid always has preference if it is there. Sounds good
|
You can also use There are some wrapper libs that have fallbacks like https://clipboardjs.com |
There was a problem hiding this comment.
I was thinking... maybe it is good to loop over all files (if a file is shared via multiple ways)... and pick the one with the highest permission?
There was a problem hiding this comment.
Of course harder then it sounds because which do you pick if 1 has edit and 1 has share permissions.
There was a problem hiding this comment.
Also not that common scenario...
There was a problem hiding this comment.
@rullzer yeah good point, possibly something for later.
Also I thought about adding a "trashbin" route in case the file is detected in trash instead, but something for later also.
|
@georgehrke I'll make a ticket to research that. Could definitely be useful for the many link-copy locations we have: #24472 |
The following routes will redirect to the files app and display the matching folder. If the fileid is a file, it will scroll to it. - http://localhost/owncloud/index.php/f/$fileid - http://localhost/owncloud/index.php/files/?dir=somedir&fileid=$fileid
|
|
Fixed back button and unit test. |
|
👍 very very cool stuff! |
|
I cannot find the permalink in the curren owncloud version. What this feature removed? |
|
@LiamHD This feature will be released with ownCloud 9.1 |
|
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |

Fixes #11732
The following routes will redirect to the files app and display the
matching folder. If the fileid is a file, it will scroll to it.
Missing parts and challenges: