Modify

Opened 14 years ago

Closed 13 years ago

Last modified 13 years ago

#7793 closed defect (fixed)

[Patch] Custom fields with date=false still behave as if it were set to true

Reported by: C. G. Brown Owned by: Robert Corsaro
Priority: low Component: DateFieldPlugin
Severity: minor Keywords:
Cc: Trac Release: 0.11

Description (last modified by Ryan J Ollos)

The following custom field entry will still display a date in Trac 0.11.7:

[ticket-custom]
test1=text
test1.date=false
test1.date_empty=false
test1.label=Testing
test1.value=

The workaround is to remove the date entry altogether but if someone were just doing a quick change of a field this could become an issue. For us it's a an issue, albeit a minor one, because we have our own custom field manager and it's easier to pass false than to hide the value.

I'll see if I can produce a patch.

Attachments (1)

date_true_false.patch (893 bytes) - added by C. G. Brown 14 years ago.
Patch to fix text being treated as date unless field.date=true

Download all attachments as: .zip

Change History (5)

Changed 14 years ago by C. G. Brown

Attachment: date_true_false.patch added

Patch to fix text being treated as date unless field.date=true

comment:1 Changed 13 years ago by Ryan J Ollos

Description: modified (diff)
Summary: Custom Field date=false still behaves as if it were set to true[Patch] Custom fields with date=false still behave as if it were set to true

I can confirm this behavior and that the patch resolves the issue. Doki, can I go ahead and commit the patch?

comment:2 Changed 13 years ago by Ryan J Ollos

I'm going to go ahead and apply the patch and assume that Doki will be okay with it, based on previous discussion. Otherwise I'll probably never get back to doing it.

comment:3 Changed 13 years ago by Ryan J Ollos

Resolution: fixed
Status: newclosed

(In [10398]) Fixes #7793: When field.date = false, the field was still being treated as a datefield. Thanks to cgbrown for the patch.

comment:4 Changed 13 years ago by Ryan J Ollos

The egg file I accidentally added in [10398] was removed in [10399].

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Robert Corsaro.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.