Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Date wrong #50

Open
MRohweder opened this issue Aug 1, 2022 · 6 comments
Open

Date wrong #50

MRohweder opened this issue Aug 1, 2022 · 6 comments

Comments

@MRohweder
Copy link

On Dolibarr 14 is an problem with the imported Date
Screenshot_20220801_212928
Value Date and Transaction date are 1970 after import.
at import mask date shown correctly.

@hanneshier
Copy link

Did you found a solution for that bug?

@hanneshier
Copy link

Did you found a solution for that bug?

For me it was just entering the wrong date format 🤦 I was using the standard d/m/Y instead of d.m.Y

@MRohweder
Copy link
Author

No thats not on my side.
i use the %d.%m.%y as seen inside csv file.
I can import the file and on page where i can select what kind of transaction each line is, everything works.
But than i create transactions.
And after that at transaction overview all date files are like this.

@hanneshier
Copy link

i use the %d.%m.%y as seen inside csv file.

How many digits does your year representation have? Because for four digit year representation, it has to be an uppercase Y.

There is more information in this article.

Also, I don't use their % sign, but I don't know if that makes any difference 🤷

@glu000
Copy link

glu000 commented Jan 9, 2023

I have the same problem. Analysing the source-code shows that the module is using str_getcsv. This function is not working when using standard German locale settings. See https://www.php.net/manual/de/function.str-getcsv.php

By the way: As the module is using the function DateTime::createFromFormat to parse the date, you should'nt use % in the format string. So it should be d.m.Y for standard German dates

@mnrbig
Copy link

mnrbig commented Sep 23, 2024

Hi,

This is still an issue on Dolibarr 19 and changing formats doesn't solve it. Does anyone have other ideas as to what may be causing it?

Thanks

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

No branches or pull requests

4 participants