mirror of
https://github.com/ebean-orm/ebean.git
synced 2026-11-17 22:56:28 +00:00
FIX: Do not add AssocOne-generatedProperties if they should not. (#1106)
This commit is contained in:
1 parent
f805bec8f2
commit
7336ce81bd
1 file changed
+7
-2
@@ -41,10 +41,15 @@ public class FactoryAssocOnes {
|
||||
// typically generated 'who' created/modified properties
|
||||
switch (mode) {
|
||||
case INSERT:
|
||||
list.add(new BindableAssocOneGeneratedInsert(one));
|
||||
if (one.getGeneratedProperty().includeInInsert()) {
|
||||
list.add(new BindableAssocOneGeneratedInsert(one));
|
||||
}
|
||||
break;
|
||||
case UPDATE:
|
||||
list.add(new BindableAssocOneGeneratedUpdate(one));
|
||||
if (one.getGeneratedProperty().includeInUpdate()) {
|
||||
// A 'Who Created property' is never updated
|
||||
list.add(new BindableAssocOneGeneratedUpdate(one));
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user