Group: Forum Members
Posts: 28,
Visits: 93
|
I'm having a problem and questions regarding the transaction control of SF. In the case below, if the present boOrdemdeServico (Business of Service Orders) mistake, he should not have to deal, or not save the boMateriaisOS (in english Products of Service) and boServicosOS (Services from Service Order) of the Service Orders?
In this case, the BoOrdensDeServico return "SaveUndoResult.AbortedWithBrokenRules" in Save method.
Below, my code:
try { BusinessLayer.TransactionBegin("", IsolationLevel.Unspecified); AjustaMateriaisServicos(); boOrdensDeServico.Save(true); boMateriaisOS.Save(true); boServicosOS.Save(true); BusinessLayer.TransactionCommit(""); } catch(Exception ex) { BusinessLayer.TransactionRollback(""); Log.LogInfo(ex); }
What am I missing?
|