Skip to content

[Fix]: Data values not formatted when coming from fields plugin custom fields - #655

Open
jdurand-teclib wants to merge 2 commits into
mainfrom
fix/45898/dates-from-fields-not-formatted
Open

[Fix]: Data values not formatted when coming from fields plugin custom fields#655
jdurand-teclib wants to merge 2 commits into
mainfrom
fix/45898/dates-from-fields-not-formatted

Conversation

@jdurand-teclib

Copy link
Copy Markdown

Checklist before requesting a review

Please delete options that are not relevant.

  • I have performed a self-review of my code.
  • I have updated the CHANGELOG with a short functional description of the fix or new feature.
  • This change requires a documentation update.

Description

  • It fixes !45898
  • Here is a brief description of what this PR does:
    • Fix an issue where data coming from fields plugin's custom fields are not passed through the formatting process before being injected in database.

No unit test were written because they would have involve references to Fields plugin, thus failing in the GitHub environment, as it is not linked to Fields plugin.

@Rom1-B Rom1-B 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.

!45898 also reports comma-decimal numbers from Fields custom fields failing to import, not just dates. GLPI's numeric datatype is 'decimal'/'number', never 'float', so this fallback won't trigger reformatFloat() for them. Follow-up planned?

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.

2 participants