This repository has been archived by the owner on Dec 13, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 240
Mon 3834 display datetime in csv export #7533
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
kduret
suggested changes
May 13, 2019
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should be better to use ISO-8601 date format :
php function ==> date('c', $timestamp)
kduret
approved these changes
May 13, 2019
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
but not sure this could be apply everywhere cause sometimes date and time are in separated columns
indeed, they are (in the foreach) |
loiclau
reviewed
May 14, 2019
Co-Authored-By: loiclau <loic.lau@gmail.com>
Co-Authored-By: loiclau <loic.lau@gmail.com>
Co-Authored-By: loiclau <loic.lau@gmail.com>
Co-Authored-By: loiclau <loic.lau@gmail.com>
Co-Authored-By: loiclau <loic.lau@gmail.com>
Co-Authored-By: loiclau <loic.lau@gmail.com>
loiclau
approved these changes
May 14, 2019
sc979
added a commit
that referenced
this pull request
May 16, 2019
* enh(BE): securise id from request * style and PSR2 * enh(csv): homogenize exported date values' format * enh(BE): filter sanitize strings from REQUEST * fix(BE): setting a start date if the user didn't
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Pull Request Template
Description
Correct the date in the exported csv files :
1 - Convert the timestamps to formatted dates/times for each occurences.
2 - Homogenize the formatted start and end date.
3 - improve string sent from request security
4 - setting a default start date if the user didn't chose a period, nor a start date (to avoid to display/export logs since 1/1/1970 -> timestamp = 0 )
Fixes # (support)
Type of change
Target serie
How this pull request can be tested ?
Please describe the procedure to verify that the goal of the PR is matched. Provide clear instructions so that it can be correctly tested.
1 - Go to Monitoring -> event logs, choose a resource -> export the csv -> then check the csv output
2 - Go to Monitoring -> event logs, choose a resource and a start date -> export the csv -> then check the csv output
3 - Go to Monitoring -> event logs, choose a resource and a period -> export the csv -> then check the csv output
do the same for Monitoring -> system logs
Checklist
Community contributors & Centreon team