| Version 2 (modified by , 2 weeks ago) ( diff ) |
|---|
UseCase05 - Create a Listing
Initiating actor: Owner
Description
An owner creates a listing for an animal they own. After creation, the system shows the created listing.
Scenario
- Owner opens "My Animals" page.
SELECT a.animal_id, a.name, a.sex, a.date_of_birth, a.type, a.species, a.breed, a.located_name FROM animals a WHERE a.owner_id = $1 ORDER BY a.animal_id DESC;
- Owner clicks on a specific animal.
- Clicks on the "Create Listing" button.
- Owner enters listing information and submits it.
- System creates the lisitng.
INSERT INTO listings (owner_id, animal_id, status, price, description, created_at) VALUES ($1, $2, 'ACTIVE', $3, $4, NOW()) RETURNING listing_id;
Note:
See TracWiki
for help on using the wiki.
