JiayangYing / CITS3403_PRO

MIT License
2 stars 0 forks source link

Implement Foreign Key Association between Product and User Tables and Update Database #41

Closed JiayangYing closed 6 months ago

JiayangYing commented 6 months ago

Description:

We need to enhance the relationship between our Product and User tables to ensure that each product is associated with a user. This will involve the following key tasks:

Add a Foreign Key in the Product Table:
    Modify the Product table schema by adding a foreign key that links to the User table. This will establish a direct relationship, ensuring that each product is related to a specific user.
Database Schema Update:
    Update the database schema to include the new foreign key. This will likely involve running a migration script to modify the existing structure without affecting the current data.
Enable User Product Association:
    Adjust the application logic to allow users to add products. This means updating the product creation functionalities to include user identification and ensuring that the product-user link is correctly established during the product addition process.

Expected Outcome:

A robust link between products and users, facilitating clear ownership and management of products within the system.
Updated database schema and application functionalities to support this new association.
JiayangYing commented 6 months ago

closed #44