Skip to content

Commit

Permalink
Fix regression (bad name of function)
Browse files Browse the repository at this point in the history
  • Loading branch information
eldy committed Dec 14, 2018
1 parent 4b90f88 commit baf9b6f
Show file tree
Hide file tree
Showing 11 changed files with 29 additions and 29 deletions.
6 changes: 3 additions & 3 deletions htdocs/comm/propal/list.php
Expand Up @@ -330,15 +330,15 @@
$sql.= ' AND p.fk_statut IN ('.$db->escape($viewstatut).')';
}

$sql.= dol_sql_datefilter(
$sql.= dolSqlDateFilter(
"p.datep",
$search_day, $search_month, $search_year
);
$sql.= dol_sql_datefilter(
$sql.= dolSqlDateFilter(
"p.fin_validite",
$search_dayfin, $search_month_end, $search_yearfin
);
$sql.= dol_sql_datefilter(
$sql.= dolSqlDateFilter(
"p.date_livraison",
$search_daydelivery, $search_monthdelivery, $search_yeardelivery
);
Expand Down
4 changes: 2 additions & 2 deletions htdocs/commande/list.php
Expand Up @@ -304,12 +304,12 @@
}
}

$sql.= dol_sql_datefilter(
$sql.= dolSqlDateFilter(
"c.date_commande",
$search_orderday, $search_ordermonth, $search_orderyear
);

$sql.= dol_sql_datefilter(
$sql.= dolSqlDateFilter(
"c.date_livraison",
$search_deliveryday, $search_deliverymonth, $search_deliveryyear
);
Expand Down
2 changes: 1 addition & 1 deletion htdocs/compta/deplacement/list.php
Expand Up @@ -107,7 +107,7 @@
}
// if ($search_amount) $sql.=" AND d.km='".$db->escape(price2num(trim($search_amount)))."'";

$sql.= dol_sql_datefilter(
$sql.= dolSqlDateFilter(
"d.dated", $day, $month, $year
);

Expand Down
4 changes: 2 additions & 2 deletions htdocs/compta/facture/list.php
Expand Up @@ -452,11 +452,11 @@
}
if ($search_paymentmode > 0) $sql .= " AND f.fk_mode_reglement = ".$db->escape($search_paymentmode);

$sql.= dol_sql_datefilter(
$sql.= dolSqlDateFilter(
"f.datef",
$search_day, $search_month, $search_year
);
$sql.= dol_sql_datefilter(
$sql.= dolSqlDateFilter(
"f.date_lim_reglement",
$search_day_lim, $search_month_lim, $search_year_lim
);
Expand Down
2 changes: 1 addition & 1 deletion htdocs/compta/paiement/list.php
Expand Up @@ -164,7 +164,7 @@
else $sql.= " AND f.fk_user_author = ".$userid;
}
// Search criteria
$sql.= dol_sql_datefilter("p.datep", $day, $month, $year);
$sql.= dolSqlDateFilter("p.datep", $day, $month, $year);

if ($search_ref) $sql .= natural_search('p.ref', $search_ref);
if ($search_account > 0) $sql .=" AND b.fk_account=".$search_account;
Expand Down
18 changes: 9 additions & 9 deletions htdocs/core/lib/date.lib.php
Expand Up @@ -151,7 +151,7 @@ function dol_time_plus_duree($time, $duration_value, $duration_unit)
* @return int Time into seconds
* @see convertSecondToTime
*/
function convertTime2Seconds($iHours=0,$iMinutes=0,$iSeconds=0)
function convertTime2Seconds($iHours=0, $iMinutes=0, $iSeconds=0)
{
$iResult=($iHours*3600)+($iMinutes*60)+$iSeconds;
return $iResult;
Expand Down Expand Up @@ -276,16 +276,16 @@ function convertSecondToTime($iSecond, $format='all', $lengthOfDay=86400, $lengt


/**
* générate standard filter date
* Generate a SQL string to make a filter into a range (for second of date until last second of date)
*
* @param string $datefield fields where apply sql date filter
* @param int $day_date day date
* @param int $month_date month date
* @param int $year_date year date
* @return string $sqldate sql part of date
* @param string $datefield Name of SQL field where apply sql date filter
* @param int $day_date Day date
* @param int $month_date Month date
* @param int $year_date Year date
* @return string $sqldate String with SQL filter
*/

function dolSqlDatefilter($datefield, $day_date, $month_date, $year_date) {
function dolSqlDateFilter($datefield, $day_date, $month_date, $year_date)
{
global $db;
$sqldate="";
if ($month_date > 0) {
Expand Down
4 changes: 2 additions & 2 deletions htdocs/expensereport/list.php
Expand Up @@ -276,13 +276,13 @@
// Ref
if (!empty($search_ref)) $sql.= natural_search('d.ref', $search_ref);
// Date Start
$sql.= dol_sql_datefilter(
$sql.= dolSqlDateFilter(
"d.date_debut",
$day_start, $month_start, $year_start
);

// Date End
$sql.= dol_sql_datefilter(
$sql.= dolSqlDateFilter(
"d.date_fin",
$day_end, $month_end, $year_end
);
Expand Down
4 changes: 2 additions & 2 deletions htdocs/fourn/commande/list.php
Expand Up @@ -528,11 +528,11 @@
if ($search_status != '' && $search_status >= 0)
$sql.=" AND cf.fk_statut IN (".$db->escape($search_status).")";

$sql.= dol_sql_datefilter(
$sql.= dolSqlDateFilter(
"cf.date_commande",
$search_orderday, $search_ordermonth, $search_orderyear
);
$sql.= dol_sql_datefilter(
$sql.= dolSqlDateFilter(
"cf.date_livraison",
$search_deliveryday, $search_deliverymonth, $search_deliveryyear
);
Expand Down
4 changes: 2 additions & 2 deletions htdocs/fourn/facture/list.php
Expand Up @@ -331,8 +331,8 @@
if ($search_status != '' && $search_status >= 0) $sql.= " AND f.fk_statut = ".$db->escape($search_status);
if ($search_paymentmode > 0) $sql .= " AND f.fk_mode_reglement = ".$search_paymentmode."";

$sql.= dol_sql_datefilter( "f.datef", $day, $month, $year);
$sql.= dol_sql_datefilter( "f.date_lim_reglement", $day_lim, $month_lim, $year_lim);
$sql.= dolSqlDateFilter( "f.datef", $day, $month, $year);
$sql.= dolSqlDateFilter( "f.date_lim_reglement", $day_lim, $month_lim, $year_lim);

if ($option == 'late') $sql.=" AND f.date_lim_reglement < '".$db->idate(dol_now() - $conf->facture->fournisseur->warning_delay)."'";
if ($search_label) $sql .= natural_search('f.libelle', $search_label);
Expand Down
6 changes: 3 additions & 3 deletions htdocs/holiday/list.php
Expand Up @@ -191,19 +191,19 @@
}

// Start date
$sql.= dol_sql_datefilter(
$sql.= dolSqlDateFilter(
"cp.date_debut",
$search_day_start, $search_month_start, $search_year_start
);

// End date
$sql.= dol_sql_datefilter(
$sql.= dolSqlDateFilter(
"cp.date_fin",
$search_day_end, $search_month_end, $search_year_end
);

// Create date
$sql.= dol_sql_datefilter(
$sql.= dolSqlDateFilter(
"cp.date_create",
$search_day_create, $search_month_create, $search_year_create
);
Expand Down
4 changes: 2 additions & 2 deletions htdocs/supplier_proposal/list.php
Expand Up @@ -290,8 +290,8 @@
if ($socid) $sql.= ' AND s.rowid = '.$socid;
if ($search_status >= 0 && $search_status != '') $sql.= ' AND sp.fk_statut IN ('.$db->escape($search_status).')';

$sql.= dol_sql_datefilter("sp.date_livraison", $day, $month, $year);
$sql.= dol_sql_datefilter("sp.date_valid", $dayvalid, $monthvalid, $yearvalid);
$sql.= dolSqlDateFilter("sp.date_livraison", $day, $month, $year);
$sql.= dolSqlDateFilter("sp.date_valid", $dayvalid, $monthvalid, $yearvalid);

if ($search_sale > 0) $sql.= " AND s.rowid = sc.fk_soc AND sc.fk_user = " .$search_sale;
if ($search_user > 0)
Expand Down

0 comments on commit baf9b6f

Please sign in to comment.