Skip to content
Snippets Groups Projects
Commit e9dcac1e authored by Andre Loreth's avatar Andre Loreth
Browse files

Contact: Do not return preset value for address if possible standard address...

Contact: Do not return preset value for address if possible standard address is the private address default id
parent dd3b1ca4
No related branches found
No related tags found
No related merge requests found
......@@ -8,6 +8,9 @@ if (vars.get("$this.value") === null || vars.get("$this.value") === "" || vars.g
.onPersonValueChange(vars.get("$field.ORGANISATION_ID"));
// If a possible standard addrss was found it should get applied to the field.
if (possibleStandardAddressID !== null)
// The secondary condition is specifically for a new "private" person, because
// it has placeholder address with the id "0<35 whitespaces>" (whitspaces due
// to char36 and uuid format).
if (possibleStandardAddressID !== null && possibleStandardAddressID.trim() !== "0")
result.string(possibleStandardAddressID);
}
\ No newline at end of file
}
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