Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
basic
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
xrm
basic
Commits
f9e4e022
Commit
f9e4e022
authored
4 years ago
by
Sebastian Pongratz
Browse files
Options
Downloads
Patches
Plain Diff
#1065468_LeadimportReset_MariaDBBugfix Änderung am Delete
parent
3f3e57b7
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
entity/Leadimport_entity/entityfields/leadimportreset/onActionProcess.js
+15
-12
15 additions, 12 deletions
...rt_entity/entityfields/leadimportreset/onActionProcess.js
with
15 additions
and
12 deletions
entity/Leadimport_entity/entityfields/leadimportreset/onActionProcess.js
+
15
−
12
View file @
f9e4e022
...
...
@@ -22,14 +22,14 @@ _deleteData("COMMUNICATION", leadimportId, dateADayBefore);
_deleteData
(
"
AB_ATTRIBUTERELATION
"
,
leadimportId
,
dateADayBefore
);
newWhere
(
"
LEADLOG.LEADIMPORT_ID
"
,
leadimportId
)
.
and
(
"
LEADLOG.DATE_NEW
"
,
dateADayBefore
.
getTime
(),
"
# >= ?
"
)
.
from
(
"
LEADLOG
"
)
.
deleteData
();
.
and
(
"
LEADLOG.DATE_NEW
"
,
dateADayBefore
.
getTime
(),
"
# >= ?
"
)
.
from
(
"
LEADLOG
"
)
.
deleteData
();
newWhere
(
"
LEAD.LEADIMPORT_ID
"
,
leadimportId
)
.
and
(
"
LEAD.DATE_NEW
"
,
dateADayBefore
.
getTime
(),
"
# >= ?
"
)
.
from
(
"
LEAD
"
)
.
deleteData
();
.
and
(
"
LEAD.DATE_NEW
"
,
dateADayBefore
.
getTime
(),
"
# >= ?
"
)
.
from
(
"
LEAD
"
)
.
deleteData
();
// Ändern des Status auf Created
newWhere
(
"
LEADIMPORT.LEADIMPORTID
"
,
leadimportId
).
updateData
(
true
,
"
LEADIMPORT
"
,
[
"
Status
"
],
null
,
[
$KeywordRegistry
.
importStatus
$created
()]);
...
...
@@ -46,12 +46,15 @@ function _deleteData (pTableName, pleadimportId, pdateADayBefor)
{
let
uTableName
=
pTableName
.
charAt
(
0
);
newWhere
(
pTableName
+
"
.
"
+
pTableName
+
"
ID
"
,
newSelect
(
uTableName
+
"
.
"
+
pTableName
+
"
ID
"
)
.
from
(
pTableName
,
uTableName
)
.
join
(
"
LEADLOG
"
,
"
LEADLOG.DATE_NEW =
"
+
uTableName
+
"
.DATE_NEW
"
)
.
where
(
uTableName
+
"
.USER_NEW = LEADLOG.USER_NEW
"
)
.
and
(
"
LEADLOG.LEADIMPORT_ID
"
,
pleadimportId
)
.
and
(
"
LEADLOG.DATE_NEW
"
,
pdateADayBefor
.
getTime
(),
"
# >= ?
"
),
SqlBuilder
.
IN
())
newSelect
(
"
TAB.
"
+
pTableName
+
"
ID
"
)
.
from
(
newSelect
(
uTableName
+
"
.
"
+
pTableName
+
"
ID
"
)
.
from
(
pTableName
,
uTableName
)
.
join
(
"
LEADLOG
"
,
"
LEADLOG.DATE_NEW =
"
+
uTableName
+
"
.DATE_NEW
"
)
.
where
(
uTableName
+
"
.USER_NEW = LEADLOG.USER_NEW
"
)
.
and
(
"
LEADLOG.LEADIMPORT_ID
"
,
pleadimportId
)
.
and
(
"
LEADLOG.DATE_NEW
"
,
pdateADayBefor
.
getTime
(),
SqlBuilder
.
GREATER_OR_EQUAL
())
,
"
TAB
"
),
SqlBuilder
.
IN
())
.
from
(
pTableName
)
.
deleteData
();
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment