mirror of
https://codeberg.org/PostERG/xamxam.git
synced 2026-06-25 08:09:18 +02:00
Reintroduce TFE duration metadata: DB columns, form fields, controllers, views, and migration
Add 'unsafe-eval' to CSP script-src directives (htmx requires Function())
This commit is contained in:
@@ -123,12 +123,12 @@ extract(FormBootstrap::adminFormVariables(
|
||||
mode: 'edit',
|
||||
formAction: '/admin/actions/edit.php',
|
||||
hiddenFields:
|
||||
'<input type="hidden" name="csrf_token" value="' . htmlspecialchars($_SESSION['csrf_token']) . '">'
|
||||
. '<input type="hidden" name="thesis_id" value="' . $thesisId . '">',
|
||||
'<input type="hidden" name="csrf_token" value="' . htmlspecialchars($_SESSION['csrf_token']) . '">',
|
||||
formData: $formData,
|
||||
siteSettings: $siteSettings,
|
||||
helpBlocks: $helpBlocks,
|
||||
options: [
|
||||
'thesisId' => $thesisId,
|
||||
'filesMode' => 'edit',
|
||||
'existingWebsiteUrl' => $existingWebsiteUrl,
|
||||
'existingWebsiteLabel' => $existingWebsiteLabel,
|
||||
@@ -144,6 +144,8 @@ extract(FormBootstrap::adminFormVariables(
|
||||
'currentFiles' => $currentFiles ?? [],
|
||||
'currentContextNote' => $currentContextNote ?? null,
|
||||
'currentContactVisible' => $currentContactVisible ?? null,
|
||||
'currentDurationValue' => $currentDurationValue ?? null,
|
||||
'currentDurationUnit' => $currentDurationUnit ?? 'pages',
|
||||
'contactInterne' => $contactInterne ?? null,
|
||||
'contactPublic' => $contactPublic ?? false,
|
||||
'showCoverPreview' => true,
|
||||
@@ -158,6 +160,10 @@ $formData['license_id'] = $currentLicenseId;
|
||||
$formData['license_custom'] = $currentRaw['license_custom'] ?? '';
|
||||
$formData['cc2r'] = $currentRaw['cc2r'] ?? false;
|
||||
|
||||
// Duration variables for the form template
|
||||
$durationValue = $currentDurationValue ?? null;
|
||||
$durationUnit = $currentDurationUnit ?? 'pages';
|
||||
|
||||
// Asset arrays and page chrome
|
||||
$isAdmin = true;
|
||||
$bodyClass = 'admin-body';
|
||||
|
||||
Reference in New Issue
Block a user