Edit State / Edit Mode

Posts   
 
    
Gazley
User
Posts: 18
Joined: 17-Apr-2006
# Posted on: 02-Nov-2006 21:21:51   

Hi

Do the entity classes generated by LLBL have an "edit state"?

Also, if a BO/Entity is edited, does LLBL preserve the original data in the event that the changes are cancelled. If so, will LLBL abort a new row (prior to it being persisted) if Cancel/Undo is called?

Thanks.

bclubb
User
Posts: 934
Joined: 12-Feb-2004
# Posted on: 03-Nov-2006 04:00:28   

If an entity is modified it is marked as dirty. The each entity contains filelds which have a current value and a dbvalue. The dbvalue is the value of the field when the entity was fetched.

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39927
Joined: 17-Aug-2003
# Posted on: 03-Nov-2006 09:41:32   

Furthermore, if you want versioning in the entity of the entityfields, please check SaveFields and RollbackFields methods of the entity. (Documented in the UnitOfWork and field versioning section in the manual).

Edit state preservation is also implemented for databinding scenario's so you can press ESC in a grid and the value rolls back.

Frans Bouma | Lead developer LLBLGen Pro
Gazley
User
Posts: 18
Joined: 17-Apr-2006
# Posted on: 03-Nov-2006 10:32:55   

Great to hear - it seems that in this regard, you have all bases covered simple_smile

Thanks again!