Placement switch: drop the cached member view on change and redraw fresh (Clinton #218 saw 'Team rotation' for up to 2 min after choosing Direct)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
martbost
2026-10-02 12:57:12 -05:00
parent 451bd50eb3
commit b43d3ba1af
3 changed files with 3 additions and 2 deletions
+1 -1
View File
@@ -849,7 +849,7 @@
try{
const r=await (await fetch('/api/public/placement',{method:'POST',headers:{'Content-Type':'application/json'},body:JSON.stringify({mode:m})})).json();
if(r&&r.error){ const ex=document.getElementById('plExplain'); if(ex)ex.textContent=r.error; return; }
load(d.id); // redraw from the server so the panel and the copy can never disagree
try{sessionStorage.setItem('rmc.fresh','1')}catch(e){} load(d.id); // redraw from the server (cache-bypassing) so the panel and the copy can never disagree
}catch(e){}
};
const bt=document.getElementById('plTeam'), bd=document.getElementById('plDirect');