View Issue Details

IDProjectCategoryView StatusLast Update
0033992mantisbtrsspublic2026-08-22 13:13
Reporterdomosekai Assigned Todregad  
PrioritynormalSeverityminorReproducibilityalways
Status resolvedResolutionfixed 
Product Version2.26.1 
Target Version2.29.0Fixed in Version2.29.0 
Summary0033992: RSS should have been sorted by date_submitted but failed due to invisibility
Description

Currently if a column is not visible, it's not sortable. See notes at build_order_by().

While in View Issues it's not a problem because it makes no sense to sort by an invisible column, in RSS the default column to sort by is date_submitted which is not visible by default. The RSS feed is always sorted in the default order (i.e. last updated).

/* issues_rss.php */
if( $f_sort === 'update' ) {
    $c_sort_field = 'last_updated';
} else {
    $c_sort_field = 'date_submitted';  // no effect due to invisibility
}

A temporary fix is to use id instead of date_submitted. But the real question is should it be allowed to sort by an invisible column?

TagsNo tags attached.

Activities

dregad

dregad

2024-03-12 04:14

developer   ~0068647

Thanks for the bug report. I can confirm the behavior as described.

It would appear that when the filter API was refactored several years ago, it did not consider that filters were also used in non-UI contexts such as RSS. Or more accurately, the question was asked, but not answered [1].

dregad

dregad

2026-07-18 07:12

developer   ~0071301

https://github.com/mantisbt/mantisbt/pull/2246

dregad

dregad

2026-07-18 07:12

developer   ~0071302

PR https://github.com/mantisbt/mantisbt/pull/2246

Related Changesets

MantisBT: master 60c5f7bf

2026-07-18 06:54

dregad


Details Diff
Allow filters to sort on invisible columns

New filter_get_sort_properties_array() API function adds a new
$p_visible_only parameter to determine if sorting should be restricted
to visible columns (default) or allowed on all columns.

Existing filter_get_visible_sort_properties_array() becomes a proxy for
the new function.

Add $visible_only property to BugFilterQuery class, initialized in
Constructor via $p_config parameter, defaulting to true. It is used in
the build_order_by() method in the filter_get_sort_properties_array()
call.

filter_get_bug_rows() gets a new $p_visible_only parameter, passed on
to BugFilterQuery's constructor.

Fixes 0033992
Affected Issues
0033992
mod - core/classes/BugFilterQuery.class.php Diff File
mod - core/filter_api.php Diff File

MantisBT: master ccd20274

2026-07-18 07:06

dregad


Details Diff
Fix sorting by submitted date on Issues RSS feed

Fixes 0033992
Affected Issues
0033992
mod - issues_rss.php Diff File