Skip to content
Snippets Groups Projects
Commit ef888154 authored by Tobias Feldmann's avatar Tobias Feldmann
Browse files

Bugfixes set email and phone standard for person and organisation

parent 64c551bc
No related branches found
No related tags found
No related merge requests found
import("system.vars");
import("Entity_lib");
// TODO: also there is currently no good way to do updates with fields not connected to the record container. Workaround: imagevariable and update in onDBUpdate Process #1030023
FieldChanges.setChange("$field.IMAGE");
\ No newline at end of file
FieldChanges.setChange("$field.IMAGE", vars.get("$local.value"));
\ No newline at end of file
......@@ -290,8 +290,8 @@
<onValueChangeTypes>
<element>MASK</element>
<element>PROCESS</element>
<element>RECORD</element>
<element>PROCESS_SETVALUE</element>
<element>RECORD</element>
</onValueChangeTypes>
</entityField>
<entityField>
......
import("system.vars");
import("Entity_lib");
// TODO: also there is currently no good way to do updates with fields not connected to the record container. Workaround: imagevariable and update in onDBUpdate Process #1030023
FieldChanges.setChange("local.value");
\ No newline at end of file
FieldChanges.setChange("$field.STANDARD_EMAIL_COMMUNICATION", vars.get("$local.value"));
\ No newline at end of file
import("system.vars");
import("Entity_lib");
// TODO: also there is currently no good way to do updates with fields not connected to the record container. Workaround: imagevariable and update in onDBUpdate Process #1030023
FieldChanges.setChange("local.value");
\ No newline at end of file
FieldChanges.setChange("$field.STANDARD_PHONE_COMMUNICATION", vars.get("$local.value"));
\ No newline at end of file
import("system.logging");
import("system.vars");
import("Organisation_lib");
import("Communication_lib");
import("Entity_lib");
// TODO: this is a workaround for missing possibility to react on changes of fields not connected to record Contqainer #1030023
var uid = vars.get("$sys.uid");
var rowdata = vars.get("$local.rowdata");
var uid = rowdata["CONTACT.CONTACTID"];
FieldChanges.assimilateChangeAndDispose("$field.STANDARD_EMAIL_COMMUNICATION", function(state, value){
CommUtil.setStandardMail(uid, value);
});
......
import("system.vars");
import("Entity_lib");
// TODO: also there is currently no good way to do updates with fields not connected to the record container. Workaround: imagevariable and update in onDBUpdate Process #1030023
FieldChanges.setChange("local.value");
\ No newline at end of file
FieldChanges.setChange("$field.STANDARD_EMAIL_COMMUNICATION", vars.get("$local.value"));
\ No newline at end of file
import("system.vars");
import("Entity_lib");
// TODO: also there is currently no good way to do updates with fields not connected to the record container. Workaround: imagevariable and update in onDBUpdate Process #1030023
FieldChanges.setChange("local.value");
\ No newline at end of file
FieldChanges.setChange("$field.STANDARD_PHONE_COMMUNICATION", vars.get("$local.value"));
\ No newline at end of file
......@@ -139,14 +139,13 @@ FieldChanges.assimilateChangeAndDispose = function (pFieldName, pAssimilatorFn)
/**
* Call this if the field changed.
*/
FieldChanges.setChange = function(pFieldName)
FieldChanges.setChange = function(pFieldName, pValue)
{
var allChanges = FieldChanges._getStorage();
if (allChanges[pFieldName] == undefined)
allChanges[pFieldName] = {};
var value = vars.get(pFieldName);
if (!value)
if (!pValue)
allChanges[pFieldName].state = FieldChanges.STATE_DELETED();
else
allChanges[pFieldName].state = FieldChanges.STATE_CHANGED();
......
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