Poprawka botto bar i wersje językowe

This commit is contained in:
2026-09-25 17:39:44 +02:00
parent 3056eb6c3d
commit a381ad09d8
21 changed files with 770 additions and 428 deletions
+5 -1
View File
@@ -1,5 +1,6 @@
const API_URL = '../../api/waiter_feed.php';
const POLL_MS = 15000;
const FEED_TOKEN = String(window.WAITER_CONFIG?.feedToken || '');
const feedList = document.getElementById('feedList');
const emptyState = document.getElementById('emptyState');
@@ -238,7 +239,10 @@ function setSyncState(ok, message) {
async function pollFeed() {
try {
const response = await fetch(API_URL, { cache: 'no-store' });
const response = await fetch(API_URL, {
cache: 'no-store',
headers: FEED_TOKEN ? { 'X-Waiter-Token': FEED_TOKEN } : {},
});
const result = await response.json();
if (result.status !== 'success') {