[Vtigercrm-commits] [vtiger development] #5423: birthday filter dows not work properly
vtiger development
vtiger-tickets at trac.vtiger.com
Sat Dec 27 10:05:10 EST 2008
#5423: birthday filter dows not work properly
-----------------------+----------------------------------------------------
Reporter: frankpie | Owner: developer
Type: patch | Status: new
Priority: critical | Milestone: 5.1.0
Component: vtigercrm | Version: 5.1.0-wip
Keywords: |
-----------------------+----------------------------------------------------
the birthday filter at CustomView.php is faulty. Replace (line 962 at rev.
12259)
if($startdate != "" && $enddate != "")
{
$columns = explode(":",$filtercolumn);
$stdfiltersql =
$columns[0].".".$columns[1]." between '".$startdate." 00:00:00' and
'".$enddate." 23:59:00'";
}
by
if($startdate != "" && $enddate != "")
{
$columns = explode(":",$filtercolumn);
if ($columns[1] != 'birthday')
$stdfiltersql =
$columns[0].".".$columns[1]." between '".$startdate." 00:00:00' and
'".$enddate." 23:59:00'";
else
{
$stdfiltersql =
"DATE_FORMAT(".$columns[0].".".$columns[1].", '%m%d') between
DATE_FORMAT('".$startdate."', '%m%d') and DATE_FORMAT('".$enddate."',
'%m%d')";
}
}
The patch removes the year from the filter if you search for a birthday
--
Ticket URL: <http://trac.vtiger.com/cgi-bin/trac.cgi/ticket/5423>
vtiger development <http://trac.vtiger.com/>
vtigerCRM
More information about the vtigercrm-commits
mailing list