Skip to content
Snippets Groups Projects
Commit da7ff9f7 authored by Sebastian Pongratz's avatar Sebastian Pongratz :ping_pong: Committed by Martin Groppe
Browse files

[Projekt: xRM-ContactManagement][TicketNr.: 2002042][Fehlerhafter...

parent 4cf0c7c9
No related branches found
No related tags found
No related merge requests found
...@@ -936,7 +936,7 @@ LeadImportUtils.scanLeadDups = function(pAllContactData) ...@@ -936,7 +936,7 @@ LeadImportUtils.scanLeadDups = function(pAllContactData)
updDupVals = [dupStatus]; updDupVals = [dupStatus];
toUpdate.push([dupUpdateLeadTable, ["DUPSTATUS"], null, updDupVals, newWhere([dupUpdateLeadTable, "LEADID"], leadID).build()]); toUpdate.push([dupUpdateLeadTable, ["DUPSTATUS"], null, updDupVals, newWhere([dupUpdateLeadTable, "LEADSID"], leadID).build()]);
} }
db.updates(toUpdate);//update Leads with the new status db.updates(toUpdate);//update Leads with the new status
} }
......
...@@ -541,7 +541,7 @@ AuditUpdateSyncEntries.prototype.execute = function() ...@@ -541,7 +541,7 @@ AuditUpdateSyncEntries.prototype.execute = function()
switch (this.sqlAction + "-" + this.table) switch (this.sqlAction + "-" + this.table)
{ {
case "U-CONTACT": case "U-CONTACT":
subSQL = this.idValue; subSQL = [this.idValue];
break; break;
case "U-PERSON": case "U-PERSON":
subSQL = newSelect("CONTACT.CONTACTID").from("CONTACT").where("CONTACT.PERSON_ID", this.idValue); subSQL = newSelect("CONTACT.CONTACTID").from("CONTACT").where("CONTACT.PERSON_ID", this.idValue);
...@@ -555,7 +555,7 @@ AuditUpdateSyncEntries.prototype.execute = function() ...@@ -555,7 +555,7 @@ AuditUpdateSyncEntries.prototype.execute = function()
check = subSQL.arrayColumn().length > 0; check = subSQL.arrayColumn().length > 0;
break; break;
case "D-ADDRESS": case "D-ADDRESS":
subSQL = this.oldValues[this.columns.indexOf("CONTACT_ID")]; subSQL = [this.oldValues[this.columns.indexOf("CONTACT_ID")]];
break; break;
case "I-COMMUNICATION": case "I-COMMUNICATION":
case "U-COMMUNICATION": case "U-COMMUNICATION":
...@@ -563,11 +563,14 @@ AuditUpdateSyncEntries.prototype.execute = function() ...@@ -563,11 +563,14 @@ AuditUpdateSyncEntries.prototype.execute = function()
check = subSQL.arrayColumn().length > 0; check = subSQL.arrayColumn().length > 0;
break; break;
case "D-COMMUNICATION": case "D-COMMUNICATION":
subSQL = this.oldValues[this.columns.indexOf("CONTACT_ID")]; subSQL = [this.oldValues[this.columns.indexOf("CONTACT_ID")]];
break;
default:
check = false;
break; break;
} }
if(check) if(check && !Utils.isNullOrEmpty(subSQL))
{ {
newWhere("AB_SYNCCONTACT.CONTACT_ID", subSQL, SqlBuilder.IN()) newWhere("AB_SYNCCONTACT.CONTACT_ID", subSQL, SqlBuilder.IN())
.updateData(true, "AB_SYNCCONTACT", ["DATE_EDIT", "UPDATECONTACT"] , null, [vars.getString("$sys.date"), '1'], datetime.ONE_MINUTE * 5); .updateData(true, "AB_SYNCCONTACT", ["DATE_EDIT", "UPDATECONTACT"] , null, [vars.getString("$sys.date"), '1'], datetime.ONE_MINUTE * 5);
......
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