mirror of
https://github.com/nextcloud/passman.git
synced 2025-01-06 07:22:03 +08:00
Add public share page
This commit is contained in:
parent
3dc19d2371
commit
2311247064
3 changed files with 12 additions and 1 deletions
|
@ -21,6 +21,7 @@ return [
|
||||||
'routes' => [
|
'routes' => [
|
||||||
['name' => 'page#index', 'url' => '/', 'verb' => 'GET'],
|
['name' => 'page#index', 'url' => '/', 'verb' => 'GET'],
|
||||||
['name' => 'page#bookmarklet', 'url' => '/bookmarklet', 'verb' => 'GET'],
|
['name' => 'page#bookmarklet', 'url' => '/bookmarklet', 'verb' => 'GET'],
|
||||||
|
['name' => 'page#publicSharePage', 'url' => '/share/public', 'verb' => 'GET'],
|
||||||
|
|
||||||
//Vault
|
//Vault
|
||||||
['name' => 'vault#listVaults', 'url' => '/api/v2/vaults', 'verb' => 'GET'],
|
['name' => 'vault#listVaults', 'url' => '/api/v2/vaults', 'verb' => 'GET'],
|
||||||
|
|
|
@ -48,7 +48,16 @@ class PageController extends Controller {
|
||||||
*/
|
*/
|
||||||
public function bookmarklet($url='',$title='') {
|
public function bookmarklet($url='',$title='') {
|
||||||
$params = array('url' => $url, 'label' => $title);
|
$params = array('url' => $url, 'label' => $title);
|
||||||
return new TemplateResponse('passman', 'bookmarklet', $params);
|
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @NoAdminRequired
|
||||||
|
* @NoCSRFRequired
|
||||||
|
* @PublicPage
|
||||||
|
*/
|
||||||
|
public function publicSharePage($shareKey) {
|
||||||
|
return new TemplateResponse('passman', 'public_share');
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
1
templates/public_share.php
Normal file
1
templates/public_share.php
Normal file
|
@ -0,0 +1 @@
|
||||||
|
Public shared credential
|
Loading…
Reference in a new issue