Refactoring Rates: From Foreign Keys to Enums in Reimpact Platform
In the Reimpact platform, we're constantly striving for a cleaner, more maintainable codebase. Recently, we tackled an area involving rates and their association with different modules within the system.
The Problem: Priority Products and Foreign Keys
Originally, rates were tied to "priority products" using a foreign key relationship. This approach, while seemingly straightforward,