2014-05-14 07:08:27 +08:00
|
|
|
<?php
|
|
|
|
|
|
|
|
/**
|
|
|
|
* ownCloud - RainLoop mail plugin
|
|
|
|
*
|
|
|
|
* @author RainLoop Team
|
|
|
|
* @copyright 2014 RainLoop Team
|
|
|
|
*
|
|
|
|
* https://github.com/RainLoop/rainloop-webmail/tree/master/build/owncloud
|
|
|
|
*/
|
|
|
|
|
|
|
|
OCP\User::checkLoggedIn();
|
|
|
|
OCP\App::checkAppEnabled('rainloop');
|
|
|
|
|
|
|
|
OCP\Util::addScript('rainloop', 'personal');
|
|
|
|
|
2014-05-30 09:42:22 +08:00
|
|
|
$sUser = OCP\User::getUser();
|
2014-05-14 07:08:27 +08:00
|
|
|
|
2014-05-30 09:42:22 +08:00
|
|
|
$oTemplate = new OCP\Template('rainloop', 'personal');
|
2014-05-14 07:08:27 +08:00
|
|
|
|
2014-05-30 09:42:22 +08:00
|
|
|
$sEmail = OCP\Config::getUserValue($sUser, 'rainloop', 'rainloop-email', '');
|
2014-05-14 07:08:27 +08:00
|
|
|
|
2014-05-30 09:42:22 +08:00
|
|
|
$oTemplate->assign('rainloop-email', $sEmail);
|
|
|
|
$oTemplate->assign('rainloop-login', OCP\Config::getUserValue($sUser, 'rainloop', 'rainloop-login', ''));
|
2014-05-14 07:08:27 +08:00
|
|
|
|
2014-05-30 09:42:22 +08:00
|
|
|
$sPass = OCP\Config::getUserValue($sUser, 'rainloop', 'rainloop-password', '');
|
|
|
|
$oTemplate->assign('rainloop-password', 0 === strlen($sPass) && 0 === strlen($sEmail) ? '' : '******');
|
2014-05-14 07:08:27 +08:00
|
|
|
|
|
|
|
return $oTemplate->fetchPage();
|