Skip to content

An eBay-like e-commerce auction site. This project was done as part of the Harvard x EdX Course: CS50 Web Programming with Python and JavaScript.

Notifications You must be signed in to change notification settings

alicialawjy/commerce

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Header

Auctions

An eBay-like e-commerce auction site that allows users to post auction listings, place bids on listings, comment on those listings, and add listings to a “watchlist.”

Project Setup

  1. Download the zip file to this repository.
  2. In your terminal, cd into the 'commerce' directory.
  3. Run python manage.py runserver and visit http://127.0.0.1:8000/

Tech Stack

  • Backend Framework: Django and Python
  • Database Modelling: SQLite
  • Front End Languages: HTML, CSS and Javascript

Functionality

!!! Note: Asides from #6, users needs to be logged in to experience all functionalities.

1. Make a New Listing

  • Via 'CREATE LISTING' on the main tab.
  • Users are required to input a title, description, starting bid price, image (optional) and category.
  • Once submitted, user is redirected to the new listing page created

2. Make a Bid

  • Via the 'BID' field within the individual listing page.
  • Only bids greater than the current highest bid/ starting bid are accepted.
  • Else, an error message will be presented.

3. Add to/ Remove from Watchlist

  • Add Item: click the 'ADD TO WATCHLIST?' button within the individual listing page.
  • Item can then be found under the 'WATCHLIST' page (accessed by clicking button in main tab)
  • Remove Item: in the 'WATCHLIST' page, click the 'x' button on the individual listing to remove the item.

4. Comment

  • Via the comment textarea within the individual listing page.
  • Comments are displayed in reverse-chronological order.

5. Close a Listing

  • Done via the 'CLOSE LISTING' button at the end of the individual listing page.
  • This is only visible to the owner of a listing (only the owner can close the listing).
  • When listing is closed,
    • the highest bidder is noted as the winner of the auction,
    • the listing is deactived (i.e. not visible on the ACTIVE LISTING page), and
    • users can no longer bid/add to watchlist/comment on the listing
  • If the curent user is on a closed listing page, and they are the highest bidder, the page will announce the user as the winner of the auction.

6. Search for Listing

  • Via the search bar in the main menu.
  • The search goes through the listing title database.
  • Users are directed to a search result page with potential listings that contain the search query as a substring in their title (eg. 'apple' will show 'Apple iPhone 12 Pro Max' as a search result).

Page Views

1. Active Listing

  • views.py: name = index
  • Shows all the active listings on the site (aka. listings available for bidding)

2. Individual Listing

  • views.py: name = listing
  • This can be accessed by clicking on a listing.
  • Shows all details of the listing, bids and comments

3. Category

  • views.py: name = category
  • Shows listings of a particular category (category is determined during the listing creation).

4. Watchlist

  • views.py: name = watchlist
  • Shows all listings that the user has chose to add to their watchlist.

5. Create listing

  • views.py: name = create
  • For users to create their page listings.

6. Search results page

  • views.py: name = search
  • Shows results from a user's search.

7. Login

  • views.py: name = login

8. Register

  • views.py: name = register

About

An eBay-like e-commerce auction site. This project was done as part of the Harvard x EdX Course: CS50 Web Programming with Python and JavaScript.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published