// Default sort by field, possible values see above } if (!$bSearchInFound) { $_REQUEST["searchin"] = "--all--"; } // Free memory unset($oUser); unset($oClient); ################################## # Get data ################################## $oRecipients = new RecipientCollection(); // Updating keys, if activated; all recipients of all clients! $sMsg = ""; if (getSystemProperty("newsletter", "updatekeys")) { $iUpdatedRecipients = $oRecipients->updateKeys(); $sMsg = $notification->returnNotification("info", sprintf(i18n("%d recipients, with no or incompatible key has been updated. Deactivate update function.", $plugin_name), $iUpdatedRecipients)); } $oRecipients->setWhere("recipientcollection.idclient", $client); $oRecipients->setWhere("recipientcollection.idlang", $lang); // sort by and sort order $oRecipients->setOrder("recipientcollection." . $_REQUEST["sortby"] . " " . $_REQUEST["sortorder"]); // Show group if ($_REQUEST["restrictgroup"] != "--all--") { $oRecipients->link("RecipientGroupMemberCollection"); $oRecipients->setWhere("RecipientGroupMemberCollection.idnewsgroup", $_REQUEST["restrictgroup"]); } // Search for if ($_REQUEST["filter"] != "") { if ($_REQUEST["searchin"] == "--all--" || $_REQUEST["searchin"] == "") { foreach ($aFields as $sKey => $aData) {