Skip to content

Commit c23626a

Browse files
tested all router
1 parent d088860 commit c23626a

File tree

2 files changed

+0
-21
lines changed

2 files changed

+0
-21
lines changed

carrot/app/auction/models.py

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -34,18 +34,6 @@ class Auction(Base):
3434
product: Mapped["Product"] = relationship("Product", back_populates="auction", uselist=False)
3535
bids: Mapped[list["Bid"]] = relationship("Bid", back_populates="auction", cascade="all, delete-orphan")
3636

37-
top_bid: Mapped[Optional["Bid"]] = relationship(
38-
"Bid",
39-
primaryjoin="and_(Auction.id==Bid.auction_id)",
40-
order_by="desc(Bid.bid_price)",
41-
uselist=False,
42-
viewonly=True,
43-
)
44-
45-
@property
46-
def owner_id(self):
47-
return self.product.owner_id
48-
4937
class Bid(Base):
5038
__tablename__ = "bid"
5139

carrot/app/auction/schemas.py

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -44,15 +44,6 @@ class AuctionProductSummary(BaseModel):
4444

4545
class Config:
4646
from_attributes = True
47-
48-
class BidSummaryResponse(BaseModel):
49-
id: str
50-
bidder_id: str
51-
bid_price: int
52-
bid_at: datetime
53-
54-
class Config:
55-
from_attributes = True
5647

5748
class AuctionListResponse(BaseModel):
5849
id: str

0 commit comments

Comments
 (0)