On Thu, Jul 15, 2010 at 8:34 PM, Wai <[email protected]> wrote: > > Hello, > What is the best practice in using the thruDate of an item. > I know that when deleting or expiring an item, it is best to just fill in > the thruDate. The reason behind this is to have a record of > deleted/expired > items. > > What if an item needs to be reused again. Is it a matter of emptying out > the thruDate or setting it to a future expiry date? If this is the best > practice, how would ofbiz keep track of whether an item has ever been > expired? > > I would recommend creating some kind of detail record to track this kind of "on-off-on" change.
The framework has a built-in way of dealing with valid date range states, as you know, but to get the next level of accountability you probably want to extend the model in order to store the transaction history. I would look at ProductPriceChange or PartyNameHistory for examples of this idea. -- James McGill Phoenix AZ
