We're updating the issue view to help you get more done. 

Merging CollectionChangeWorkUnit with ModWorkUnit ended with incorrect values of modified flags

Description

We have @OneToMany biderectional association (with mapped by):
Ticket -> comments (@OneToMany)
Comment -> ticket (@ManyToOne)

Follow steps:

1. Insert comment -> this creates CollectionChangeWorkUnit on ticket
2. Update ticket -> this creates ModWorkUnit on ticket
3. AuditProcess calls merge -> second ModWorkUnit returns

Created ModWorkUnit should have comments_AUD = true, but the value is false.

I suppose the same issue happens with AddWorkUnit.

Environment

None

Status

Assignee

Lukasz Antoniak

Reporter

Michal Kurtak

Fix versions

Labels

None

backPortable

None

Suitable for new contributors

None

Requires Release Note

None

Pull Request

None

backportDecision

None

Components

Affects versions

4.1.9

Priority

Major