{
"tool_response": {
"type": "update",
"filePath": "\/var\/www\/dev.campus.systemische-tools.de\/src\/View\/semantic-explorer\/stopwords\/edit.php",
"content": "<?php\n\ndeclare(strict_types=1);\n\n\/\/ @responsibility: View für Stopword bearbeiten mit HTMX-Formular\n\nob_start();\n?>\n\n<nav class=\"breadcrumb\">\n <a href=\"\/\">Campus KI<\/a> »\n <a href=\"\/semantic-explorer\">Semantic Explorer<\/a> »\n <a href=\"\/semantic-explorer\/stopwords\">Stopwords<\/a> » <?= htmlspecialchars($stopword['word']) ?>\n<\/nav>\n\n<h1>Stopword: <?= htmlspecialchars($stopword['word']) ?><\/h1>\n\n<form id=\"stopword-form\" class=\"form\" style=\"max-width: 600px;\"\n hx-post=\"\/semantic-explorer\/stopwords\/<?= $stopword['id'] ?>\"\n hx-headers='{\"X-CSRF-TOKEN\": \"<?= $csrfToken ?>\"}'\n hx-disabled-elt=\"button[type=submit]\">\n <div class=\"form-group\">\n <label for=\"word\">Wort *<\/label>\n <input type=\"text\" id=\"word\" name=\"word\" class=\"form-input\" required value=\"<?= htmlspecialchars($stopword['word']) ?>\">\n <\/div>\n\n <div class=\"form-group\">\n <label for=\"category\">Kategorie<\/label>\n <select id=\"category\" name=\"category\" class=\"form-select\">\n <option value=\"generic\" <?= $stopword['category'] === 'generic' ? 'selected' : '' ?>>Generisch - Immer ausschliessen<\/option>\n <option value=\"domain_specific\" <?= $stopword['category'] === 'domain_specific' ? 'selected' : '' ?>>Domain-spezifisch<\/option>\n <option value=\"context_dependent\" <?= $stopword['category'] === 'context_dependent' ? 'selected' : '' ?>>Kontextabhaengig<\/option>\n <\/select>\n <\/div>\n\n <div class=\"form-group\">\n <label for=\"reason\">Begruendung<\/label>\n <input type=\"text\" id=\"reason\" name=\"reason\" class=\"form-input\" value=\"<?= htmlspecialchars($stopword['reason'] ?? '') ?>\">\n <\/div>\n\n <div class=\"form-group\">\n <label class=\"checkbox-inline\">\n <input type=\"checkbox\" name=\"is_active\" value=\"1\" <?= $stopword['is_active'] ? 'checked' : '' ?>>\n Aktiv\n <\/label>\n <\/div>\n\n <div class=\"form-info\">\n <p><strong>Canonical Form:<\/strong> <code><?= htmlspecialchars($stopword['canonical_form']) ?><\/code><\/p>\n <p><strong>Erstellt:<\/strong> <?= htmlspecialchars($stopword['created_at']) ?><\/p>\n <p><strong>Aktualisiert:<\/strong> <?= htmlspecialchars($stopword['updated_at']) ?><\/p>\n <\/div>\n\n <div class=\"form-actions\">\n <button type=\"submit\" class=\"btn btn--primary\">Speichern<\/button>\n <a href=\"\/semantic-explorer\/stopwords\" class=\"btn\">Abbrechen<\/a>\n <button type=\"button\"\n class=\"btn btn--danger\"\n style=\"margin-left: auto;\"\n hx-post=\"\/semantic-explorer\/stopwords\/<?= $stopword['id'] ?>\/delete\"\n hx-headers='{\"X-CSRF-TOKEN\": \"<?= $csrfToken ?>\"}'\n hx-confirm=\"Stopword wirklich loeschen?\"\n hx-disabled-elt=\"this\">\n Loeschen\n <\/button>\n <\/div>\n<\/form>\n\n<?php $content = ob_get_clean(); ?>\n<?php require VIEW_PATH . '\/layout.php'; ?>\n",
"structuredPatch": [
{
"oldStart": 1,
"oldLines": 15,
"newStart": 1,
"newLines": 24,
"lines": [
"-<?php ob_start(); ?>",
"+<?php",
" ",
"+declare(strict_types=1);",
"+",
"+\/\/ @responsibility: View für Stopword bearbeiten mit HTMX-Formular",
"+",
"+ob_start();",
"+?>",
"+",
" <nav class=\"breadcrumb\">",
"+ <a href=\"\/\">Campus KI<\/a> »",
" <a href=\"\/semantic-explorer\">Semantic Explorer<\/a> »",
" <a href=\"\/semantic-explorer\/stopwords\">Stopwords<\/a> » <?= htmlspecialchars($stopword['word']) ?>",
" <\/nav>",
" ",
" <h1>Stopword: <?= htmlspecialchars($stopword['word']) ?><\/h1>",
" ",
"-<form id=\"stopword-form\" method=\"post\" action=\"\/semantic-explorer\/stopwords\/<?= $stopword['id'] ?>\" class=\"form\" style=\"max-width: 600px;\">",
"- <input type=\"hidden\" name=\"_csrf_token\" value=\"<?= htmlspecialchars($_SESSION['_csrf_token'] ?? '') ?>\">",
"-",
"+<form id=\"stopword-form\" class=\"form\" style=\"max-width: 600px;\"",
"+ hx-post=\"\/semantic-explorer\/stopwords\/<?= $stopword['id'] ?>\"",
"+ hx-headers='{\"X-CSRF-TOKEN\": \"<?= $csrfToken ?>\"}'",
"+ hx-disabled-elt=\"button[type=submit]\">",
" <div class=\"form-group\">",
" <label for=\"word\">Wort *<\/label>",
" <input type=\"text\" id=\"word\" name=\"word\" class=\"form-input\" required value=\"<?= htmlspecialchars($stopword['word']) ?>\">"
]
},
{
"oldStart": 44,
"oldLines": 24,
"newStart": 53,
"newLines": 18,
"lines": [
" ",
" <div class=\"form-actions\">",
" <button type=\"submit\" class=\"btn btn--primary\">Speichern<\/button>",
"- <button type=\"button\" class=\"btn btn--danger\" onclick=\"if(confirm('Stopword wirklich loeschen?')) { document.getElementById('delete-form').submit(); }\">Loeschen<\/button>",
" <a href=\"\/semantic-explorer\/stopwords\" class=\"btn\">Abbrechen<\/a>",
"+ <button type=\"button\"",
"+ class=\"btn btn--danger\"",
"+ style=\"margin-left: auto;\"",
"+ hx-post=\"\/semantic-explorer\/stopwords\/<?= $stopword['id'] ?>\/delete\"",
"+ hx-headers='{\"X-CSRF-TOKEN\": \"<?= $csrfToken ?>\"}'",
"+ hx-confirm=\"Stopword wirklich loeschen?\"",
"+ hx-disabled-elt=\"this\">",
"+ Loeschen",
"+ <\/button>",
" <\/div>",
" <\/form>",
" ",
"-<form id=\"delete-form\" method=\"post\" action=\"\/semantic-explorer\/stopwords\/<?= $stopword['id'] ?>\/delete\" style=\"display:none;\">",
"- <input type=\"hidden\" name=\"_csrf_token\" value=\"<?= htmlspecialchars($_SESSION['_csrf_token'] ?? '') ?>\">",
"-<\/form>",
"-",
"-<?php if (isset($_SESSION['success'])): ?>",
"-<div class=\"form-message form-message--success\"><?= htmlspecialchars($_SESSION['success']) ?><\/div>",
"-<?php unset($_SESSION['success']); ?>",
"-<?php endif; ?>",
"-",
"-<?php if (isset($_SESSION['error'])): ?>",
"-<div class=\"form-message form-message--error\"><?= htmlspecialchars($_SESSION['error']) ?><\/div>",
"-<?php unset($_SESSION['error']); ?>",
"-<?php endif; ?>",
"-",
" <?php $content = ob_get_clean(); ?>",
" <?php require VIEW_PATH . '\/layout.php'; ?>"
]
}
],
"originalFile": "<?php ob_start(); ?>\n\n<nav class=\"breadcrumb\">\n <a href=\"\/semantic-explorer\">Semantic Explorer<\/a> »\n <a href=\"\/semantic-explorer\/stopwords\">Stopwords<\/a> » <?= htmlspecialchars($stopword['word']) ?>\n<\/nav>\n\n<h1>Stopword: <?= htmlspecialchars($stopword['word']) ?><\/h1>\n\n<form id=\"stopword-form\" method=\"post\" action=\"\/semantic-explorer\/stopwords\/<?= $stopword['id'] ?>\" class=\"form\" style=\"max-width: 600px;\">\n <input type=\"hidden\" name=\"_csrf_token\" value=\"<?= htmlspecialchars($_SESSION['_csrf_token'] ?? '') ?>\">\n\n <div class=\"form-group\">\n <label for=\"word\">Wort *<\/label>\n <input type=\"text\" id=\"word\" name=\"word\" class=\"form-input\" required value=\"<?= htmlspecialchars($stopword['word']) ?>\">\n <\/div>\n\n <div class=\"form-group\">\n <label for=\"category\">Kategorie<\/label>\n <select id=\"category\" name=\"category\" class=\"form-select\">\n <option value=\"generic\" <?= $stopword['category'] === 'generic' ? 'selected' : '' ?>>Generisch - Immer ausschliessen<\/option>\n <option value=\"domain_specific\" <?= $stopword['category'] === 'domain_specific' ? 'selected' : '' ?>>Domain-spezifisch<\/option>\n <option value=\"context_dependent\" <?= $stopword['category'] === 'context_dependent' ? 'selected' : '' ?>>Kontextabhaengig<\/option>\n <\/select>\n <\/div>\n\n <div class=\"form-group\">\n <label for=\"reason\">Begruendung<\/label>\n <input type=\"text\" id=\"reason\" name=\"reason\" class=\"form-input\" value=\"<?= htmlspecialchars($stopword['reason'] ?? '') ?>\">\n <\/div>\n\n <div class=\"form-group\">\n <label class=\"checkbox-inline\">\n <input type=\"checkbox\" name=\"is_active\" value=\"1\" <?= $stopword['is_active'] ? 'checked' : '' ?>>\n Aktiv\n <\/label>\n <\/div>\n\n <div class=\"form-info\">\n <p><strong>Canonical Form:<\/strong> <code><?= htmlspecialchars($stopword['canonical_form']) ?><\/code><\/p>\n <p><strong>Erstellt:<\/strong> <?= htmlspecialchars($stopword['created_at']) ?><\/p>\n <p><strong>Aktualisiert:<\/strong> <?= htmlspecialchars($stopword['updated_at']) ?><\/p>\n <\/div>\n\n <div class=\"form-actions\">\n <button type=\"submit\" class=\"btn btn--primary\">Speichern<\/button>\n <button type=\"button\" class=\"btn btn--danger\" onclick=\"if(confirm('Stopword wirklich loeschen?')) { document.getElementById('delete-form').submit(); }\">Loeschen<\/button>\n <a href=\"\/semantic-explorer\/stopwords\" class=\"btn\">Abbrechen<\/a>\n <\/div>\n<\/form>\n\n<form id=\"delete-form\" method=\"post\" action=\"\/semantic-explorer\/stopwords\/<?= $stopword['id'] ?>\/delete\" style=\"display:none;\">\n <input type=\"hidden\" name=\"_csrf_token\" value=\"<?= htmlspecialchars($_SESSION['_csrf_token'] ?? '') ?>\">\n<\/form>\n\n<?php if (isset($_SESSION['success'])): ?>\n<div class=\"form-message form-message--success\"><?= htmlspecialchars($_SESSION['success']) ?><\/div>\n<?php unset($_SESSION['success']); ?>\n<?php endif; ?>\n\n<?php if (isset($_SESSION['error'])): ?>\n<div class=\"form-message form-message--error\"><?= htmlspecialchars($_SESSION['error']) ?><\/div>\n<?php unset($_SESSION['error']); ?>\n<?php endif; ?>\n\n<?php $content = ob_get_clean(); ?>\n<?php require VIEW_PATH . '\/layout.php'; ?>\n"
}
}