Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

456
Views
date formatting datefield in django

I want to have the given format "dd/mm/yyyy" overall the application, but momentally I have "mm/dd/yyyy".

Here's the code in models.py

period_from = models.DateField(db_column="Period From", blank=True, null=True)

How to define it for all the datefields and in which file?

over 4 years ago · Santiago Trujillo
1 answers
Answer question

0

You can use the DATE_FORMAT [Django-doc] and SHORT_DATE_FORMAT settings [Django-doc] to specify how Django will format date objects.

Note that if you enable USE_L10N [Django-doc], then these settings will not have effect, and Django will format the date according to the locale of the user.

over 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!