ItEr60S04ValidacionEProbasFuncionaisItEr59S04: After saving load the order from the DB.
This allows the avoiding of lots of dontPoseAsTransientAnymore.
This commit is contained in:
parent
c3fc7664c2
commit
ded85c356d
1 changed files with 14 additions and 0 deletions
|
|
@ -473,9 +473,23 @@ public class OrderModel implements IOrderModel {
|
|||
}
|
||||
});
|
||||
order.dontPoseAsTransientObjectAnymore();
|
||||
// this way we don't have dontPoseAsTransient all children of the
|
||||
// order
|
||||
initEditAfterSave();
|
||||
}
|
||||
}
|
||||
|
||||
private void initEditAfterSave() {
|
||||
transactionService
|
||||
.runOnReadOnlyTransaction(new IOnTransaction<Void>() {
|
||||
@Override
|
||||
public Void execute() {
|
||||
initEdit(order);
|
||||
return null;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
private void saveOnTransaction(boolean newOrderVersionNeeded) {
|
||||
reattachCriterions();
|
||||
reattachTasksForTasksSources();
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue