Rails 3 - Removing a User but retaining content? -
i've seemed have gotten myself bit of pickle. i'm trying write way destroy users, still retain content.
currently in app, company has many users, , users belongs 1 company. company can make user inactive if need to, i'd company able remove users account in cases of termination, etc.
i going simply, on destroy, set foreign company_id key nil in user's table. however, doing this, company lose old user's work, can't happen, information populated doing queries on company_id.
has thought of nice little way of getting around similar db design? or have go square 1 figure out way more effectively.
thanks
this more of interface issue data model issue. sure, shouldn't delete/destroy users if need retain information. if need way of removing users apart making them inactive, add option 'terminated' status. depends on how , display these terminated users in front end (or maybe never display them).
Comments
Post a Comment