mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-09-02 22:17:03 +03:00
Automatic login with ownCloud credentials
This commit is contained in:
parent
86f282f885
commit
2f52f826bd
21 changed files with 259 additions and 152 deletions
|
|
@ -9,9 +9,19 @@
|
|||
* https://github.com/RainLoop/owncloud
|
||||
*/
|
||||
|
||||
OC::$CLASSPATH['OC_RainLoop_Helper'] = OC_App::getAppPath('rainloop') . '/lib/RainLoopHelper.php';
|
||||
|
||||
OCP\App::registerAdmin('rainloop', 'admin');
|
||||
OCP\App::registerPersonal('rainloop', 'personal');
|
||||
|
||||
$bAutologin = OCP\Config::getAppValue('rainloop', 'rainloop-autologin', false);
|
||||
if ('on' === $bAutologin)
|
||||
{
|
||||
OCP\Util::connectHook('OC_User', 'post_login', 'OC_RainLoop_Helper', 'login');
|
||||
OCP\Util::connectHook('OC_User', 'logout', 'OC_RainLoop_Helper', 'logout');
|
||||
OCP\Util::connectHook('OC_User', 'post_setPassword', 'OC_RainLoop_Helper', 'changePassword');
|
||||
}
|
||||
|
||||
OCP\Util::addScript('rainloop', 'rainloop');
|
||||
|
||||
OCP\App::addNavigationEntry(array(
|
||||
|
|
@ -19,5 +29,5 @@ OCP\App::addNavigationEntry(array(
|
|||
'order' => 10,
|
||||
'href' => OCP\Util::linkTo('rainloop', 'index.php'),
|
||||
'icon' => OCP\Util::imagePath('rainloop', 'mail.png'),
|
||||
'name' => 'RainLoop'
|
||||
'name' => 'Email'
|
||||
));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue