Edgewall Software

Ticket #7444 (closed enhancement: fixed)

Opened 5 months ago

Last modified 5 months ago

[PATCH] Searching in milestones

Reported by: Remy Blank <remy.blank@…> Owned by: remy.blank@…
Priority: normal Milestone: 0.11.1
Component: roadmap Version:
Severity: normal Keywords: milestone patch
Cc:

Description

The search function currently doesn't search in milestones. The attached patch adds an ISearchSource to MilestoneModule and allows searching in the milestone name and description.

The patch depends on #2561 for searching in milestone attachment metadata as well. Should the former not be accepted, the last section starting with the # Attachments comment can simply be dropped.

Attachments

milestone-search.patch (2.3 KB) - added by Remy Blank <remy.blank@…> 5 months ago.
Patch against 0.11-stable [7346] adding searching in milestones
search-no-author.patch (0.6 KB) - added by Remy Blank <remy.blank@…> 5 months ago.
Do not show author in search results if it is empty

Change History

Changed 5 months ago by Remy Blank <remy.blank@…>

Patch against 0.11-stable [7346] adding searching in milestones

  Changed 5 months ago by Remy Blank <remy.blank@…>

A few comments:

  • The author field of milestone search results is set to the empty string. This is consistent with the data returned for timeline events. However, for milestone events in the timeline, the author is not displayed at all, whereas in search results, the author appears as anonymous. Maybe this should be fixed in the search template in the same way as in the timeline.
  • The time field of milestone search results is set to the completed date if it is set, otherwise to the due date if it is set, otherwise to "now". I'm not quite sure about this last case, but setting it to 0 makes all milestones with no due or completed date come last, as the search result list is sorted in descending time order. And setting it to an arbitrary date in the future (e.g. in 1 month) doesn't sound convincing either.

Changed 5 months ago by Remy Blank <remy.blank@…>

Do not show author in search results if it is empty

  Changed 5 months ago by cboos

<py:if test="result.author"><span class="author">...

can also be written:

<span py:if="result.author" class="author">...

follow-up: ↓ 4   Changed 5 months ago by Remy Blank <remy.blank@…>

Not if you include the &mdash; at the end of the line ;-)

But apart from that, does it make sense to remove the author when it is empty, or does some other functionality rely on it being there?

in reply to: ↑ 3   Changed 5 months ago by cboos

Replying to Remy Blank <remy.blank@pobox.com>:

Not if you include the &mdash; at the end of the line ;-)

Morning reviewing not a good thing ;-)

But apart from that, does it make sense to remove the author when it is empty, or does some other functionality rely on it being there?

I think it's OK to remove it.

  Changed 5 months ago by cboos

  • owner set to remy.blank@…
  • milestone set to 0.11.1

0.11.1, as any other minor release, is "Bug fixes and minor improvements to 0.11.", so I think this feature (as well as #2561) is fine for being included there.

  Changed 5 months ago by cboos

  • status changed from new to closed
  • resolution set to fixed

Both patches applied, in [7351] and [7352].

Add/Change #7444 ([PATCH] Searching in milestones)

Author



Change Properties
<Author field>
Action
as closed
Next status will be 'reopened'
to The owner will change from remy.blank@pobox.com. Next status will be 'closed'
 
Note: See TracTickets for help on using tickets.