as I can make 2 tables with one, I explain, I have a table works and other projects, these two tables have in common a table called events, where I want to put as fk the id and type since they can be repeated the id (id 1 of works or projects for example). Previously I had it related only to the works table, but I had to add projects, so I added the field type to events to be able to differentiate. How would the relationship in the migration and the model be? Thanks