| Version 1 (modified by , 13 hours ago) ( diff ) |
|---|
Product Update
Actors: Registered Employee/Boss
1. A member of the personal opens a product from their store.
2. The system checks if the member has permission to change products.
3. After permission is confiremed, the registered user clicks "Edit product".
4. The employee/boss makes changes.
5. Application updates the data in product.
UPDATE product SET price = 44.99, availability = 15, description = 'Updated handmade wooden box' WHERE code = '00100001';
6. If new pictures of the product, the data in image is updated accordingly.
INSERT INTO image(product_code, image) VALUES
('00100001', 'black-box-open.png');
DELETE FROM image WHERE product_code='00100001' AND image='black-box-side.png';
7. If the colors in which the product is available changes, color is updated accordingly.
INSERT INTO color(product_code, color) VALUES
('00100001','Blue and White');
DELETE FROM color WHERE product_code='00100001' AND color='Black';
8. The change is logged in change.
INSERT INTO change(date_and_time, product_code, changes) VALUES
('2025-12-30 15:40:35', '00100001', 'Changed color "Black" to "Blue and White"');
9. The employee who made the change is logged in makes_change.
INSER INTO makes_change(personal_ID, change_date_time, product_code) VALUES
('0010002', '2025-12-30 15:40:35', '00100001');
Note:
See TracWiki
for help on using the wiki.
