Fix unsaved compose contacts

Move thm-body from body to div
This commit is contained in:
RainLoop Team 2013-12-27 18:05:04 +04:00
parent 92855bc880
commit 25f9a1e95b
6 changed files with 57 additions and 13 deletions

View file

@ -70,6 +70,15 @@
min-width: 120px;
}
#rl-bg {
z-index: -1;
position: absolute;
left: 0;
right: 0;
top: 0;
bottom: 0;
}
html.mobile {
#rl-top-resizer-left {
width: @rlLeftWidth - 60;

View file

@ -4220,8 +4220,8 @@ class Actions
{
$oSettings = $this->SettingsProvider()->Load($oAccount);
$this->PersonalAddressBookProvider($oAccount)->IncFrec($oAccount->ParentEmailHelper(), \array_values($aArrayToFrec),
!!$oSettings->GetConf('ContactsAutosave', false));
$this->PersonalAddressBookProvider($oAccount)->IncFrec(
$oAccount->ParentEmailHelper(), \array_values($aArrayToFrec), !!$oSettings->GetConf('ContactsAutosave', true));
}
}

View file

@ -948,10 +948,10 @@ class PdoPersonalAddressBook
{
if ($oItem)
{
$sEmail = \strtolower(\trim($oItem->GetEmail()));
if (0 < \strlen($sEmail))
$sEmailUpdate = \strtolower(\trim($oItem->GetEmail()));
if (0 < \strlen($sEmailUpdate))
{
$aEmailsToUpdate[] = $sEmail;
$aEmailsToUpdate[] = $sEmailUpdate;
}
}
}
@ -977,15 +977,41 @@ class PdoPersonalAddressBook
}
if ('' !== \trim($oEmail->GetDisplayName()))
{
$sFirst = $sLast = '';
$sFullName = $oEmail->GetDisplayName();
if (false !== \strpos($sFullName, ' '))
{
$aNames = explode(' ', $sFullName, 2);
$sFirst = isset($aNames[0]) ? $aNames[0] : '';
$sLast = isset($aNames[1]) ? $aNames[1] : '';
}
else
{
$sFirst = $sFullName;
}
if (0 < \strlen($sFirst))
{
$oPropName = new \RainLoop\Providers\PersonalAddressBook\Classes\Property();
$oPropName->ScopeType = $oContact->ScopeType;
$oPropName->Type = \RainLoop\Providers\PersonalAddressBook\Enumerations\PropertyType::FULLNAME;
$oPropName->Value = \trim($oEmail->GetDisplayName());
$oPropName->Type = \RainLoop\Providers\PersonalAddressBook\Enumerations\PropertyType::FIRST_NAME;
$oPropName->Value = \trim($sFirst);
$oContact->Properties[] = $oPropName;
}
if (0 < \strlen($sLast))
{
$oPropName = new \RainLoop\Providers\PersonalAddressBook\Classes\Property();
$oPropName->ScopeType = $oContact->ScopeType;
$oPropName->Type = \RainLoop\Providers\PersonalAddressBook\Enumerations\PropertyType::LAST_NAME;
$oPropName->Value = \trim($sLast);
$oContact->Properties[] = $oPropName;
}
}
if (0 < \count($oContact->Properties))
{
$this->ContactSave($sEmail, $oContact);

View file

@ -38,7 +38,8 @@
}
</script>
</head>
<body class="thm-body">
<body>
<div id="rl-bg" class="thm-body"></div>
<div id="rl-loading" class="thm-loading">
{{BaseAppLoadingDescription}}
<div class="e-spinner">
@ -50,7 +51,7 @@
<div id="rl-loading-error" class="thm-loading">
An Error occurred,<br />please refresh the page and try again.
</div>
<div id="rl-content" class="startup-animation">
<div id="rl-content">
<div id="rl-popups"></div>
<div id="rl-center">
<div id="rl-top"></div>

View file

@ -6016,6 +6016,14 @@ html.mobile * {
right: auto;
min-width: 120px;
}
#rl-bg {
z-index: -1;
position: absolute;
left: 0;
right: 0;
top: 0;
bottom: 0;
}
html.mobile #rl-top-resizer-left {
width: 170px;
}

File diff suppressed because one or more lines are too long