I mostly took over the schema Leon wrote, but the fact an order is in paid_orders already means that the status is paid, so that is redundant. The table now looks like this:
paid_orders:
[order_id, amount_paid, user_id]
Not sure if user_id is needed, but it doesn't hurt to store it I guess.
I mostly took over the schema Leon wrote, but the fact an order is in paid_orders already means that the status is paid, so that is redundant. The table now looks like this:
paid_orders: [order_id, amount_paid, user_id]
Not sure if user_id is needed, but it doesn't hurt to store it I guess.