1

How to set format datetime for all system ?

Such as: date attributes of entity(product, customer etc), import, export etc

Anyone know, please show me step by step.

  • I don't fully understand what is mean "format datetime for all system"? Datetime is formatted based on locale – KAndy Mar 24 '16 at 9:03
  • @Kandy we are facing same issue need date time format dd/mm/yyyy but its showing mm/dd/yyyy – Pradeep Singh Mar 31 '16 at 7:48
1

You need override date.js file from:

vendor/magento/Magento_Ui/web/js/form/element/date.js

To your vendor/Theme, ex.:

/app/design/frontend/Your_Vendor_Name\Your_Theme_Name/Magento_Ui/web/js/form/element/date.js

Choose your features and date format options and deploy new static files:

sudo rm -rf pub/static/*

And run Magento2 CLI command:

php -f bin/magento setup:static-content:deploy en_US 

If Magento Cache in use/enable, need clean , run command:

php -f bin/magento cache:clean
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.