farm fix between worlds

This commit is contained in:
2026-05-02 01:28:20 +03:00
parent 502b330ac5
commit 4272edf432
2 changed files with 16 additions and 7 deletions

View File

@@ -233,7 +233,7 @@
<body>
<div class="topbar">
<a href="/player/{{ player_id }}">← Πίσω</a>
<a href="/player/{{ player_id }}/{{ world_id }}">← Πίσω</a>
<h1>🌾 Farm Manager</h1>
<span class="online-dot" id="online-dot" title="Κατάσταση Script"></span>
<button class="sync-btn" onclick="requestSync()">Live Sync</button>
@@ -411,6 +411,7 @@
<script>
const PLAYER_ID = '{{ player_id }}';
const WORLD_ID = '{{ world_id }}';
let selectedOption = 1;
// -- Loot option buttons --
@@ -480,7 +481,7 @@
}
function loadFarmData() {
fetch(`/dashboard/farm-data?player_id=${PLAYER_ID}`)
fetch(`/dashboard/farm-data?player_id=${PLAYER_ID}&world_id=${WORLD_ID}`)
.then(r => r.json())
.then(resp => {
const data = resp.towns || [];