master
E. Almqvist 3 years ago
parent 94701d2a14
commit 3864538244
  1. 1
      src/lib/db_init.rb
  2. 10
      src/lib/db_models.rb

@ -5,6 +5,7 @@ LOAD_MODELS = [
Role, Role,
User_Role_relation, User_Role_relation,
Auction, Auction,
Bid,
Auction_Category_relation, Auction_Category_relation,
Category, Category,
Image Image

@ -352,6 +352,16 @@ class Auction < EntityModel
end end
end end
# Auction bids
class Bid < EntityModel
attr_reader :amount, :auction_id, :user_id, :message
def initialize(data)
super data
@amount = data["amount"].to_f
# stuff
end
end
class Category < EntityModel class Category < EntityModel
attr_reader :name, :color attr_reader :name, :color

Loading…
Cancel
Save