My database diagram corresponds to:
Each table has his own Symfony Entity class. My app view shows:
I need to associate a Discount Entity to multiple entities: Sneaker Tshirt Trouser or even more entities.
Create N:N tables between discounts and the others. The problem is that I could need create new tables to apply discount and then I would have to create more N:N tables. So I discard this solution.
generic table with
to_entity_id fields that let me map discount to
to_entity entity destination (Sneaker