How to give control to delete/remove an entity member to end user?
Hi all,
I am currently building an retail planning application in which the we are giving the flexibility to the end user to load the master data (Store details) into the entities. In addition to this, we want to give the flexibility to remove a particular store detail in case the use want to do so. Let's suppose the user want to close a store at particular point of time then he should able remove the details of that store from the entity(i.e. that particular entity member).Helmut HeimannAdam ElvinFelix CsanadyAudrey Nobles
Answers
-
Hi Sanjay Bindhani,
I would be very careful with providing such a solution to the end-user since it might lead to inconsistencies in your database.
My suggestion would be to make the store entity time-dependent with the ability for the end-user to set a valid-to date. This way you wouldn't have to delete the data referring to the "out-of-date" store and you won't get orphaned entity members.
Hope this helps!
KR
Helmut7 -
Hi,
I would not suggest to give the enduser the right to clear data (see Helmut Heimann Post for reasons).
Cause if so you also loose all planing/reporint data on this stores.
The better way would be to create an Parent Entity above Store like "Active Store" (containing active/Closed).
If you select only Active Stores on all Screens you have the same. And the Enduser can change the relationship very easily using ato Pager or a DataView. So you can also Re-Open a store and see all the old data
regards
Björn
9 -
Hi,
exactly, listen to Björn! ;-)
For the exact same reasons stated above we often use a "Status"- entity with members like active, inactive, new, deleted etc. This can also be used in other contexts, for example if you only want to plan new articles in a sales planning application or if you want to exclude projects that you don't want to see in a capacity planning environment and so on. The relation to this "Status"-Entity can easily be changed by the user.
What you can think about in addition to that is running a clean-up job every few weeks or months depending on the size of the entity, where you define which elements to keep. This should in my opinion always be a centralized process, though and not triggered by the individual user.
Kind regards,
Gerrit
4