Alles mögliche
Some checks failed
Host-Based Deploy (Java 21 Fix) / build-and-run (push) Has been cancelled
Some checks failed
Host-Based Deploy (Java 21 Fix) / build-and-run (push) Has been cancelled
This commit is contained in:
@@ -314,6 +314,24 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Bereits in einem Lock-Dialog -->
|
||||
<div class="modal-overlay" id="activeLockModal">
|
||||
<div class="modal-bg" onclick="document.getElementById('activeLockModal').classList.remove('open')"></div>
|
||||
<div class="modal-box">
|
||||
<div style="font-size:2rem;">🔒</div>
|
||||
<h3 style="margin:0;text-align:center;">Du bist bereits in einem Lock</h3>
|
||||
<p style="color:var(--color-muted);font-size:0.85rem;text-align:center;margin:0;">
|
||||
Es ist bereits ein aktives Keuschheitslock für dein Konto vorhanden.
|
||||
Beende oder öffne zuerst das bestehende Lock.
|
||||
</p>
|
||||
<a id="activeLockLink" href="#" style="display:none;width:100%;">
|
||||
<button style="width:100%;">Zum aktiven Lock →</button>
|
||||
</a>
|
||||
<button class="btn-secondary" style="width:100%;"
|
||||
onclick="document.getElementById('activeLockModal').classList.remove('open')">Schließen</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Entsperrcode-Modal -->
|
||||
<div class="modal-overlay" id="unlockModal">
|
||||
<div class="modal-bg"></div>
|
||||
@@ -669,12 +687,29 @@
|
||||
el.style.display = '';
|
||||
el.scrollIntoView({ behavior: 'smooth', block: 'center' });
|
||||
}
|
||||
function showActiveLockError() {
|
||||
const el = document.getElementById('errorMsg');
|
||||
el.innerHTML = 'Du befindest dich bereits in einem aktiven Lock. '
|
||||
+ '<a href="/games/chastity/meine-locks.html" style="color:inherit;text-decoration:underline;">Zum aktiven Lock</a>';
|
||||
el.style.display = '';
|
||||
el.scrollIntoView({ behavior: 'smooth', block: 'center' });
|
||||
async function showActiveLockError() {
|
||||
const modal = document.getElementById('activeLockModal');
|
||||
const linkEl = document.getElementById('activeLockLink');
|
||||
linkEl.style.display = 'none';
|
||||
|
||||
// Eigenes aktives Lock suchen (CardLock oder TimeLock)
|
||||
try {
|
||||
const [cardRes, timeRes] = await Promise.all([
|
||||
fetch('/keyholder/mylock'),
|
||||
fetch('/keyholder/timelock/mylock')
|
||||
]);
|
||||
if (cardRes.status === 200) {
|
||||
const d = await cardRes.json();
|
||||
linkEl.href = '/games/chastity/activelock.html?lockId=' + d.lockId;
|
||||
linkEl.style.display = '';
|
||||
} else if (timeRes.status === 200) {
|
||||
const d = await timeRes.json();
|
||||
linkEl.href = '/games/chastity/activetimelock.html?lockId=' + d.lockId;
|
||||
linkEl.style.display = '';
|
||||
}
|
||||
} catch (_) {}
|
||||
|
||||
modal.classList.add('open');
|
||||
}
|
||||
function setFieldError(rowId, msg) {
|
||||
const row = document.getElementById(rowId);
|
||||
|
||||
Reference in New Issue
Block a user