Поправлен html

This commit is contained in:
MpakobecEx 2026-05-27 23:39:27 +05:00
parent a886ae094d
commit 80d446443c
1 changed files with 6 additions and 1 deletions

View File

@ -313,7 +313,11 @@
async function showQRModal(recordId) { async function showQRModal(recordId) {
try { try {
const response = await fetch(`/get_qr_code/${recordId}`); const response = await fetch(`/get_qr_code/${recordId}`, {
headers: {
'X-TG-Init-Data': tg.initData
}
});
const data = await response.json(); const data = await response.json();
if (data.qr_code) { if (data.qr_code) {
@ -343,6 +347,7 @@
alert('QR-код отсутствует'); alert('QR-код отсутствует');
} }
} catch (e) { } catch (e) {
console.error(e);
alert('Ошибка загрузки QR'); alert('Ошибка загрузки QR');
} }
} }