Open AdrianDAlessandro opened 1 week ago
From offline conversation:
@cc-a : I've not really looked at unmanaged models before but it looks to me like they're still meant for working with stuff in the database. So it won't try to manage the database table but will still try and save data if the save method is called on an instance. TBH I can't really see it as a replacement for an enum that is just being used to represent options in a function call. Maybe more so for the forms and tables but we'd probably want to override some of the class methods to stop people trying to save objects which kind of makes me think we'd be abusing the intended purpose.
@AdrianDAlessandro: Yea, I agree. We don't want to use a model because we don't have a DB to interact with. But I think the lack of models means we're losing a bit of the natural separation of concerns that they help keep. We're defining data structure logic in the views, tables and forms which should really live somewhere else. So yes, agreed that an unmanaged model isn't the way to do it, but we need some kind of single-source-of-truth for data structures.
_Originally posted by @AdrianDAlessandro in https://github.com/ImperialCollegeLondon/dune_processes/pull/59#discussion_r1753701809_
This also can apply to the tables and forms that we are currently using.