diff --git a/application/Espo/Core/Utils/Api/Auth.php b/application/Espo/Core/Utils/Api/Auth.php index bb4e66c4e5..b49011b454 100644 --- a/application/Espo/Core/Utils/Api/Auth.php +++ b/application/Espo/Core/Utils/Api/Auth.php @@ -55,7 +55,10 @@ class Auth extends \Slim\Middleware } $espoCgiAuth = $req->headers('HTTP_ESPO_CGI_AUTH'); - if ( !isset($authUsername) && !isset($authPassword) && !empty($espoCgiAuth) ) { + if (empty($espoCgiAuth)) { + $espoCgiAuth = $req->headers('REDIRECT_HTTP_ESPO_CGI_AUTH'); + } + if (!isset($authUsername) && !isset($authPassword) && !empty($espoCgiAuth)) { list($authUsername, $authPassword) = explode(':' , base64_decode(substr($espoCgiAuth, 6))); } diff --git a/application/Espo/Modules/Crm/EntryPoints/Unsubscribe.php b/application/Espo/Modules/Crm/EntryPoints/Unsubscribe.php index 1e5af5ac85..c7ff9d5504 100644 --- a/application/Espo/Modules/Crm/EntryPoints/Unsubscribe.php +++ b/application/Espo/Modules/Crm/EntryPoints/Unsubscribe.php @@ -86,11 +86,8 @@ class Unsubscribe extends \Espo\Core\EntryPoints\Base $link = $m[$target->getEntityType()]; } if ($link) { - if ($campaign) { - $targetListList = $campaign->get('targetLists'); - } else { - $targetListList = $massEmail->get('targetLists'); - } + $targetListList = $massEmail->get('targetLists'); + foreach ($targetListList as $targetList) { $this->getEntityManager()->getRepository('TargetList')->updateRelation($targetList, $link, $target->id, array( 'optedOut' => true diff --git a/application/Espo/Modules/Crm/Resources/metadata/entityDefs/Contact.json b/application/Espo/Modules/Crm/Resources/metadata/entityDefs/Contact.json index 6487bd6ba2..274a2cdb38 100644 --- a/application/Espo/Modules/Crm/Resources/metadata/entityDefs/Contact.json +++ b/application/Espo/Modules/Crm/Resources/metadata/entityDefs/Contact.json @@ -238,7 +238,8 @@ }, "collection": { "sortBy": "name", - "asc": true + "asc": true, + "textFilterFields": ["name", "emailAddress"] }, "indexes": { "firstName": { diff --git a/application/Espo/Modules/Crm/Resources/metadata/entityDefs/Lead.json b/application/Espo/Modules/Crm/Resources/metadata/entityDefs/Lead.json index d67fa05b3a..b735d875e4 100644 --- a/application/Espo/Modules/Crm/Resources/metadata/entityDefs/Lead.json +++ b/application/Espo/Modules/Crm/Resources/metadata/entityDefs/Lead.json @@ -255,7 +255,7 @@ "collection": { "sortBy": "createdAt", "asc": false, - "textFilterFields": ["name", "accountName"] + "textFilterFields": ["name", "accountName", "emailAddress"] }, "indexes": { "firstName": { diff --git a/package.json b/package.json index b45f9b9959..e8da8b662b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "espocrm", - "version": "3.7.3", + "version": "3.7.4", "description": "", "main": "index.php", "repository": {