Closed egg-bread closed 4 years ago
commit actually just changing bool -> Bool and fixing getter/setters for it.
And using the routines service to delete a routine when deleting a product (that is the sole product in the routine). Before it was not deleting the product properly.
ALWAYS REMOVE THE CONNECTION FROM THE OTHER SIDE OF THE RELATIONSHIP AND SAVE THE OTHER SIDE (IF NEEDED) THEN DELETE THE THING TO BE DELETED OR DELETE THE OTHER SIDE OF THE RELATIONSHIP DIRECTLY
Routines has >= 2 products and a product in it being deleted: detach product from routine, save routine back to db, delete product from db Routines has 1 product and that product is being deleted: deleted routine directly (as it does not delete the product), delete product from db
@JckXia ready for review 😗
WIPpers