When a user is thanking, check state to see if other user thanked first, if so switch new_state to THANKED_BY_BOTH. fixes #13

This commit is contained in:
badblocks 2025-04-08 14:12:54 -07:00
parent 52663c83ef
commit a83ce746b5
7 changed files with 35 additions and 42 deletions

View file

@ -26,9 +26,9 @@ class CardDetailView(DetailView):
class TradeOfferHaveCardListView(ListView):
model = TradeOffer
template_name = "cards/_trade_offer_list.html"
context_object_name = "trade_offers"
paginate_by = 6
template_name = "trades/_trade_offer_list.html"
context_object_name = "offers"
paginate_by = 2
def get_queryset(self):
card_id = self.kwargs.get("pk")
@ -46,9 +46,9 @@ class TradeOfferHaveCardListView(ListView):
class TradeOfferWantCardListView(ListView):
model = TradeOffer
template_name = "cards/_trade_offer_list.html"
context_object_name = "trade_offers"
paginate_by = 6
template_name = "trades/_trade_offer_list.html"
context_object_name = "offers"
paginate_by = 2
def get_queryset(self):
card_id = self.kwargs.get("pk")