<?php
/**
 * @var Laminas\View\Renderer\PhpRenderer $this
 * @var \Tour\Entity\Structure $structure
 */
$this->headTitle('Modifier - ' . $structure->getName());
?>
<h1>Modifier <?= $this->escapeHtml($structure->getName()) ?></h1>

<form method="post" class="mt-4">
    <div class="mb-3">
        <label class="form-label">Nom</label>
        <input type="text" name="name" class="form-control" value="<?= $this->escapeHtml($structure->getName()) ?>" required>
    </div>
    <div class="mb-3">
        <label class="form-label">Description</label>
        <textarea name="description" class="form-control" rows="3"><?= $this->escapeHtml($structure->getDescription() ?? '') ?></textarea>
    </div>
    <button type="submit" class="btn btn-primary">Enregistrer</button>
    <a href="<?= $this->url('structures', ['action' => 'view', 'id' => $structure->getId()]) ?>" class="btn btn-secondary">Annuler</a>
</form>
