Skip to content

Conversation

@skerbis
Copy link
Member

@skerbis skerbis commented Oct 30, 2025

fixed: #170

BREAKING CHANGES:

  • Renamed all YForm fields with neues_ prefix to resolve conflicts with yform_field addon
    • choice_status → neues_choice_status
    • datetime_local → neues_datetime_local
    • domain → neues_domain
  • Updated tableset.json with new field type names
  • Migration logic for existing installations

NEW FEATURES:

  • JSON Feed API implementation (JSON Feed 1.1 standard)
    • Available at: ?rex-api-call=neues_json
    • Supports same filters as RSS: category_id, lang_id, domain_id
    • Additional pagination with limit/offset parameters
  • Enhanced RSS Feed with domain filtering
  • Improved installation process with ycom-style cache management

IMPROVEMENTS:

  • Documentation cleanup and consistency
  • Menu renamed from 'Aktuelles' to 'Neues'
  • Enhanced error handling and migration support
  • Added comprehensive cleanup tools for duplicate fields

Resolves: #170 - YForm field conflicts with yform_field addon

Summary by CodeRabbit

Release Notes v7.0.0

  • New Features

    • JSON Feed API für News-Einträge verfügbar
    • Erweiterte RSS- und JSON-Feed-Filterung nach Domain
  • Breaking Changes

    • Version 7.0.0 mit YForm-Feldnamen-Migration
    • URL2-Addon-Unterstützung durch URL-Profile ersetzt
    • Menu-Label „Aktuelles" → „Neues"
  • Dokumentation

    • Dokumentation für JSON Feed API hinzugefügt
    • Migrations- und Cleanup-Anleitungen bereitgestellt
    • Anforderungen und Funktionen aktualisiert

…Feed API

BREAKING CHANGES:
- Renamed all YForm fields with neues_ prefix to resolve conflicts with yform_field addon
  - choice_status → neues_choice_status
  - datetime_local → neues_datetime_local
  - domain → neues_domain
- Updated tableset.json with new field type names
- Migration logic for existing installations

NEW FEATURES:
- JSON Feed API implementation (JSON Feed 1.1 standard)
  - Available at: ?rex-api-call=neues_json
  - Supports same filters as RSS: category_id, lang_id, domain_id
  - Additional pagination with limit/offset parameters
- Enhanced RSS Feed with domain filtering
- Improved installation process with ycom-style cache management

IMPROVEMENTS:
- Documentation cleanup and consistency
- Menu renamed from 'Aktuelles' to 'Neues'
- Enhanced error handling and migration support
- Added comprehensive cleanup tools for duplicate fields

Resolves: #170 - YForm field conflicts with yform_field addon
Copilot AI review requested due to automatic review settings October 30, 2025 19:26
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Oct 30, 2025

Caution

Review failed

The pull request is closed.

Note

Other AI code review bot(s) detected

CodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review.

Moin!

Walkthrough

Das PR löst einen Konflikt mit dem yform_field-Addon durch Umbenennung von YForm-Feldtypen (choice_status, datetime_local, domain) in addon-spezifische Namen (neues_choice_status, neues_datetime_local, neues_domain). Versionsbump auf 7.0.0 mit Migration, Cleanup-Scripts und neuer JSON-Feed-API.

Changes

Cohort / Datei(en) Zusammenfassung
Versionierung & Konfiguration
package.yml, CHANGELOG.md
Versionsbump von 6.1.0-beta1 auf 7.0.0; Entfernung der yform_field-Konflikt-Definition; neue Breaking Changes dokumentiert
YForm-Feldtypen-Umbenennung
lib/Field/value/neues_choice_status.php, lib/Field/value/neues_datetime_local.php, lib/Field/value/neues_domain.php
Klassen und API-Signaturen umbenennt (z.B. rex_yform_value_choice_status → rex_yform_value_neues_choice_status); Template-Rendering angepasst; getDefinitions()-Rückgabewerte aktualisiert
Tableset-Konfiguration
install/tableset.json
Feldtyp-Identifikatoren mit neues_-Präfix versehen (choice_status, datetime_local, domain)
Migration & Cleanup
install/migrate_v7.php, install/cleanup_v7.php, cleanup_manual.php, cleanup_duplicates.sql
Neue Scripts für Feldnamen-Migration und Duplikat-Bereinigung; YForm-Cache-Management und Tablenklassen-Regeneration
Installations-Script
install.php
YForm-Cache-Verwaltung integriert; Tableset-Import erweitert; v7.0.0-Migrationscode für Feldnamen-Updates hinzugefügt
API-Implementierung
lib/Api/JsonFeed.php, lib/Api/Rss.php
Neue JSON-Feed-API (JSON Feed 1.1) mit Filterung (category_id, lang_id, domain_id); RSS-Endpoint konsolidiert mit Multi-Domain-Filterung
Dokumentation
README.md, docs/01_a_intro.md, docs/02_settings.md, docs/06_url.md, docs/07_rss.md, docs/08_json_feed.md
Menü-Labels von "Aktuelles" auf "Neues" geändert; URL2 auf URL-Profile aktualisiert; neue JSON-Feed-API-Dokumentation; RSS-Domain-Filterung beschrieben
Lokalisierung
lang/de_de.lang
Übersetzungen für neues, neues_title, neues_entry_publish_cronjob aktualisiert

Sequence Diagram(s)

sequenceDiagram
    participant Admin as Admin/Installer
    participant Install as install.php
    participant Migrate as migrate_v7.php
    participant Cleanup as cleanup_v7.php
    participant YForm as YForm Manager
    participant DB as Datenbank

    Admin->>Install: Version 7.0.0 Installation
    Install->>Install: Cache löschen (vor Import)
    Install->>YForm: Tableset aus JSON importieren
    YForm->>DB: Tabellen mit neuen Feldtypen erstellen
    Install->>Migrate: v7.0.0-Migration aufrufen
    Migrate->>DB: Alte Feldnamen (choice_status, etc.) finden
    Migrate->>DB: type_name in neues_* umbenennen
    Migrate->>YForm: Tablenklassen regenerieren
    Install->>Cleanup: Duplikate aufräumen
    Cleanup->>DB: Duplikate identifizieren
    Cleanup->>DB: Alte Felder löschen/umbenennen
    Cleanup->>YForm: Tablenklassen neu laden
    Install->>Install: Finale Cache-Bereinigung
    Install-->>Admin: Installation abgeschlossen
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

Bereiche mit erhöhter Aufmerksamkeit:

  • Feldtyp-Umbenennung & YForm-Integration: Die drei YForm-Feldklassen wurden umbenannt; kritisch ist, dass die Migrations- und Cleanup-Logik in install.php, install/migrate_v7.php und install/cleanup_v7.php korrekt funktionieren und keine Daten verloren gehen
  • Tableset-Migration: Der Import von tableset.json mit neuen Feldtypen muss mit der Datenbank-Migration synchron laufen; fehlerhafte Reihenfolge könnte zu verwaisten Feldern führen
  • JSON Feed API: Neue Klasse mit Filterlogik; Domain-Filterung muss die Datenbankabfrage korrekt handhaben (NULL/leere Domains)
  • Rückwärtskompatibilität: Version 7.0.0 mit Breaking Changes — die Migration muss für bestehende Installationen sicher sein
  • Lokalisierung & Dokumentation: Umfangreiche Text-Updates; sollte auf Konsistenz mit Codeänderungen geprüft werden

Possibly related PRs

  • PR Free from yform field addon #169: Berührt die gleichen YForm-Feldimplementierungen (choice_status, datetime_local, domain) — direkter Zusammenhang zu dieser Umbenennung und Konfliktauflösung
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch v7.0

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between aaba05e and 78ab12f.

📒 Files selected for processing (20)
  • CHANGELOG.md (1 hunks)
  • README.md (3 hunks)
  • cleanup_duplicates.sql (1 hunks)
  • cleanup_manual.php (1 hunks)
  • docs/01_a_intro.md (2 hunks)
  • docs/02_settings.md (1 hunks)
  • docs/06_url.md (1 hunks)
  • docs/07_rss.md (1 hunks)
  • docs/08_json_feed.md (1 hunks)
  • install.php (4 hunks)
  • install/cleanup_v7.php (1 hunks)
  • install/migrate_v7.php (1 hunks)
  • install/tableset.json (3 hunks)
  • lang/de_de.lang (2 hunks)
  • lib/Api/JsonFeed.php (1 hunks)
  • lib/Api/Rss.php (1 hunks)
  • lib/Field/value/neues_choice_status.php (3 hunks)
  • lib/Field/value/neues_datetime_local.php (3 hunks)
  • lib/Field/value/neues_domain.php (3 hunks)
  • package.yml (1 hunks)

Warning

Tools execution failed with the following error:

Failed to run tools: 14 UNAVAILABLE: Connection dropped


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@skerbis skerbis merged commit 533e97e into main Oct 30, 2025
@skerbis skerbis deleted the v7.0 branch October 30, 2025 19:26
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR prepares version 7.0.0 of the neues addon, resolving naming conflicts with the yform_field addon by renaming custom YForm field types with a neues_ prefix. Additionally, it introduces a new JSON Feed API and updates branding from "Aktuelles" to "Neues."

Key changes:

  • Renamed three custom YForm field types to avoid conflicts: choice_statusneues_choice_status, datetime_localneues_datetime_local, domainneues_domain
  • Added JSON Feed 1.1 API support alongside existing RSS feed
  • Updated German language strings and documentation from "Aktuelles" to "Neues"

Reviewed Changes

Copilot reviewed 20 out of 23 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
package.yml Bumped version to 7.0.0, removed yform_field conflict declaration
lib/Field/value/*.php Renamed field classes and updated template references
ytemplates/bootstrap/*.tpl.php Created new template files for renamed field types
install/tableset.json Updated type_name values to use new field names
install.php Added migration logic for field renaming and cache management
install/migrate_v7.php Migration script for updating existing field definitions
install/cleanup_v7.php Cleanup script for removing duplicate fields
cleanup_manual.php Manual cleanup utility script
cleanup_duplicates.sql SQL script for database cleanup
lib/Api/JsonFeed.php New JSON Feed 1.1 API implementation
lib/Api/Rss.php Enhanced RSS feed with domain filtering
docs/*.md Updated documentation with new naming and JSON Feed API
lang/de_de.lang Changed "Aktuelles" to "Neues"
README.md Updated documentation with JSON Feed API information
CHANGELOG.md Added 7.0.0 release notes


use const JSON_PRETTY_PRINT;
use const JSON_UNESCAPED_UNICODE;

Copy link

Copilot AI Oct 30, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The JsonFeed API class is never registered in boot.php. While the class is created and documented, it cannot be called via ?rex-api-call=neues_json without adding rex_api_function::register('neues_json', Api\JsonFeed::class); in boot.php (similar to line 41 for the RSS feed).

Copilot uses AI. Check for mistakes.
*/

// REDAXO Bootstrap (passen Sie den Pfad an Ihre Installation an)
$redaxoPath = __DIR__ . '/../../../../../../../../';
Copy link

Copilot AI Oct 30, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The path uses an excessive number of parent directory references (9 levels). This appears incorrect for a REDAXO addon structure which is typically located at redaxo/src/addons/neues/. A more reasonable path would be __DIR__ . '/../../../' to reach the REDAXO root from the addon directory.

Suggested change
$redaxoPath = __DIR__ . '/../../../../../../../../';
$redaxoPath = __DIR__ . '/../../../';

Copilot uses AI. Check for mistakes.

if ($totalCleaned > 0) {
echo "📄 Lade Tableset neu...\n";
rex_yform_manager_table_api::importTablesets(rex_file::get(__DIR__ . '/tableset.json', '[]'));
Copy link

Copilot AI Oct 30, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The path __DIR__ . '/tableset.json' is incorrect. Based on the repository structure, the tableset.json file is located at install/tableset.json, so this should be __DIR__ . '/install/tableset.json' to match the pattern used in install.php line 38.

Suggested change
rex_yform_manager_table_api::importTablesets(rex_file::get(__DIR__ . '/tableset.json', '[]'));
rex_yform_manager_table_api::importTablesets(rex_file::get(__DIR__ . '/install/tableset.json', '[]'));

Copilot uses AI. Check for mistakes.
# Changelog

## xx-xx-2024 x.x.x (**Breacking Changes ⚠**)
## 30-10-2025 7.0.0 (**Breaking Changes ⚠**)
Copy link

Copilot AI Oct 30, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The CHANGELOG does not mention the new JSON Feed API feature, which is a significant addition documented in docs/08_json_feed.md and mentioned in the README. This should be included in the 'Weitere Änderungen' section.

Copilot uses AI. Check for mistakes.
$category = Category::get($category_id);
}

// Basis-Query für alle Filter
Copy link

Copilot AI Oct 30, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nitpick] Corrected spelling of 'Basis-Query' to 'Basis-Abfrage' for consistency with German comments, or use English 'Base query' for consistency with code.

Suggested change
// Basis-Query für alle Filter
// Basis-Abfrage für alle Filter

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Konflikt mit yform_field auflösen

2 participants