diff --git a/src/lib/db_models.rb b/src/lib/db_models.rb index ff55f29..0094211 100644 --- a/src/lib/db_models.rb +++ b/src/lib/db_models.rb @@ -346,6 +346,10 @@ class Auction < EntityModel data = Auction_Category_relation.get "category_id", "auction_id = ?", @id data && data.map! { |category| Category.find_by_id category["category_id"]} end + + def bids + return [] + end end diff --git a/src/views/auction/view.slim b/src/views/auction/view.slim index c10cf4f..d0b404c 100644 --- a/src/views/auction/view.slim +++ b/src/views/auction/view.slim @@ -18,10 +18,19 @@ #auctioninfo.card h2 = auction.title + ul.list-container#category-list + - auction.categories.each do |category| + p = category.name + + - if auction.bids.length >= 1 + .bid-container + - auctions.bids.each do |bid| + .bid + | BID + - else + p = "No bids! Be the first to bid on this item!" + - ul.list-container#category-list - - auction.categories.each do |category| - p = category.name script src="/js/slides.js" type="text/javascript" diff --git a/src/views/stylesheets/style.sass b/src/views/stylesheets/style.sass index f6c1566..b0625f5 100644 --- a/src/views/stylesheets/style.sass +++ b/src/views/stylesheets/style.sass @@ -461,6 +461,10 @@ ul.list-container h2 font-size: 1.8rem + #category-list + flex-direction: row + height: unset + .slideshow-container grid-area: im width: 40rem