Release fixes

Additional branding options
fixes (php mail functionality)
This commit is contained in:
RainLoop Team 2015-05-23 02:04:34 +04:00
parent baae7f2900
commit 8f55b5c554
14 changed files with 351 additions and 159 deletions

View file

@ -1060,7 +1060,32 @@
oTop = null,
oBottom = null,
fResizeFunction = function (oEvent, oObject) {
fResizeCreateFunction = function (oEvent) {
if (oEvent && oEvent.target)
{
var oResizableHandle = $(oEvent.target).find('.ui-resizable-handle');
oResizableHandle
.on('mousedown', function () {
Globals.$html.addClass('rl-resizer');
})
.on('mouseup', function () {
Globals.$html.removeClass('rl-resizer');
})
;
}
},
fResizeStartFunction = function () {
Globals.$html.addClass('rl-resizer');
},
fResizeResizeFunction = _.debounce(function () {
Globals.$html.addClass('rl-resizer');
}, 500, true),
fResizeStopFunction = function (oEvent, oObject) {
Globals.$html.removeClass('rl-resizer');
if (oObject && oObject.size && oObject.size.height)
{
Local.set(sClientSideKeyName, oObject.size.height);
@ -1076,7 +1101,10 @@
'minHeight': iMinHeight,
'maxHeight': iMaxHeight,
'handles': 's',
'stop': fResizeFunction
'create': fResizeCreateFunction,
'resize': fResizeResizeFunction,
'start': fResizeStartFunction,
'stop': fResizeStopFunction
},
fSetHeight = function (iHeight) {
@ -1169,8 +1197,29 @@
fSetWidth(iWidth > iMinWidth ? iWidth : iMinWidth);
}
},
fResizeCreateFunction = function (oEvent) {
if (oEvent && oEvent.target)
{
var oResizableHandle = $(oEvent.target).find('.ui-resizable-handle');
fResizeFunction = function (oEvent, oObject) {
oResizableHandle
.on('mousedown', function () {
Globals.$html.addClass('rl-resizer');
})
.on('mouseup', function () {
Globals.$html.removeClass('rl-resizer');
})
;
}
},
fResizeResizeFunction = _.debounce(function () {
Globals.$html.addClass('rl-resizer');
}, 500, true),
fResizeStartFunction = function () {
Globals.$html.addClass('rl-resizer');
},
fResizeStopFunction = function (oEvent, oObject) {
Globals.$html.removeClass('rl-resizer');
if (oObject && oObject.size && oObject.size.width)
{
Local.set(sClientSideKeyName, oObject.size.width);
@ -1192,7 +1241,10 @@
'minWidth': iMinWidth,
'maxWidth': 350,
'handles': 'e',
'stop': fResizeFunction
'create': fResizeCreateFunction,
'resize': fResizeResizeFunction,
'start': fResizeStartFunction,
'stop': fResizeStopFunction
});
Events.sub('left-panel.off', function () {

View file

@ -196,6 +196,8 @@
{
this.modeToggle(true);
sHtml = sHtml.replace(/<[pP][^>]*><\/[pP]>/g, '');
try {
this.editor.setData(sHtml);
} catch (e) {}

View file

@ -867,6 +867,7 @@
sText = sHtml
.replace(/\u0002([\s\S]*)\u0002/gm, '\u200C$1\u200C')
.replace(/<[pP][^>]*><\/[pP]>/g, '')
.replace(/<pre[^>]*>([\s\S\r\n]*)<\/pre>/gmi, convertPre)
.replace(/[\s]+/gm, ' ')
.replace(/((?:href|data)\s?=\s?)("[^"]+?"|'[^']+?')/gmi, fixAttibuteValue)

View file

@ -42,6 +42,9 @@
this.userLogoMessage = ko.observable(Settings.settingsGet('UserLogoMessage') || '');
this.userLogoMessage.trigger = ko.observable(Enums.SaveSettingsStep.Idle);
this.userIframeMessage = ko.observable(Settings.settingsGet('UserIframeMessage') || '');
this.userIframeMessage.trigger = ko.observable(Enums.SaveSettingsStep.Idle);
this.userLogoTitle = ko.observable(Settings.settingsGet('UserLogoTitle') || '');
this.userLogoTitle.trigger = ko.observable(Enums.SaveSettingsStep.Idle);

View file

@ -69,6 +69,22 @@ html.rl-no-preview-pane {
color: #DA4F49;
}
.b-message-view-iframe {
}
.b-message-view-iframe-backdrop {
display: none;
background: transparent;
position: absolute;
width: 100%;
height: 100%;
top: 0px;
left: 0px;
right: 0px;
bottom: 0px;
opacity: .1;
}
.content {
-webkit-overflow-scrolling: touch;
}
@ -453,6 +469,10 @@ html.rl-no-preview-pane {
}
}
html.rl-resizer .b-message-view-iframe-backdrop {
display: block !important;
}
html.rl-no-preview-pane .messageView {
.toolbar {
padding-left: @rlMainBorderSize;

View file

@ -73,6 +73,7 @@
this.allowMessageListActions = !!Settings.capa(Enums.Capa.MessageListActions);
this.logoImg = Utils.trim(Settings.settingsGet('UserLogoMessage'));
this.logoIframe = Utils.trim(Settings.settingsGet('UserIframeMessage'));
this.attachmentsActions = AppStore.attachmentsActions;

View file

@ -2,7 +2,7 @@
"name": "RainLoop",
"title": "RainLoop Webmail",
"version": "1.9.1",
"release": "330",
"release": "333",
"description": "Simple, modern & fast web-based email client",
"homepage": "http://rainloop.net",
"main": "gulpfile.js",
@ -40,7 +40,7 @@
"plugins"
],
"readmeFilename": "README.md",
"ownCloudPackageVersion": "4.2",
"ownCloudPackageVersion": "4.3",
"engines": {
"node": ">= 0.10.0"
},

View file

@ -730,6 +730,64 @@ END;
return $sValue;
}
/**
* @param string $sIncHeaders
* @param string $aHeadersToRemove = array()
*
* @return string
*/
public static function RemoveHeaderFromHeaders($sIncHeaders, $aHeadersToRemove = array())
{
$sResultHeaders = $sIncHeaders;
if (\is_array($aHeadersToRemove) && 0 < \count($aHeadersToRemove))
{
$aHeadersToRemove = \array_map('strtolower', $aHeadersToRemove);
$sIncHeaders = \preg_replace('/[\r\n]+/', "\n", $sIncHeaders);
$aHeaders = \explode("\n", $sIncHeaders);
$bSkip = false;
$aResult = array();
foreach ($aHeaders as $sLine)
{
if (0 < \strlen($sLine))
{
$sFirst = $sLine{1};
if (' ' === $sFirst || "\t" === $sFirst)
{
if (!$bSkip)
{
$aResult[] = $sLine;
}
}
else
{
$bSkip = false;
$aParts = \explode(':', $sLine, 2);
if (!empty($aParts) && !empty($aParts[0]))
{
if (\in_array(\strtolower(\trim($aParts[0])), $aHeadersToRemove))
{
$bSkip = true;
}
else
{
$aResult[] = $sLine;
}
}
}
}
}
$sResultHeaders = \implode("\r\n", $aResult);
}
return $sResultHeaders;
}
/**
* @param string $sEncodeType
* @param string $sValue

View file

@ -716,7 +716,8 @@ class MailClient
$sHighestModSeq = isset($aFolderStatus[\MailSo\Imap\Enumerations\FolderResponseStatus::HIGHESTMODSEQ])
? (string) $aFolderStatus[\MailSo\Imap\Enumerations\FolderResponseStatus::HIGHESTMODSEQ] : '';
if ($this->IsGmail())
if ($this->IsGmail() &&
('INBOX' === $sFolderName || '[gmail]' === \strtolower(\substr($sFolderName, 0, 7))))
{
$oFolder = $this->oImapClient->FolderCurrentInformation();
if ($oFolder && null !== $oFolder->Exists && $oFolder->FolderName === $sFolderName)
@ -846,7 +847,8 @@ class MailClient
$aFlags = array();
$bSelect = false;
if ($this->IsGmail())
if ($this->IsGmail() &&
('INBOX' === $sFolderName || '[gmail]' === \strtolower(\substr($sFolderName, 0, 7))))
{
$this->oImapClient->FolderSelect($sFolderName);
$bSelect = true;
@ -1336,11 +1338,8 @@ class MailClient
$aCriteriasResult[] = \gmdate('j-M-Y', $iTimeFilter > $iDateStampFrom ?
$iTimeFilter : $iDateStampFrom);
if (0 < $iTimeFilter && $iTimeFilter > $iDateStampFrom)
{
$iTimeFilter = 0;
}
}
if (0 < $iDateStampTo)
{

View file

@ -1447,7 +1447,6 @@ class Actions
}
$oSettings = null;
$oSettingsLocal = null;
if (!$bAdmin)
{
@ -1504,7 +1503,7 @@ class Actions
}
$oSettings = $this->SettingsProvider()->Load($oAccount);
$oSettingsLocal = $this->SettingsProvider(true)->Load($oAccount);
if (!$oAccount->IsAdditionalAccount() && !empty($aResult['WelcomePageUrl']) &&
('once' === $aResult['WelcomePageDisplay'] || 'always' === $aResult['WelcomePageDisplay']))
@ -1616,15 +1615,15 @@ class Actions
$aResult['Auth'] = $this->IsAdminLoggined(false);
if ($aResult['Auth'])
{
$aResult['AdminLogin'] = $oConfig->Get('security', 'admin_login', '');
$aResult['AdminDomain'] = APP_SITE;
$aResult['AdminLogin'] = (string) $oConfig->Get('security', 'admin_login', '');
$aResult['UseTokenProtection'] = (bool) $oConfig->Get('security', 'csrf_protection', true);
$aResult['EnabledPlugins'] = (bool) $oConfig->Get('plugins', 'enable', false);
$aResult['VerifySslCertificate'] = !!$oConfig->Get('ssl', 'verify_certificate', false);
$aResult['AllowSelfSigned'] = !!$oConfig->Get('ssl', 'allow_self_signed', true);
$aResult['VerifySslCertificate'] = (bool) $oConfig->Get('ssl', 'verify_certificate', false);
$aResult['AllowSelfSigned'] = (bool) $oConfig->Get('ssl', 'allow_self_signed', true);
$aDrivers = \class_exists('PDO') ? \PDO::getAvailableDrivers() : array();
$aDrivers = \class_exists('PDO') ? \PDO::getAvailableDrivers() : null;
$aResult['MySqlIsSupported'] = \is_array($aDrivers) ? \in_array('mysql', $aDrivers) : false;
$aResult['SQLiteIsSupported'] = \is_array($aDrivers) ? \in_array('sqlite', $aDrivers) : false;
$aResult['PostgreSqlIsSupported'] = \is_array($aDrivers) ? \in_array('pgsql', $aDrivers) : false;
@ -1632,11 +1631,11 @@ class Actions
$aResult['ContactsEnable'] = (bool) $oConfig->Get('contacts', 'enable', false);
$aResult['ContactsSharing'] = (bool) $oConfig->Get('contacts', 'allow_sharing', false);
$aResult['ContactsSync'] = (bool) $oConfig->Get('contacts', 'allow_sync', false);
$aResult['ContactsPdoType'] = $this->ValidateContactPdoType(\trim($this->Config()->Get('contacts', 'type', 'sqlite')));
$aResult['ContactsPdoType'] = (string) $this->ValidateContactPdoType(\trim($this->Config()->Get('contacts', 'type', 'sqlite')));
$aResult['ContactsPdoDsn'] = (string) $oConfig->Get('contacts', 'pdo_dsn', '');
$aResult['ContactsPdoType'] = (string) $oConfig->Get('contacts', 'type', '');
$aResult['ContactsPdoUser'] = (string) $oConfig->Get('contacts', 'pdo_user', '');
$aResult['ContactsPdoPassword'] = APP_DUMMY;
$aResult['ContactsPdoPassword'] = (string) APP_DUMMY;
$aResult['AllowGoogleSocial'] = (bool) $oConfig->Get('social', 'google_enable', false);
$aResult['AllowGoogleSocialAuth'] = (bool) $oConfig->Get('social', 'google_enable_auth', true);
@ -1658,11 +1657,11 @@ class Actions
$aResult['AllowDropboxSocial'] = (bool) $oConfig->Get('social', 'dropbox_enable', false);
$aResult['DropboxApiKey'] = (string) $oConfig->Get('social', 'dropbox_api_key', '');
$aResult['SubscriptionEnabled'] = \MailSo\Base\Utils::ValidateDomain($aResult['AdminDomain']);
$aResult['SubscriptionEnabled'] = (bool) \MailSo\Base\Utils::ValidateDomain($aResult['AdminDomain']);
// || \MailSo\Base\Utils::ValidateIP($aResult['AdminDomain']);
$aResult['WeakPassword'] = $oConfig->ValidatePassword('12345');
$aResult['CoreAccess'] = $this->rainLoopCoreAccess();
$aResult['WeakPassword'] = (bool) $oConfig->ValidatePassword('12345');
$aResult['CoreAccess'] = (bool) $this->rainLoopCoreAccess();
$aResult['PhpUploadSizes'] = array(
'upload_max_filesize' => \ini_get('upload_max_filesize'),
@ -1690,6 +1689,7 @@ class Actions
$aResult['Themes'] = $this->GetThemes();
$aResult['Languages'] = $this->GetLanguages(false);
$aResult['LanguagesAdmin'] = $this->GetLanguages(true);
$aResult['AllowLanguagesOnSettings'] = (bool) $oConfig->Get('webmail', 'allow_languages_on_settings', true);
$aResult['AllowLanguagesOnLogin'] = (bool) $oConfig->Get('login', 'allow_languages_on_login', true);
$aResult['AttachmentLimit'] = ((int) $oConfig->Get('webmail', 'attachment_size_limit', 10)) * 1024 * 1024;
@ -1714,28 +1714,34 @@ class Actions
$aResult['UserBackgroundName'] = '';
$aResult['UserBackgroundHash'] = '';
if (!$bAdmin && $oSettings instanceof \RainLoop\Settings &&
$oSettingsLocal instanceof \RainLoop\Settings &&
$oAccount)
if (!$bAdmin && $oAccount instanceof \RainLoop\Model\Account)
{
$aResult['ParentEmail'] = $oAccount->ParentEmail();
$oSettingsLocal = $this->SettingsProvider(true)->Load($oAccount);
if ($oSettingsLocal instanceof \RainLoop\Settings)
{
// if ($this->GetCapa(false, \RainLoop\Enumerations\Capa::FOLDERS, $oAccount))
$aResult['SentFolder'] = (string) $oSettingsLocal->GetConf('SentFolder', '');
$aResult['DraftFolder'] = (string) $oSettingsLocal->GetConf('DraftFolder', '');
$aResult['SpamFolder'] = (string) $oSettingsLocal->GetConf('SpamFolder', '');
$aResult['TrashFolder'] = (string) $oSettingsLocal->GetConf('TrashFolder', '');
$aResult['ArchiveFolder'] = (string) $oSettingsLocal->GetConf('ArchiveFolder', '');
$aResult['NullFolder'] = (string) $oSettingsLocal->GetConf('NullFolder', '');
}
if ($this->GetCapa(false, \RainLoop\Enumerations\Capa::SETTINGS, $oAccount))
{
if ($oSettings instanceof \RainLoop\Settings)
{
if ($oConfig->Get('webmail', 'allow_languages_on_settings', true))
{
$sLanguage = $oSettings->GetConf('Language', $sLanguage);
$sLanguage = (string) $oSettings->GetConf('Language', $sLanguage);
}
if ($this->GetCapa(false, \RainLoop\Enumerations\Capa::THEMES, $oAccount))
{
$sTheme = $oSettingsLocal->GetConf('Theme', $sTheme);
}
$aResult['SentFolder'] = $oSettingsLocal->GetConf('SentFolder', '');
$aResult['DraftFolder'] = $oSettingsLocal->GetConf('DraftFolder', '');
$aResult['SpamFolder'] = $oSettingsLocal->GetConf('SpamFolder', '');
$aResult['TrashFolder'] = $oSettingsLocal->GetConf('TrashFolder', '');
$aResult['ArchiveFolder'] = $oSettingsLocal->GetConf('ArchiveFolder', '');
$aResult['NullFolder'] = $oSettingsLocal->GetConf('NullFolder', '');
$aResult['EditorDefaultType'] = $oSettings->GetConf('EditorDefaultType', $aResult['EditorDefaultType']);
$aResult['EditorDefaultType'] = (string) $oSettings->GetConf('EditorDefaultType', $aResult['EditorDefaultType']);
$aResult['ShowImages'] = (bool) $oSettings->GetConf('ShowImages', $aResult['ShowImages']);
$aResult['ContactsAutosave'] = (bool) $oSettings->GetConf('ContactsAutosave', $aResult['ContactsAutosave']);
$aResult['MPP'] = (int) $oSettings->GetConf('MPP', $aResult['MPP']);
@ -1745,9 +1751,6 @@ class Actions
$aResult['AutoLogout'] = (int) $oSettings->GetConf('AutoLogout', $aResult['AutoLogout']);
$aResult['Layout'] = (int) $oSettings->GetConf('Layout', $aResult['Layout']);
$aResult['UseThreads'] = (bool) $oSettingsLocal->GetConf('UseThreads', $aResult['UseThreads']);
$aResult['ReplySameFolder'] = (bool) $oSettingsLocal->GetConf('ReplySameFolder', $aResult['ReplySameFolder']);
if (!$this->GetCapa(false, \RainLoop\Enumerations\Capa::AUTOLOGOUT, $oAccount))
{
$aResult['AutoLogout'] = 0;
@ -1764,9 +1767,20 @@ class Actions
// }
}
$aResult['EnableTwoFactor'] = !!$oSettings->GetConf('EnableTwoFactor', $aResult['EnableTwoFactor']);
$aResult['EnableTwoFactor'] = (bool) $oSettings->GetConf('EnableTwoFactor', $aResult['EnableTwoFactor']);
}
$aResult['ParentEmail'] = $oAccount->ParentEmail();
if ($oSettingsLocal instanceof \RainLoop\Settings)
{
$aResult['UseThreads'] = (bool) $oSettingsLocal->GetConf('UseThreads', $aResult['UseThreads']);
$aResult['ReplySameFolder'] = (bool) $oSettingsLocal->GetConf('ReplySameFolder', $aResult['ReplySameFolder']);
if ($this->GetCapa(false, \RainLoop\Enumerations\Capa::THEMES, $oAccount))
{
$sTheme = (string) $oSettingsLocal->GetConf('Theme', $sTheme);
}
}
}
}
$sStaticCache = \md5(APP_VERSION.$this->Plugins()->Hash());
@ -1833,7 +1847,7 @@ class Actions
if (false !== \strpos($sAcceptLang, ','))
{
$aParts = \explode(',', $sAcceptLang, 2);
$sLang = !empty($aParts[0]) ? \trim(\strtolower($aParts[0])) : '';
$sLang = empty($aParts[0]) ? '' : \trim(\strtolower($aParts[0]));
}
return $sLang;
@ -2398,12 +2412,14 @@ class Actions
/**
* @param \RainLoop\Model\Account $oAccount
* @param bool $bAllowIdentities = false
*
* @return array
*/
public function GetIdentities($oAccount, $bAllowIdentities = false)
public function GetIdentities($oAccount)
{
$bAllowIdentities = $this->GetCapa(false,
\RainLoop\Enumerations\Capa::IDENTITIES, $oAccount);
$aIdentities = array();
if ($oAccount)
{
@ -2491,6 +2507,7 @@ class Actions
public function GetIdentityByID($oAccount, $sID, $bFirstOnEmpty = false)
{
$aIdentities = $this->GetIdentities($oAccount);
if (\is_array($aIdentities))
{
foreach ($aIdentities as $oIdentity)
@ -2544,12 +2561,13 @@ class Actions
/**
* @param \RainLoop\Model\Account $oAccount
* @param array $aIdentities = array()
* @param bool $bAllowIdentities = false
*
* @return array
*/
public function SetIdentities($oAccount, $aIdentities = array(), $bAllowIdentities = false)
public function SetIdentities($oAccount, $aIdentities = array())
{
$bAllowIdentities = $this->GetCapa(false, \RainLoop\Enumerations\Capa::IDENTITIES, $oAccount);
$aResult = array();
foreach ($aIdentities as $oItem)
{
@ -2966,8 +2984,7 @@ class Actions
throw new \RainLoop\Exceptions\ClientException(\RainLoop\Notifications::InvalidInputArgument);
}
$aIdentities = $this->GetIdentities($oAccount,
$this->GetCapa(false, \RainLoop\Enumerations\Capa::IDENTITIES, $oAccount));
$aIdentities = $this->GetIdentities($oAccount);
$bAdded = false;
$aIdentitiesForSave = array();
@ -2992,8 +3009,7 @@ class Actions
$aIdentitiesForSave[] = $oIdentity;
}
return $this->DefaultResponse(__FUNCTION__, $this->SetIdentities($oAccount, $aIdentitiesForSave,
$this->GetCapa(false, \RainLoop\Enumerations\Capa::IDENTITIES, $oAccount)));
return $this->DefaultResponse(__FUNCTION__, $this->SetIdentities($oAccount, $aIdentitiesForSave));
}
/**
@ -3017,7 +3033,8 @@ class Actions
}
$aNew = array();
$aIdentities = $this->GetIdentities($oAccount, $this->GetCapa(false, \RainLoop\Enumerations\Capa::IDENTITIES, $oAccount));
$aIdentities = $this->GetIdentities($oAccount);
foreach ($aIdentities as $oItem)
{
if ($oItem && $sId !== $oItem->Id())
@ -3026,8 +3043,7 @@ class Actions
}
}
return $this->DefaultResponse(__FUNCTION__, $this->SetIdentities($oAccount, $aNew,
$this->GetCapa(false, \RainLoop\Enumerations\Capa::IDENTITIES, $oAccount)));
return $this->DefaultResponse(__FUNCTION__, $this->SetIdentities($oAccount, $aNew));
}
/**
@ -3191,8 +3207,7 @@ class Actions
return $this->DefaultResponse(__FUNCTION__, array(
'Accounts' => $mAccounts,
'Identities' => $this->GetIdentities($oAccount,
$this->GetCapa(false, \RainLoop\Enumerations\Capa::IDENTITIES, $oAccount))
'Identities' => $this->GetIdentities($oAccount)
));
}
@ -4791,11 +4806,15 @@ class Actions
*/
public function DoSettingsUpdate()
{
$oAccount = $this->getAccountFromToken();
if (!$this->GetCapa(false, \RainLoop\Enumerations\Capa::SETTINGS, $oAccount))
{
return $this->FalseResponse(__FUNCTION__);
}
$self = $this;
$oConfig = $this->Config();
$oAccount = $this->getAccountFromToken();
$oSettings = $this->SettingsProvider()->Load($oAccount);
$oSettingsLocal = $this->SettingsProvider(true)->Load($oAccount);
@ -6038,11 +6057,26 @@ class Actions
list($sMailHeaders, $sMailBody) = \explode("\r\n\r\n", $sRawBody, 2);
unset($sRawBody);
// $this->Logger()->WriteDump(array(
// $sMailTo, $sMailSubject, $sMailBody, $sMailHeaders
// ));
if ($this->Config()->Get('labs', 'mail_func_clear_headers', true))
{
$sMailHeaders = \MailSo\Base\Utils::RemoveHeaderFromHeaders($sMailHeaders, array(
\MailSo\Mime\Enumerations\Header::TO_,
\MailSo\Mime\Enumerations\Header::SUBJECT
));
}
if (!\mail($sMailTo, $sMailSubject, $sMailBody, $sMailHeaders/*, '-f'.$oFrom->GetEmail()*/))
if ($this->Config()->Get('debug', 'enable', false))
{
$this->Logger()->WriteDump(array(
$sMailTo, $sMailSubject, $sMailBody, $sMailHeaders
));
}
$bR = $this->Config()->Get('labs', 'mail_func_additional_parameters', false) ?
\mail($sMailTo, $sMailSubject, $sMailBody, $sMailHeaders, '-f'.$oFrom->GetEmail()) :
\mail($sMailTo, $sMailSubject, $sMailBody, $sMailHeaders);
if (!$bR)
{
throw new \RainLoop\Exceptions\ClientException(\RainLoop\Notifications::CantSendMessage);
}
@ -7906,30 +7940,6 @@ class Actions
$aResult = array();
if ($oConfig->Get('capa', 'filters', false))
{
$aResult[] = \RainLoop\Enumerations\Capa::FILTERS;
if ($bAdmin || ($oAccount && $oAccount->Domain()->UseSieve()))
{
$aResult[] = \RainLoop\Enumerations\Capa::SIEVE;
}
}
if ($oConfig->Get('capa', 'x-templates', true))
{
$aResult[] = \RainLoop\Enumerations\Capa::TEMPLATES;
}
if ($oConfig->Get('webmail', 'allow_additional_accounts', false))
{
$aResult[] = \RainLoop\Enumerations\Capa::ADDITIONAL_ACCOUNTS;
}
if ($oConfig->Get('webmail', 'allow_additional_identities', false))
{
$aResult[] = \RainLoop\Enumerations\Capa::IDENTITIES;
}
if ($oConfig->Get('capa', 'folders', true))
{
$aResult[] = \RainLoop\Enumerations\Capa::FOLDERS;
@ -7953,6 +7963,57 @@ class Actions
if ($oConfig->Get('capa', 'settings', true))
{
$aResult[] = \RainLoop\Enumerations\Capa::SETTINGS;
if ($oConfig->Get('webmail', 'allow_additional_accounts', false))
{
$aResult[] = \RainLoop\Enumerations\Capa::ADDITIONAL_ACCOUNTS;
}
if ($oConfig->Get('webmail', 'allow_additional_identities', false))
{
$aResult[] = \RainLoop\Enumerations\Capa::IDENTITIES;
}
if ($oConfig->Get('capa', 'x-templates', true))
{
$aResult[] = \RainLoop\Enumerations\Capa::TEMPLATES;
}
if ($oConfig->Get('webmail', 'allow_themes', false))
{
$aResult[] = \RainLoop\Enumerations\Capa::THEMES;
}
if ($oConfig->Get('webmail', 'allow_user_background', false))
{
$aResult[] = \RainLoop\Enumerations\Capa::USER_BACKGROUND;
}
if ($oConfig->Get('security', 'openpgp', false))
{
$aResult[] = \RainLoop\Enumerations\Capa::OPEN_PGP;
}
if ($oConfig->Get('capa', 'filters', false))
{
$aResult[] = \RainLoop\Enumerations\Capa::FILTERS;
if ($bAdmin || ($oAccount && $oAccount->Domain()->UseSieve()))
{
$aResult[] = \RainLoop\Enumerations\Capa::SIEVE;
}
}
}
if ($oConfig->Get('security', 'allow_two_factor_auth', false) &&
($bAdmin || ($oAccount && !$oAccount->IsAdditionalAccount())))
{
$aResult[] = \RainLoop\Enumerations\Capa::TWO_FACTOR;
if ($oConfig->Get('security', 'force_two_factor_auth', false) &&
($bAdmin || ($oAccount && !$oAccount->IsAdditionalAccount())))
{
$aResult[] = \RainLoop\Enumerations\Capa::TWO_FACTOR_FORCE;
}
}
if ($oConfig->Get('capa', 'help', true))
@ -7990,18 +8051,6 @@ class Actions
}
}
if ($oConfig->Get('security', 'allow_two_factor_auth', false) &&
($bAdmin || ($oAccount && !$oAccount->IsAdditionalAccount())))
{
$aResult[] = \RainLoop\Enumerations\Capa::TWO_FACTOR;
if ($oConfig->Get('security', 'force_two_factor_auth', false) &&
($bAdmin || ($oAccount && !$oAccount->IsAdditionalAccount())))
{
$aResult[] = \RainLoop\Enumerations\Capa::TWO_FACTOR_FORCE;
}
}
if ($oConfig->Get('labs', 'allow_gravatar', false))
{
$aResult[] = \RainLoop\Enumerations\Capa::GRAVATAR;
@ -8017,21 +8066,6 @@ class Actions
$aResult[] = \RainLoop\Enumerations\Capa::PREFETCH;
}
if ($oConfig->Get('webmail', 'allow_themes', false))
{
$aResult[] = \RainLoop\Enumerations\Capa::THEMES;
}
if ($oConfig->Get('webmail', 'allow_user_background', false))
{
$aResult[] = \RainLoop\Enumerations\Capa::USER_BACKGROUND;
}
if ($oConfig->Get('security', 'openpgp', false))
{
$aResult[] = \RainLoop\Enumerations\Capa::OPEN_PGP;
}
if (!\RainLoop\Utils::IsOwnCloud())
{
$aResult[] = \RainLoop\Enumerations\Capa::AUTOLOGOUT;

View file

@ -89,10 +89,13 @@ class Application extends \RainLoop\Config\AbstractConfig
'login_desc' => array(''),
'login_css' => array(''),
'login_powered' => array(true),
'user_css' => array(''),
'user_logo' => array(''),
'user_logo_title' => array(''),
'user_logo_message' => array(''),
'user_css' => array(''),
'user_iframe_message' => array(''),
'welcome_page_url' => array(''),
'welcome_page_display' => array('none')
),
@ -318,6 +321,8 @@ Enables caching in the system'),
'smtp_show_server_errors' => array(false),
'sieve_allow_raw_script' => array(false),
'sieve_utf8_folder_name' => array(true),
'mail_func_clear_headers ' => array(true),
'mail_func_additional_parameters ' => array(false),
'folders_spec_limit' => array(50),
'owncloud_save_folder' => array('Attachments'),
'curl_proxy' => array(''),

View file

@ -193,18 +193,23 @@ class Service
$sResult .= '<!--';
$sResult .= ' [version:'.APP_VERSION;
$sResult .= '][lic:'.($this->oActions->IsOpen() ? 'agpl' : 'cc');
if ($this->oActions->IsOpen())
{
$sResult .= '][AGPLv3';
}
$sResult .= '][time:'.\substr(\microtime(true) - APP_START, 0, 6);
$sResult .= '][cached:'.($bCached ? 'true' : 'false');
$sResult .= '][hash:'.$aTemplateParameters['{{BaseHash}}'];
$sResult .= '][session:'.\md5(\RainLoop\Utils::GetShortToken());
// $sResult .= '][hash:'.$aTemplateParameters['{{BaseHash}}'];
// $sResult .= '][session:'.\md5(\RainLoop\Utils::GetShortToken());
if (\RainLoop\Utils::IsOwnCloud())
{
$sResult .= '][owncloud:true';
}
$sResult .= '] -->';
$sResult .= '] //-->';
}
// Output result

View file

@ -20,7 +20,7 @@
<label class="control-label" style="padding-top: 14px" data-i18n="TAB_LICENSING/LABEL_VERSION"></label>
<div class="controls">
<div class="alert alert-block span6" style="margin-left: 0">
<h4 data-i18n="TAB_LICENSING/TYPE_BASIC"></h4>
<h4>Basic</h4>
<br />
<p data-i18n="TAB_LICENSING/TYPE_BASIC_HINT_2"></p>
</div>

View file

@ -43,21 +43,32 @@
</nobr>
</div>
<div class="b-content b-message-view-wrapper thm-message-view-background-color">
<div>
<div style="height: 100%">
<div class="b-message-view-checked-helper" data-bind="visible: !message() && '' === messageError() && hasCheckedMessages()">
<span data-bind="text: printableCheckedMessageCount()"></span>
<i class="icon-mail"></i>
</div>
<div class="b-message-view-desc" data-bind="visible: !message() && '' === messageError() && !hasCheckedMessages()">
<div class="b-message-view-desc error" data-bind="visible: !message() && '' !== messageError() && !hasCheckedMessages()">
<span class="text" data-bind="text: messageError()"></span>
</div>
<div data-bind="visible: !message() && '' === messageError() && !hasCheckedMessages()" style="height: 100%">
<div class="b-message-view-desc" data-bind="visible: !logoIframe">
<span class="i18n" data-bind="visible: !logoImg" data-i18n="MESSAGE/MESSAGE_VIEW_DESC"></span>
<div class="logoPlace" data-bind="if: logoImg">
<div class="logoPlace" data-bind="visible: logoImg, if: logoImg">
<img style="height: 99%" data-bind="attr: { 'src': logoImg }" />
</div>
</div>
<div class="b-message-view-desc error" data-bind="visible: !message() && '' !== messageError()">
<span class="text" data-bind="text: messageError()"></span>
<div class="b-message-view-iframe" data-bind="visible: logoIframe, if: logoIframe" style="position: relative; height: 100%">
<iframe src="javascript:1;" tabindex="-1" frameborder="0"
style="border: none; width: 100%; height: 100%; position: absolute; top: 0px; left: 0px; right: 0px; bottom: 0px;"
data-bind="attr: {'src': logoIframe}"></iframe>
<div class="b-message-view-iframe-backdrop"></div>
</div>
</div>
<div class="message-fixed-button-toolbar clearfix" data-bind="visible: message">
@ -211,6 +222,7 @@
<div>
<img class="fromPic" data-bind="visible: viewUserPicVisible, attr: {'src': viewUserPic() }">
<div style="overflow: hidden;">
<button class="close" data-bind="command: closeMessage" style="margin-top: -2px;">&times;</button>
<div class="subjectParent" data-bind="event: { 'dblclick': toggleFullScreen }">
<span class="flagParent">
<i class="icon-star-empty flagOff" data-bind="css: {'icon-star flagOn': viewIsFlagged, 'icon-star-empty flagOff': !viewIsFlagged()}"></i>