Service for Issues. Provides function to update the deprecation status
Parameters
the associated repository used for CRUD functionality
used to find Labels by id
used to save TimelineItems
used to find Artefacts by id
used to find Trackables by id
used to find IssuePrioritys by id
used to find IssueTypes by id
used to find IssueStates by id
used to find AffectedByIssues by id
used to validate and update templated fields
used to serialize templated fields
used to find Users by id
used to find Assignments by id
used to find AssignmentTypes by id
used to find IssueRelations by id
used to find IssueRelationTypes by id
used to find IssueComments by id
used to find Bodys by id
used to find Comments by id
used to find IssueTemplates by id
used to delete Nodes
Constructors
Properties
Injected, used for the checkPermission function
Injected, used to get a user based on a GropiusAuthorizationContext
Functions
Adds an AffectedByIssue to an Issue, returns the created AddedAffectedEntityEvent, or null if the AffectedByIssue was already on the Issue. Checks the authorization status.
Adds an affectedEntity to an issue at atTime as byUser and adds a AddedAffectedEntityEvent to the timeline. Creates the event even if the affectedEntity was already affected by the issue. Only adds the affectedEntity to the affects on the issue if no newer timeline item exists which removes it again. Does not check the authorization status. Does neither save the created AddedToPinnedIssuesEvent nor the issue. It is necessary to save the issue or returned AddedAffectedEntityEvent afterwards.
Adds referencedArtefacts to the referencedArtefacts of issueComment Does not mark the issueComment as updated
Adds a Artefact to an Issue, returns the created AddedArtefactEvent, or null if the Artefact was already present on the Issue. Checks the authorization status, checks that the Artefact can be added to the Issue
Adds a artefact to an issue at atTime as byUser and adds a AddedArtefactEvent to the timeline. Creates the event even if the artefact was already on the issue. Only adds the artefact to the issue if no newer timeline item exists which removes it again. Does not check the authorization status. Check if the artefact can be added to this issue. Does neither save the created AddedArtefactEvent nor the issue. It is necessary to save the issue or returned AddedArtefactEvent afterwards.
Pins an Issue on a Trackable, returns the created AddedToPinnedIssuesEvent, or null if the Issue was already pinned on the Trackable. Checks the authorization status, checks that the Issue can be pinned on the Trackable
Pins an issue on trackable at atTime as byUser and adds a AddedToPinnedIssuesEvent to the timeline. Creates the event even if the issue was already pinned on the trackable. Only adds the issue to the pinnedIssues on trackable if no newer timeline item exists which removes it again. Does not check the authorization status. Checks if the issue can be pinned to this trackable. Does neither save the created AddedToPinnedIssuesEvent nor the issue. It is necessary to save the issue or returned AddedToPinnedIssuesEvent afterwards.
Adds an Issue to a Trackable, returns the created AddedToTrackableEvent, or null if the Issue was already on the Trackable. Checks the authorization status
Adds an issue to a trackable at atTime as byUser and adds a AddedToTrackableEvent to the timeline. Creates the event even if the issue was already on the trackable. Only adds the issue to the trackable if no newer timeline item exists which removes it again. Does not check the authorization status. Does neither save the created AddedToTrackableEvent nor the issue. It is necessary to save the issue or returned AddedToTrackableEvent afterwards.
Adds a Label to an Issue, returns the created AddedLabelEvent, or null if the Label was already present on the Issue. Checks the authorization status, checks that the Label can be added to the Issue
Adds a label to an issue at atTime as byUser and adds a AddedLabelEvent to the timeline. Creates the event even if the label was already on the issue. Only adds the label to the issue if no newer timeline item exists which removes it again. Does not check the authorization status. Checks if the label can be added to this issue. Does neither save the created AddedLabelEvent nor the issue. It is necessary to save the issue or returned AddedLabelEvent afterwards.
Changes the type of an Assignment, returns the created AssignmentTypeChangedEvent or null if the type was not changed. Checks the authorization status, and checks that the new AssignmentType can be used with the Issue the Assignment is on.
Changes the type of an assignment at atTime as byUser and adds a AssignmentTypeChangedEvent to the timeline. Creates the event even if the type was not changed. Only changes the type if no newer timeline item exists which changes it. Does not check the authorization status. Checks that the newType can be used with the Issue the assignment is on. Does neither save the created AssignmentTypeChangedEvent nor the assignment nor the Issue. It is necessary to save the assignment, the returned AssignmentTypeChangedEvent or the Issue the assignment is on afterwards.
Changes the priority of an Issue, returns the created PriorityChangedEvent or null if the priority was not changed. Checks the authorization status, and check that the new IssuePriority can be used on the Issue
Changes the priority of an issue at atTime as byUser and adds a PriorityChangedEvent to the timeline. Creates the event even if the priority was not changed. Only changes the priority if no newer timeline item exists which changes it. Does not check the authorization status. Checks that the newPriority can be used on the issue. Does neither save the created PriorityChangedEvent nor the issue. It is necessary to save the issue or returned PriorityChangedEvent afterwards.
Changes a property of issue, returns the created event or null if the property was not changed. Checks the authorization status (TrackablePermission.MANAGE_ISSUES on the issue)
Changes the type of an IssueRelation, returns the created OutgoingRelationTypeChangedEvent or null if the type was not changed. Checks the authorization status, and checks that the new IssueRelationType can be used with the Issue the IssueRelation starts at.
Changes the type of an issueRelation at atTime as byUser and adds a OutgoingRelationTypeChangedEvent to the timeline on the start Issue, and an IncomingRelationTypeChangedEvent to the timeline on the related Issue. Creates the event even if the type was not changed. Only changes the type if no newer timeline item exists which changes it, this is only checked on the start Issue. Does not check the authorization status. Checks that the newType can be used with the Issue the issueRelation is on. Does neither save the created OutgoingRelationTypeChangedEvent nor the issueRelation nor the Issue. It is necessary to save the issueRelation, the returned OutgoingRelationTypeChangedEvent or the Issue the issueRelation is on afterwards. Caution: it is also necessary to save the related Issue manually!
Changes the state of an Issue, returns the created StateChangedEvent or null if the state was not changed. Checks the authorization status, and checks that the new IssueState can be used on the Issue
Changes the state of an issue at atTime as byUser and adds a StateChangedEvent to the timeline. Creates the event even if the state was not changed. Only changes the state if no newer timeline item exists which changes it. Does not check the authorization status. Checks that the newState can be used with the issue. Does neither save the created StateChangedEvent nor the issue. It is necessary to save the issue or returned StateChangedEvent afterwards.
Changes the template of an Issue, return the created TemplateChangedEvent or null if the Issue was already pinned on the Trackable. Checks the authorization status, checks that all inputs are compatible with the new template.
Changes the template of an Issue, return the created TemplateChangedEvent. Also creates the TemplateChangedEvent if the template of the issue does not change. Uses templatedFields, type, state, priority, assignmentTypeMapping and issueRelationTypeMapping to enforce compatibility with the new template, however only updates fields which are incompatible with the new template. Does not check the authorization status. Checks that all inputs are compatible with the new template, and checks that the templatedFields are valid after the update.
Changes the value of a templated field on an Issue, returns the created TemplatedFieldChangedEvent or null if the value of the templated field was not changed. Checks the authorization status, and checks that the field exists and the value is compatible.
Changes the value of a templated field on an issue at atTime as byUser and adds a TemplatedFieldChangedEvent to the timeline. Creates the event even if the templated field was not changed. Only changes the value of the templated field if no newer timeline item exists which changes it. Does not check the authorization status. Checks that the templated field exists and that the value is compatible. Does neither save the created TemplatedFieldChangedEvent nor the issue. It is necessary to save the issue or returned TemplatedFieldChangedEvent afterwards.
Changes the title of an Issue, returns the created TitleChangedEvent or null if the title was not changed. Checks the authorization status
Changes the title of an issue at atTime as byUser and adds a TitleChangedEvent to the timeline. Creates the event even if the title was not changed. Only changes the title if no newer timeline item exists which changes it. Does not check the authorization status. Does neither save the created TitleChangedEvent nor the issue. It is necessary to save the issue or returned TitleChangedEvent afterwards.
Changes the type of an Issue, returns the created TypeChangedEvent or null if the type was not changed. Checks the authorization status, and checks that the new IssueType can be used with the Issue
Changes the type of an issue at atTime as byUser and adds a TypeChangedEvent to the timeline. Creates the event even if the type was not changed. Only changes the type if no newer timeline item exists which changes it. Does not check the authorization status. Checks that the newType can be used with the issue. Does neither save the created TypeChangedEvent nor the issue. It is necessary to save the issue or returned TypeChangedEvent afterwards.
Checks that the type of an Assignment on issue can be changed to newType
Checks that the user has TrackablePermission.CREATE_ISSUES on trackable
Checks if the user defined by authorizationContext is a global admin
Checks that the priority of an issue can be changed to newPriority
Checks that the type of an IssueRelation on issue can be changed to newType
Checks that the user has TrackablePermission.MANAGE_ISSUES on trackable
Checks that the user has TrackablePermission.MANAGE_ISSUES on issue
Checks if the permission is granted on node If checkPermission on the permission.context is false, no permission is evaluated Does not handle the case that the user is an admin
Creates a new Assignment, returns the created Assignment. Checks the authorization status, and checks that the chosen type is compatible with the template of the Issue.
Creates a new Assignment on an issue at atTime as byUser. Does not check the authorization status. If present, checks that the assignmentType is compatible with the template of the issue. Does neither save the created Assignment nor the issue. It is necessary to save the issue or returned Assignment afterwards.
Updates node after it was created without an Input Should be called after the node was constructed Sets AuditedNode.createdBy and AuditedNode.lastModifiedBy
Called after a TimelineItem was created Adds it to the issue, calls createdAuditedNode and updates Issue.lastUpdatedAt and Issue.participants. Also calls updateAuditedNode on the issue. Also sets TimelineItem.issue, to allow to save timelineItem instead of issue.
Called after a TimelineItem was created on a related Issue Adds it to the issue, calls createdAuditedNode and updates Issue.lastModifiedAt and Issue.lastUpdatedAt Also sets TimelineItem.issue, to allow to save timelineItem instead of issue. Due to confidentiality reasons, Issue.participants, Issue.lastModifiedBy are not updated.
Creates an Issue. Checks the authorization status, checks that the type, state and templatedFields are compatible with the template
Creates an Issue at atTime as byUser on trackables. Also creates the Body of the Issue. Does not check the authorization status. Checks that trackables is not empty, checks that the type, state and templatedFields are compatible with template. Does not save the created Issue, it is required to save the returned Issue afterwards.
Creates a new IssueComment, returns the created IssueComment. Checks the authorization status, and checks that the referenced Artefact can be used on the Issue. Also, checks that the Comment it answers, if present, is on the same Issue
Creates a new IssueComment on issue at atTime as byUser. Does not check the authorization status. Checks for each Artefact in referencedArtefacts that it is on a Trackable the issue is on. If present, checks that the Comment it answers is on the same issue. Does neither save the created IssueComment nor the issue. It is necessary to save the issue or returned IssueRelation afterwards.
Creates a new IssueRelation, returns the created IssueRelation. Checks the authorization status, and checks that the chosen type is compatible with the template of the Issue.
Creates a new IssueRelation from issue to relatedIssue at atTime as byUser and adds it to the timeline of issue. Also creates a RelatedByIssueEvent and adds it to the timeline of relatedIssue. Does not check the authorization status. If present, checks that the issueRelationType is compatible with the template of the issue. Does neither save the created IssueRelation nor the issue. It is necessary to save the issue or returned IssueRelation afterwards.
Deletes an Issue. Checks the authorization status
Deletes an IssueComment, returns the deleted IssueComment. Checks the authorization status.
Deletes an issueComment at atTime as byUser. Does not check the authorization status. Does not save the deleted IssueComment. It is necessary to save the deleted issueComment afterwards.
Evaluates if the permission is granted on node If checkPermission on the permission.context is false, no permission is evaluated Does not handle the case that the user is an admin
Checks if a TimelineItem with type T exists on issue created after time matching itemFilter
Gets a GropiusUser based on the userId from the authorizationContext
Removes an AffectedByIssue from an Issue, returns the created RemovedAffectedEntityEvent, or null if the AffectedByIssue was not affected by the Issue. Checks the authorization status
Removes an affectedEntity from an issue at atTime as byUser and adds a RemovedAffectedEntityEvent to the timeline. Creates the event even if the affectedEntity was not affected by the issue. Only removes the affectedEntity from the affects on the issue if no newer timeline item exists which adds it again. Does not check the authorization status. Does neither save the created RemovedAffectedEntityEvent nor the issue. It is necessary to save the issue or returned RemovedAffectedEntityEvent afterwards.
Removes a Artefact from an Issue, returns the created RemovedArtefactEvent, or null if the Artefact was not present on the Issue. Checks the authorization status
Removes a artefact from an issue at atTime as byUser and adds a RemovedArtefactEvent to the timeline. Creates the event even if the artefact was not on the issue. Only removes the artefact from the issue if no newer timeline item exists which adds it again. Does not check the authorization status. Does neither save the created RemovedArtefactEvent nor the issue. It is necessary to save the issue or returned RemovedArtefactEvent afterwards.
Removes an Assignment from its Issue, returns the created RemovedAssignmentEvent, or null if the Assignment was already removed from its Issue. Checks the authorization status
Removes an assignment from its Issue at atTime as byUser and adds a RemovedAssignmentEvent to the timeline. Creates the event even if the assignment was already removed from its Issue. Does not check the authorization status. Does neither save the created RemovedAssignmentEvent nor the Issue of the assignment. It is necessary to save the Issue of the assignment or returned RemovedAssignmentEvent afterwards.
Unpins an Issue on a Trackable, returns the created RemovedFromPinnedIssuesEvent, or null if the Issue was not pinned on the Trackable. Checks the authorization status
Unpins an issue on a trackable at atTime as byUser and adds a RemovedFromPinnedIssuesEvent to the timeline. Creates the event even if the issue was not pinned on the trackable. Only removes the issue from the pinnedIssues on trackable if no newer timeline item exists which adds it again. Does not check the authorization status. Does neither save the created RemovedFromPinnedIssuesEvent nor the issue. It is necessary to save the issue or returned RemovedFromPinnedIssuesEvent afterwards.
Removes an Issue from a Trackable, returns the created RemovedFromPinnedIssuesEvent, or null if the Issue was not pinned on the Trackable. Also removes Labels and Artefacts if necessary, and unpins it on the specified Trackable. Checks the authorization status, checks that the Issue remains on at least one Trackable.
Removes an issue from a trackable at atTime as byUser and adds a RemovedFromTrackableEvent to the timeline. Also removes Labels and Artefacts if necessary, and unpins it on the specified Trackable. Creates the event even if the issue was not on the trackable. Only removes the issue from the trackable if no newer timeline item exists which adds it again. Does not check the authorization status. Checks that the issue remains on at least one Trackable. Does neither save the created RemovedFromTrackableEvent nor the issue. It is necessary to save the issue or returned RemovedFromTrackableEvent afterwards.
Removes an IssueRelation from its Issue, returns the created RemovedOutgoingRelationEvent, or null if the IssueRelation was already removed from its Issue. Checks the authorization status
Removes an issueRelation from its Issue at atTime as byUser and adds a RemovedOutgoingRelationEvent to the timeline. Also creates a RemovedIncomingRelationEvent and adds it to the timeline of the related Issue. Creates the event even if the issueRelation was already removed from its Issue. Does not check the authorization status. Does neither save the created RemovedOutgoingRelationEvent nor the Issue of the issueRelation. It is necessary to save the Issue of the issueRelation or returned RemovedOutgoingRelationEvent afterwards. Caution: it is also necessary to save the related Issue manually!
Removes a Label from an Issue, returns the created RemovedLabelEvent, or null if the Label was not present on the Issue. Checks the authorization status
Removes a label from an issue at atTime as byUser and adds a RemovedLabelEvent to the timeline. Creates the event even if the label was not on the issue. Only removes the label from the issue if no newer timeline item exists which adds it again. Does not check the authorization status. Does neither save the created RemovedLabelEvent nor the issue. It is necessary to save the issue or returned RemovedLabelEvent afterwards.
Removes a templated field from an Issue at atTime as byUser. Should only be used during template update. Does not check the authorization status. Assumes that a templated field with name field exists. Does neither save the created RemovedTemplatedFieldEvent or the issue. Requires to save the returned RemovedTemplatedFieldEvent or the issue.
Updates types of Assignment on issue where the old type is incompatible with the new template of issue based on assignmentTypeMapping and removes types with no replacement. Adds the crated events to childItems on event
Updates node after it was updated without an UpdateNodeInput Sets AuditedNode.lastModifiedBy and AuditedNode.lastModifiedAt
Updates an IssueComment, returns the updated IssueComment. Checks the authorization status, and checks that the added referenced Artefact can be used on the Issue.
Updates an IssueComment, returns the updated IssueComment. Checks the authorization status, and checks that the added referenced Artefact can be used on the Issue.
Updates an issueComment at atTime as byUser. Does not check the authorization status. Checks for each Artefact in addedArtefacts that it can be used with the Issue the issueComment is on Does not save the updated IssueComment. It is necessary to save the updated issueComment afterwards.
Updates types of IssueRelation on issue where the old type is incompatible with the new template of issue based on issueRelationTypeMapping and removes types with no replacement. Adds the crated events to childItems on event
Updates templated fields on issue after a template update, uses templatedFields for new values for currently incompatible fields and removes fields which are no longer defined by the template. Adds the crated events to childItems on event