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

Invalid date when I tried to save Catalog Price Rule with French locale in version 2.2.2. #13139

Closed
AleksLi opened this issue Jan 11, 2018 · 14 comments
Assignees
Labels
Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development Reproduced on 2.1.x The issue has been reproduced on latest 2.1 release Reproduced on 2.2.x The issue has been reproduced on latest 2.2 release Reproduced on 2.3.x The issue has been reproduced on latest 2.3 release

Comments

@AleksLi
Copy link
Contributor

AleksLi commented Jan 11, 2018

Preconditions

  1. Magento 2.2.2
  2. mysql Ver 15.1 Distrib 10.0.31-MariaDB, for debian-linux-gnu (x86_64) using readline 5.2
  3. PHP 7.0.22

Steps to reproduce

  1. Change admin language to French
  2. Go to Marketing->Catalog Price Rules and a create New one.
  3. In the Date Range choose date like this

Expected result

  1. Save this rule without errors.

Actual result

  1. I have an error because of the wrong date

It is the similar to #9743

@magento-engcom-team magento-engcom-team added the Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed label Jan 11, 2018
@AleksLi AleksLi changed the title Invalid date when customer validate with French locale in version 2.2.2. Invalid date when I tried to save Catalog Price Rule with French locale in version 2.2.2. Jan 11, 2018
@sunil-gcet
Copy link

Hello @magento-engcom-team i would like to take a look on this issue., can you please send the invitation

@sunil-gcet
Copy link

Hi @AleksLi i think i am close on finding the issue, i have replicated it on a fresh install of v2.2.2, although i think the issue is not due to locale but its due to the datepicker fields.

When i investigated i saw the date values to post are like 20/01/+00201818 instead of 20/01/2018 and thus the validation fails on vendor/magento/module-rule/Model/AbstractModel.php:399

I am moving to find the datepicker problem now, will let you know in sometime

@sunil-gcet
Copy link

sunil-gcet commented Jan 12, 2018

on further investigation it seems that the error is coming only on the date formats having year format like "yyyy", which are set from vendor/magento/zendframework1/library/Zend/Locale/Data/ folder for each teritory and language

So
M/d/yy working correctly
dd/MM/yyyy : not working
dd/MM/yy : working correctly

@magento-engcom-team can you let us know if we are correct in above findings ?

also will this date format issue will be covered in next release ?

@AleksLi
Copy link
Contributor Author

AleksLi commented Jan 12, 2018

Hi @sunil-gcet. I'm happy to hear that you are close to fixing this.
Keep me in the loop.

@magento-engcom-team
Copy link
Contributor

@AleksLi, thank you for your report.
We've acknowledged the issue and added to our backlog.

@magento-engcom-team magento-engcom-team added Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development Issue: Confirmed Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed Reproduced on 2.1.x The issue has been reproduced on latest 2.1 release Reproduced on 2.2.x The issue has been reproduced on latest 2.2 release Reproduced on 2.3.x The issue has been reproduced on latest 2.3 release Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed labels Jan 16, 2018
@attheCube
Copy link

@magento-engcom-team
I got the same problem after updating from 2.1.3 to 2.1.10 for german admin language.
Datepicker is formatting like dd.mm.yyyy and js-validation refuses.

@Detzler
Copy link

Detzler commented Feb 21, 2018

Datepicker is formatting like dd.mm.yyyy and js-validation refuses.

I agree - got the same issue

@sedax90
Copy link

sedax90 commented Feb 23, 2018

Same problem with italian language

@Aza-an
Copy link

Aza-an commented May 17, 2018

Same Issue for English(United Kingdom)

@sedax90
Copy link

sedax90 commented Jul 3, 2018

no update for 2.2.5?

@weblips
Copy link

weblips commented Nov 30, 2018

Same Issue for en_AU (2.2.5)

@codercv
Copy link

codercv commented Jan 30, 2019

Same for en_GB (2.2.5)

@engcom-Bravo engcom-Bravo self-assigned this Dec 30, 2019
@m2-assistant
Copy link

m2-assistant bot commented Dec 30, 2019

Hi @engcom-Bravo. Thank you for working on this issue.
Looks like this issue is already verified and confirmed. But if you want to validate it one more time, please, go though the following instruction:

  • 1. Add/Edit Component: XXXXX label(s) to the ticket, indicating the components it may be related to.

  • 2. Verify that the issue is reproducible on 2.4-develop branch

    Details- Add the comment @magento give me 2.4-develop instance to deploy test instance on Magento infrastructure.
    - If the issue is reproducible on 2.4-develop branch, please, add the label Reproduced on 2.4.x.
    - If the issue is not reproducible, add your comment that issue is not reproducible and close the issue and stop verification process here!

  • 3. If the issue is not relevant or is not reproducible any more, feel free to close it.


@engcom-Bravo engcom-Bravo removed the Issue: Confirmed Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed label Dec 30, 2019
@engcom-Bravo
Copy link
Contributor

Hello @AleksLi
On Magento 2.4-develop, a proper error message appears - "The end date must be greater than the start date"
date_error
So, we have to close it.
Please feel free to comment, reopen or create new ticket according to the Issue reporting guidelines .
Thank you for collaboration.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development Reproduced on 2.1.x The issue has been reproduced on latest 2.1 release Reproduced on 2.2.x The issue has been reproduced on latest 2.2 release Reproduced on 2.3.x The issue has been reproduced on latest 2.3 release
Projects
None yet
Development

No branches or pull requests

10 participants