Skip to content

OTP-Einstellungen in Plugin-Config & Integration von YCOM_CONFIG Endp…#515

Merged
dergel merged 1 commit into
yakamara:masterfrom
ropaweb:otp-ep
Jun 23, 2025
Merged

OTP-Einstellungen in Plugin-Config & Integration von YCOM_CONFIG Endp…#515
dergel merged 1 commit into
yakamara:masterfrom
ropaweb:otp-ep

Conversation

@iriswerner

Copy link
Copy Markdown
Contributor

…oint

  • OTP-Einstellungen werden im ycom/auth namespace (Plugin-Config) gespeichert
  • statt Config-Values direkt aus der Datenbank zu holen, wird rex_ycom_config::get() verwendet
    • dadurch sind die OTP-Konfigurationen über den Endpoint YCOM_CONFIG überschreibbar
  • Anpassung der Dokumentation

…oint

- OTP-Einstellungen werden im ycom/auth namespace (Plugin-Config) gespeichert
- statt Config-Values direkt aus der Datenbank zu holen, wird rex_ycom_config::get() verwendet
    - dadurch sind die OTP-Konfigurationen über den Endpoint YCOM_CONFIG überschreibbar
- Anpassung der Dokumentation

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

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 updates the OTP configuration retrieval for the ycom/auth plugin to allow OTP settings to be overwritten via the YCOM_CONFIG endpoint and improves the related documentation.

  • Refactored OTP configuration retrieval from rex_addon::get to rex_ycom_config::get in both the yform value and injection handlers.
  • Updated the plugin configuration fetching in settings-related methods to use rex_plugin::get, ensuring OTP settings are fetched from the correct context.
  • Updated the documentation tables to include the new OTP configuration details.

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
plugins/auth/lib/yform/value/ycom_auth_otp.php Refactored OTP config retrieval using rex_ycom_config::get.
plugins/auth/lib/injections/otp.php Replaced direct addon config retrieval with rex_ycom_config::get and updated plugin fetching for settings.
docs/02_settings.md Updated documentation to include OTP configuration table entries.
Comments suppressed due to low confidence (3)

plugins/auth/lib/yform/value/ycom_auth_otp.php:15

  • Consider verifying if a default value (like 0) should be provided here for consistency with calls in other parts of the code.
$otp_article_id = (int) rex_ycom_config::get('otp_article_id');

plugins/auth/lib/injections/otp.php:13

  • Ensure that providing a default value of 0 in this context aligns with the intended configuration behavior and is consistent across the codebase.
$otp_article_id = (int) rex_ycom_config::get('otp_article_id', 0);

plugins/auth/lib/injections/otp.php:47

  • Confirm that switching from rex_addon::get to rex_plugin::get for retrieving configuration in getSettingsContent is intended, as it may affect where configurations are stored.
$addon = rex_plugin::get('ycom', 'auth');

@AWqxKAWERbXo

Copy link
Copy Markdown
Contributor

Hallo @dergel, der PR wurde gemeinsam von uns @iriswerner @j4ceee @alxndr-w eingereichtet, federführend entwickelt von @j4ceee im Rahmen seiner Abschlussarbeit und eines realen Projekts.

Wäre klasse, den Anzunehmen oder Feedback zu erhalten, ob alles passt oder nicht. Tests wünschst du dir ja eigentlich und hier ist aufgefallen, dass was noch nicht passt.

VG

@dergel dergel merged commit 429aba4 into yakamara:master Jun 23, 2025
2 of 3 checks passed
@AWqxKAWERbXo AWqxKAWERbXo deleted the otp-ep branch June 23, 2025 15:15
@AWqxKAWERbXo

Copy link
Copy Markdown
Contributor

Vielen Dank @dergel im Namen auch der anderen.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants