From 6e4c6f17c81fa5f6dc15d57cf4f21146d4507acb Mon Sep 17 00:00:00 2001 From: Claude Date: Sun, 8 Nov 2026 22:23:25 +0100 Subject: [PATCH] Verkaufen on an own listing chosen in the market list asks whether the player leaves the list Co-Authored-By: Claude Sonnet 5.5 --- docs/release/1.0.12/RELEASE_NOTES.md | 9 +++++++++ src/ui/transfer_market.cpp | 4 +++- src/ui/transfer_market_tests.cpp | 10 ++++++++++ 3 files changed, 22 insertions(+), 1 deletion(-) diff --git a/docs/release/1.0.12/RELEASE_NOTES.md b/docs/release/1.0.12/RELEASE_NOTES.md index 35c4772..e62702f 100644 --- a/docs/release/1.0.12/RELEASE_NOTES.md +++ b/docs/release/1.0.12/RELEASE_NOTES.md @@ -35,6 +35,15 @@ already did). Now pressed while held: no button and are unchanged. Toggles that stay on (training, filters) keep their lasting state. +## Transfer market + +- **Verkaufen on a listed player chosen in the market list.** Choosing an own listed + player in the right-hand list and pressing VERKAUFEN gave "Noch keine Angebote" + (or went straight to the offers) instead of the question of the original, + "Wollen Sie ... vom Transfermarkt holen?". It now asks first, as it already did for + a player chosen in the squad list: yes takes him off the list, no leads on to the + offers. + ## Internal - The drawing of the wide push button, of the calculator window (panel and keys) and diff --git a/src/ui/transfer_market.cpp b/src/ui/transfer_market.cpp index 49738b0..e29cbca 100644 --- a/src/ui/transfer_market.cpp +++ b/src/ui/transfer_market.cpp @@ -706,7 +706,9 @@ TransferMarketRequest TransferMarketScreen::make_review(const TransferMarketItem TransferMarketRequest TransferMarketScreen::make_open_offer(bool loan) { if(pending_||!selected_item_)return {}; const auto& item=state_.items.at(size_t(*selected_item_)); - if(item.own_listing)return make_review(item); + // An own listing chosen in the market list: VERKAUFEN first asks whether the player leaves the list (as for a player + // chosen in the squad); "no" leads on to the offers. + if(item.own_listing)return make_review(item,true); TransferMarketRequest request;request.kind=TransferMarketRequestKind::open_offer;request.offer_is_loan=loan; request.manager_slot=state_.manager_slot;request.runtime_club=state_.runtime_club;request.revision=state_.revision; if(item.own_bid)request.bid=*item.own_bid; diff --git a/src/ui/transfer_market_tests.cpp b/src/ui/transfer_market_tests.cpp index ee5f740..5eced04 100644 --- a/src/ui/transfer_market_tests.cpp +++ b/src/ui/transfer_market_tests.cpp @@ -98,6 +98,16 @@ int main(int argc,char** argv){ check(withdraw.kind==TransferMarketRequestKind::review_offers&&withdraw.ask_withdraw&&withdraw.bid.list_entry==4&& transfer_market_request_json(withdraw).find("\"ask_withdraw\":true")!=std::string::npos, "selling a listed own player without offers still asks whether he leaves the list"); + { // the same question when the listed player is chosen in the market list (right panel), with and without offers + for(const uint8_t offers:{uint8_t(0),uint8_t(1)}) { + auto own_state=listed;own_state.items[0].offers=offers; + TransferMarketScreen own(argv[1],own_state); + auto chosen=own.click(210,28);own.acknowledge_preview(own_state,quote(chosen)); + const auto sell_listed=own.click(200,206); + check(sell_listed.kind==TransferMarketRequestKind::review_offers&&sell_listed.ask_withdraw&&sell_listed.bid.list_entry==4, + "selling an own listing chosen in the market list asks whether the player leaves the list"); + } + } auto expired=fixture();expired.squad_slots[2932]=0x0fff; check(!transfer_market_from_game(expired,5).squad[0].already_listed, "cleared rejected/expired pool entry immediately makes the player listable again");