Opened 7 years ago

Closed 7 years ago

Last modified 7 years ago

#8557 closed (duplicate)

intpoint filter for contrib.humanize

Reported by: drakkan Owned by: nobody
Component: Template system Version: master
Severity: Keywords:
Cc: Triage Stage: Design decision needed
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:


for european users would be really useful an intpoint filter in contrib.humanize,

here is the necessary code (similar to intcomma)

def intpoint(value):

Converts an integer to a string containing point every three digits.
For example, 3000 becomes '3.000' and 45000 becomes '45.000'.
orig = force_unicode(value)
new = re.sub("(-?\d+)(\d{3})", '\g<1>.\g<2>', orig)
if orig == new:

return new


return intpoint(new)

intpoint.is_safe = True

hope this would be in 1.0,


Change History (5)

comment:1 Changed 7 years ago by jacob

  • milestone 1.0 deleted
  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset

We're well past feature freeze for 1.0.

comment:2 Changed 7 years ago by kratorius

  • milestone set to post-1.0

comment:3 Changed 7 years ago by SmileyChris

  • Triage Stage changed from Unreviewed to Design decision needed

comment:4 Changed 7 years ago by SmileyChris

  • Resolution set to duplicate
  • Status changed from new to closed

See #9037 (it has a patch)

comment:5 Changed 7 years ago by anonymous

  • milestone post-1.0 deleted

Milestone post-1.0 deleted

Note: See TracTickets for help on using tickets.
Back to Top