Skip to content
Snippets Groups Projects
Commit f1aae821 authored by Johannes Goderbauer's avatar Johannes Goderbauer
Browse files

fix: Org index included private organisation

parent ab0c105a
No related branches found
No related tags found
No related merge requests found
import("Organisation_lib");
import("KeywordRegistry_basic");
import("system.translate");
import("system.result");
......@@ -57,9 +58,9 @@ var querySelect = newSelect([
.and(["COMMUNICATION", "MEDIUM_ID", "standardPhone"], commMediumPhoneIds, SqlBuilder.IN())
.and(["COMMUNICATION", "ISSTANDARD", "standardPhone"], "1")
, "standardPhone")
.where("CONTACT.STATUS", $KeywordRegistry.contactStatus$inactive(), SqlBuilder.NOT_EQUAL());
.where("CONTACT.STATUS", $KeywordRegistry.contactStatus$inactive(), SqlBuilder.NOT_EQUAL())
.and("ORGANISATION.ORGANISATIONID", OrgUtils.getPrivateOrganisationId(), SqlBuilder.NOT_EQUAL());
if (vars.exists("$local.idvalue") && vars.get("$local.idvalue") && vars.get("$local.idvalue").length > 0)
querySelect.and("CONTACT.CONTACTID", "$local.idvalue");
result.string(querySelect.toString());
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment