Revert "shorten join url"

This reverts commit 6f2dac8b0b.
pull/9/head
sualko 2020-04-26 13:43:16 +02:00
parent 6f2dac8b0b
commit a888627e14
3 changed files with 4 additions and 4 deletions

View File

@ -5,7 +5,7 @@ return [
'room_api' => ['url' => '/api/0.1/rooms'] 'room_api' => ['url' => '/api/0.1/rooms']
], ],
'routes' => [ 'routes' => [
['name' => 'join#index', 'url' => '/{token}', 'verb' => 'GET', 'requirements' => array('token' => '\w[16,]')], ['name' => 'join#index', 'url' => '/b/{token}', 'verb' => 'GET'],
['name' => 'room_api#preflighted_cors', 'url' => '/api/0.1/{path}', ['name' => 'room_api#preflighted_cors', 'url' => '/api/0.1/{path}',
'verb' => 'OPTIONS', 'requirements' => ['path' => '.+']] 'verb' => 'OPTIONS', 'requirements' => ['path' => '.+']]
] ]

View File

@ -73,12 +73,12 @@ const RoomRow: React.FC<Props> = (props) => {
return ( return (
<tr key={room.id}> <tr key={room.id}>
<td className="share icon-col"> <td className="share icon-col">
<CopyToClipboard text={window.location.origin + api.getUrl(`${room.uid}`)}> <CopyToClipboard text={window.location.origin + api.getUrl(`b/${room.uid}`)}>
<span className="icon icon-clippy icon-visible copy-to-clipboard" ></span> <span className="icon icon-clippy icon-visible copy-to-clipboard" ></span>
</CopyToClipboard> </CopyToClipboard>
</td> </td>
<td className="start icon-col"> <td className="start icon-col">
<a href={api.getUrl(`${room.uid}`)} className="icon icon-play icon-visible" target="_blank" rel="noopener noreferrer"></a> <a href={api.getUrl(`b/${room.uid}`)} className="icon icon-play icon-visible" target="_blank" rel="noopener noreferrer"></a>
</td> </td>
<td className="name"> <td className="name">
{edit('name')} {edit('name')}

View File

@ -51,7 +51,7 @@ $(() => {
async function share(path: string, filename: string, roomUid) { async function share(path: string, filename: string, roomUid) {
const id = await createShare(path); const id = await createShare(path);
const shareUrl = await configureShare(id); const shareUrl = await configureShare(id);
const joinUrl = generateUrl('/apps/bbb/{uid}?u={url}&filename={filename}', { const joinUrl = generateUrl('/apps/bbb/b/{uid}?u={url}&filename={filename}', {
uid: roomUid, uid: roomUid,
url: shareUrl + '/download', url: shareUrl + '/download',
filename filename