create events api wp

This commit is contained in:
2026-09-17 16:53:51 +02:00
parent 5df1f2d261
commit dea86cb6df
11 changed files with 1433 additions and 26 deletions
+9 -1
View File
@@ -67,6 +67,7 @@ $val = [
'what_to_bring' => $ev['what_to_bring'] ?? '',
'suitable_for' => $ev['suitable_for'] ?? '',
'gallery' => $ev['gallery'] ?? '',
'waitlist_enabled' => ($ev['waitlist_enabled'] ?? 'Y') === 'Y',
];
$isEdit = $id > 0;
@@ -531,7 +532,7 @@ $pageTitle = $isEdit ? 'Modifica evento' : 'Nuovo evento';
<label class="form-label">Colore card</label>
<input type="color" class="form-control" name="color" value="<?php echo e($val['color']); ?>">
</div>
<div class="col-md-9 mb-3">
<div class="col-md-5 mb-3">
<label class="form-label">Stato</label>
<select name="status" class="form-select">
<option value="draft" <?php echo $val['status'] === 'draft' ? 'selected' : ''; ?>>Bozza</option>
@@ -539,6 +540,13 @@ $pageTitle = $isEdit ? 'Modifica evento' : 'Nuovo evento';
<option value="cancelled" <?php echo $val['status'] === 'cancelled' ? 'selected' : ''; ?>>Annullato</option>
</select>
</div>
<div class="col-md-4 mb-3">
<label class="form-label">Lista d'attesa</label>
<div class="form-check form-switch" style="padding-top:8px;">
<input class="form-check-input" type="checkbox" role="switch" id="waitlist_enabled" name="waitlist_enabled" value="Y" <?php echo $val['waitlist_enabled'] ? 'checked' : ''; ?>>
<label class="form-check-label" for="waitlist_enabled" style="font-weight:400;">Consenti iscrizione a evento pieno</label>
</div>
</div>
</div>
<div class="d-flex justify-content-between mt-2">