Development of an internal social media platform with personalised dashboards for students
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

formats.py 1.7KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. # This file is distributed under the same license as the Django package.
  2. #
  3. # The *_FORMAT strings use the Django date format syntax,
  4. # see http://docs.djangoproject.com/en/dev/ref/templates/builtins/#date
  5. DATE_FORMAT = 'Y年n月j日' # 2016年9月5日
  6. TIME_FORMAT = 'H:i' # 20:45
  7. DATETIME_FORMAT = 'Y年n月j日 H:i' # 2016年9月5日 20:45
  8. YEAR_MONTH_FORMAT = 'Y年n月' # 2016年9月
  9. MONTH_DAY_FORMAT = 'm月j日' # 9月5日
  10. SHORT_DATE_FORMAT = 'Y年n月j日' # 2016年9月5日
  11. SHORT_DATETIME_FORMAT = 'Y年n月j日 H:i' # 2016年9月5日 20:45
  12. FIRST_DAY_OF_WEEK = 1 # 星期一 (Monday)
  13. # The *_INPUT_FORMATS strings use the Python strftime format syntax,
  14. # see http://docs.python.org/library/datetime.html#strftime-strptime-behavior
  15. DATE_INPUT_FORMATS = [
  16. '%Y/%m/%d', # '2016/09/05'
  17. '%Y-%m-%d', # '2016-09-05'
  18. '%Y年%n月%j日', # '2016年9月5日'
  19. ]
  20. TIME_INPUT_FORMATS = [
  21. '%H:%M', # '20:45'
  22. '%H:%M:%S', # '20:45:29'
  23. '%H:%M:%S.%f', # '20:45:29.000200'
  24. ]
  25. DATETIME_INPUT_FORMATS = [
  26. '%Y/%m/%d %H:%M', # '2016/09/05 20:45'
  27. '%Y-%m-%d %H:%M', # '2016-09-05 20:45'
  28. '%Y年%n月%j日 %H:%M', # '2016年9月5日 14:45'
  29. '%Y/%m/%d %H:%M:%S', # '2016/09/05 20:45:29'
  30. '%Y-%m-%d %H:%M:%S', # '2016-09-05 20:45:29'
  31. '%Y年%n月%j日 %H:%M:%S', # '2016年9月5日 20:45:29'
  32. '%Y/%m/%d %H:%M:%S.%f', # '2016/09/05 20:45:29.000200'
  33. '%Y-%m-%d %H:%M:%S.%f', # '2016-09-05 20:45:29.000200'
  34. '%Y年%n月%j日 %H:%n:%S.%f', # '2016年9月5日 20:45:29.000200'
  35. ]
  36. DECIMAL_SEPARATOR = '.'
  37. THOUSAND_SEPARATOR = ''
  38. NUMBER_GROUPING = 4