Completed Bug ... > Bug (closed)

Home > List changes preset do not work / #4041

Summary

v0.08
closed
Feb 14, 2007
100%
May 29, 2007
Feb 15, 2007 / pixtur
May 30, 2007 / pixtur
 

Attached files

No files uploaded

Issue report

Minor
Have not tried
PHP 5.2.X
Streber 0.0794
2007-01-14 16:41
  1. got to home / Changes
  2. Try preset "Today"

Too many results shown.

Use ListFilter_not_older() instead of custom filters. Value should be set in seconds from now into the past.


change

from home.inc.php line 489

				case 'today':
					$list->filters[]= new ListFilter_today(array(
						'value'=>$f_settings['value'],
					));
					break;
into
				case 'today':
					$list->filters[]= new ListFilter_not_older(array(
						'value'=> 24*60*60
					));
					break;

Something like this. Probably we could remove the current time of day from the value...

 

4 Comments

burger

Feb 16, 2007
View comment
You can use this, too.
case 'today':
					$list->filters[]= new ListFilter_min_week(array(
						'value'=>$f_settings['value'], 'factor'=>0
					));
					$list->filters[]= new ListFilter_max_week(array(
						'value'=>$f_settings['value'],
					));


					break;
The problem is that I used a new function getChanges at db_item.inc.php. There was a variable called 'today'. Now there is no variable 'today' anymore. Therefore it cannot work.

pixtur

Feb 16, 2007
version 3
On "today".
But isnt' "today" a little bit ambiguous as name? Without explanation it could mean anything. A flag, a function a value. Why introduce a new function if it only changes the range?

If we filter for dates, it see to potential ways: date_min / date_max or age.
 
Or did I got you wrong?

burger

Feb 16, 2007
Okay ...
Your right I didn't thought about this option to use date_min/date_max or age before. So let's take it :-).

pixtur

Feb 17, 2007
Who will do it?
Do you want to give it a try? I could understand if you are hestitating now :)



 

Comment / Update