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
7135f9e6
Commit
7135f9e6
authored
4 years ago
by
Sebastian Listl
Browse files
Options
Downloads
Patches
Plain Diff
#1064496 new Contacts could not be removed in QuickEntry
parent
9c82ed5c
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/Person_entity/grantDeleteProcess.js
+3
-1
3 additions, 1 deletion
entity/Person_entity/grantDeleteProcess.js
with
3 additions
and
1 deletion
entity/Person_entity/grantDeleteProcess.js
+
3
−
1
View file @
7135f9e6
...
...
@@ -11,7 +11,7 @@ var personCount = newSelect("count(*)")
.
from
(
"
CONTACT
"
)
.
join
(
"
PERSON
"
,
"
PERSON.PERSONID = CONTACT.PERSON_ID
"
)
.
where
(
"
PERSON.PERSONID
"
,
personId
)
.
cell
()
.
cell
()
;
//only delete when the contact doesnt have any functions, because that would currently lead to the person and all his functions being deleted,
// since there is only one person contact behind all the contacts.
//ToDo: come back to this and implement the solution for deleting a function (#1059167) once it'S decided how that's being implemented
...
...
@@ -30,5 +30,7 @@ if(personCount == 1)
.
andNoEntityRows
(
"
ObjectTree_entity
"
,
"
TreeProvider
"
,
{
ObjectIds_param
:
JSON
.
stringify
([
contactId
,
vars
.
get
(
"
$field.PERSON_ID
"
)]),
ObjectTypes_param
:
JSON
.
stringify
([
currentContext
,
"
PrivatePerson
"
])})
.
validate
();
}
else
if
(
personCount
==
0
)
//special case in QuickEntry where it should be possible to remove a new Person that is not saved in the db yet
canDelete
=
true
;
result
.
string
(
canDelete
);
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