Edgewall Software

Opened 19 years ago

Last modified 19 years ago

#1743 closed defect

text of notify mail is broken — at Version 2

Reported by: Shun-ichi Goto <gotoh@…> Owned by: Christopher Lenz
Priority: normal Milestone: 0.9
Component: ticket system Version: devel
Severity: normal Keywords:
Cc: Branch:
Release Notes:
API Changes:
Internal Changes:

Description (last modified by Christopher Lenz)

I think HEAD rev of format_props() makes incorrect formatting text caused by changeset:1832. The column size values are exchanged for left and right side on use. I don't know why these changes are required. I made patch to correct.

  • Notify.py

     
    233233                width[idx] = len(f)
    234234            if len(fval) > width[idx + 1]:
    235235                width[idx + 1] = len(fval)
    236         format = ('%%%is:  %%-%is  |  ' % (width[2], width[3]),
    237                   ' %%%is:  %%-%is%s' % (width[0], width[1], CRLF))
     236        format = ('%%%is:  %%-%is  |  ' % (width[0], width[1]),
     237                  ' %%%is:  %%-%is%s' % (width[2], width[3], CRLF))
    238238        i = 1
    239         l = (width[2] + width[3] + 5)
     239        l = (width[0] + width[1] + 5)
    240240        sep = l*'-' + '+' + (self.COLS-l)*'-'
    241241        txt = sep + CRLF
    242242        big = []
     
    247247                big.append((f.capitalize(), fval))
    248248            else:
    249249                txt += format[i % 2] % (f.capitalize(), fval)
    250         if i % 2:
     250        if (i % 2) == 0:
    251251            txt += '\n'
    252252        if big:
    253253            txt += sep

Change History (2)

comment:1 by linne@…, 19 years ago

Milestone: 0.9

comment:2 by Christopher Lenz, 19 years ago

Component: generalticket system
Description: modified (diff)
Owner: changed from Jonas Borgström to Christopher Lenz
Severity: minornormal
Status: newassigned

(Patch in description marked as diff for better formatting)

Note: See TracTickets for help on using tickets.