One swap per banner + admin takedown (Marty 2026-11-15: "allow the member to swap it only, and they can only do it one time. Admin takes down the option to credit back or none.")

Member swap: My Banners shows "Swap image or link" on a banner that is waiting or in the loop, usable once (then "Swap used"). POST /api/my/banners/<id>/swap changes the image and/or link (or a Banner Spin to another of the member's own 125x125/250x250 spins via lsspins), same checks as a new post (checkLink, probeLink, upload/https image checks); id, place, clicks and loop progress stay. Logged on the banner (swaps: old/new image + link, time). No withdraw, removal or refund for members.

Admin takedown: /admin finds banners (#id, wallet, username), POST /api/admin/banners/<id>/takedown {reason required, credit: back|none}. The banner is hidden at once (splash loop + waiting line show a house tile in its place, /go goes home, no look/teaser/swap); its place rides out on time so nobody moves, then it ends with no cycle, no network views, no prize count. My Banners shows "Taken down" with the reason. Restore reverses a given credit (when the owner still holds one) and, if its place rode out meanwhile, records the cycle then. Admin ledger: GET /api/admin/actions (who, when, reason, credit decision).

Chatbot: CANNED 'swap' + FACTS line (KNOWLEDGE_DATE already 2026-11-15), chat-qa entry. my.js?v=4, admin.js?v=3, vbb.css?v=8.
Tests: smoke section 15 (swap once, refused twice, keeps place, bad link/image refused, spin swap, takedown credit back vs none, others keep places, ride-out without a cycle, restore, admin ledger, phone UI): 308/308 with the committed networksso.js; chatbot.test 182/182; qa:chain 49/49.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
martbost
2026-11-15 15:18:49 -06:00
parent 666cdd9569
commit 8e6d2f9cd0
11 changed files with 409 additions and 28 deletions
+5 -1
View File
@@ -5,7 +5,7 @@
// ad views per cycle recorded but not credited yet, 6 s visit, 3 browsers per connection a day, 1 free post credit a day for network
// members, 3 banners waiting per member, packs 10 for $3 and 40 for $10, banner look $2), ../contracts VBBShop (SPONSOR_BPS 3000,
// PRIZE_BPS 1000, company the rest, sponsor bound once by voucher, no owner withdraw, failed sends claimable), server.js (100 KB
// image, 125x125, Banner Spin posting 125x125 or 250x250), lsspins.js (SPIN tiles in empty places never shift, cycle or earn),
// image, 125x125, Banner Spin posting 125x125 or 250x250, one swap per banner and the admin takedown, 2026-11-15), lsspins.js (SPIN tiles in empty places never shift, cycle or earn),
// public/how.html, packages.html, leaders.html. The prize pot's floor and cap are internal and never shown (Marty's rule).
// HOUSE RULE: when a feature changes, update CANNED and FACTS in the same commit and bump KNOWLEDGE_DATE.
// Plain words, no em dashes, never a promise of income, "SafePal or any other crypto wallet", never RM Circle.
@@ -36,6 +36,9 @@ const CANNED = [
{ id: 'free-credit', title: 'Free post credits', q: ['How do I get a free post credit?', 'Is posting free?', 'Why did I not get my free credit?'], tags: ['free credit', 'post credit', 'daily', 'network member'],
re: /(free (post )?credits?|post credits?|is (it|posting) free|daily credit|credit (a|per|each) day)/i,
a: 'Network members (anyone with an InstantAdPay or LinkSpin account) get one free post credit each day they sign in, Central time. Each credit posts one banner into the loop. Want to post more? Credit packs are one-time purchases: ' + packs + '. You can have up to ' + C.maxQueuedPerMember + ' banners waiting at once.' },
{ id: 'swap', title: 'Changing a banner after posting (one swap)', q: ['Can I change my banner image or link?', 'I posted the wrong link. Can I fix it?', 'Can I remove my banner?', 'Why was my banner taken down?'], tags: ['swap', 'change banner', 'edit', 'wrong link', 'remove', 'taken down'],
re: /((swap|change|edit|replace|update|fix|correct)\b.{0,24}\b(banners?|image|picture|link|url)|wrong (link|image|banner|url|picture)|\btypo\b|(remove|delete|withdraw|take down|pull) (my |a |the )?banners?|banners?.{0,20}taken down)/i,
a: 'Each banner can be swapped one time. On My Banners (' + URL_ + '/my), a banner that is waiting or in the loop has a "Swap image or link" button: put in a new image, a new link, or both (a Banner Spin can swap to another of your own 125x125 or 250x250 spins). The banner keeps its place, its clicks and its progress through the loop, and the new image and link get the same checks as a new post. After that one swap the button is gone. Members cannot withdraw or remove a posted banner, and post credits are not refunded. A banner that breaks the rules can be taken down by the admin; its owner sees the reason on My Banners.' },
{ id: 'post', title: 'Posting a banner', q: ['How do I post a banner?', 'What size is the banner?', 'Can I use a Banner Spin?'], tags: ['post', 'banner', '125x125', 'image', 'link', 'banner spin'],
re: /(post (a |my )?banner|banner size|what size|125 ?x ?125|upload|image|banner spin|my banners)/i,
a: 'On My Banners (' + URL_ + '/my) upload a 125x125 image (100 KB or less) with your link, or post one of your LinkSpin Banner Spins (125x125 or 250x250). It uses one post credit, waits in line, and enters the loop at the front at the next shift. Your link must be a real page that loads.' },
@@ -81,6 +84,7 @@ const FACTS = () => [
'- WHAT IT IS: Viral Banner Blitz (' + URL_ + ') is one public loop of ' + C.loopSize + ' member banners (125x125 tiles). A posted banner waits in line, then enters at the front. Every ' + C.perShift + ' verified visitors shift every banner one place; the banner at the end rides out (has cycled) and its owner earns ' + C.viewsPerCycle + ' network ad views. Cycles are recorded on My Banners now; crediting those views to network advertising is NOT switched on yet.',
'- VERIFIED VISITOR: a real browser keeps the loop page open and visible about ' + C.visitSeconds + ' seconds; once per visitor per 24 hours; bots, crawlers, repeats and more than ' + C.perIpDay + ' browsers per connection per day do not count.',
'- POSTING: one post credit per banner. Network members (InstantAdPay or LinkSpin, checked with the network hub) get 1 free post credit each day they sign in (Central day). Up to ' + C.maxQueuedPerMember + ' banners waiting per member. Image 125x125, 100 KB max, or post a LinkSpin Banner Spin (125x125 or 250x250). The link must answer. SPIN tiles in empty places are LinkSpin Banner Spins: they never shift, cycle or earn.',
'- ONE SWAP PER BANNER: a banner that is waiting or in the loop can swap its image and/or link ONE time from My Banners (a Banner Spin to another of the member\'s own 125x125/250x250 spins). It keeps its id, place, clicks and loop progress; the new image and link get the same checks as a new post. No second swap. Members cannot withdraw or remove a banner and credits are not refunded. The admin can take a banner down (the owner sees the reason; the admin decides whether the post credit comes back); its place stays as a house tile until it would have ridden out, so nobody else moves, and it never cycles or earns.',
'- PACKAGES (one-time, POL at the live price, never a subscription, overpayment returned): ' + packs + '; banner look $' + C.lookUsd + ' per banner (border + hover teaser, on a waiting or in-loop banner, one per banner); tokens (network visits at the InstantAdPay visit rate) coming soon.',
'- SPLIT (VBBShop constants, no owner withdraw): 30% to the member who introduced the buyer (bound once, by a keeper-signed voucher, on the first purchase; none = company), 10% to the weekly prize pot, 60% company, same transaction. Failed sends wait in the contract for their owner to claim.',
'- LEADERBOARDS (Monday to Sunday Central): most verified visitors sent (the member\'s ?ref= link) and most different traffic sources (referring sites). Prize pot = 10% of the week\'s sales, half per board, top three ' + places + ' percent, paid in POL to the winners\' VBB wallets the following Monday at the POL price at payout; ties to whoever got there first. Never state a maximum or a cap.',