Skip to content
Snippets Groups Projects
Commit 1f013bb3 authored by Laurent Destailleur's avatar Laurent Destailleur
Browse files

Use idate and jdate to store date

parent e2c5fb16
No related branches found
No related tags found
No related merge requests found
...@@ -526,6 +526,17 @@ class DoliDb ...@@ -526,6 +526,17 @@ class DoliDb
return "unix_timestamp(".$param.")"; return "unix_timestamp(".$param.")";
} }
/**
* \brief Convert (by PHP) a GM Timestamp date into a PHP server TZ to insert into a date field.
* Function to use to build INSERT, UPDATE or WHERE predica
* \param param Date TMS to convert
* \return string Date in a string YYYYMMDDHHMMSS
*/
function idate($param)
{
return adodb_strftime("%Y%m%d%H%M%S",$param);
}
/** /**
* \brief Convert (by PHP) a PHP server TZ string date into a GM Timestamps date * \brief Convert (by PHP) a PHP server TZ string date into a GM Timestamps date
* \param string Date in a string (YYYYMMDDHHMMSS, YYYYMMDD, YYYY-MM-DD HH:MM:SS) * \param string Date in a string (YYYYMMDDHHMMSS, YYYYMMDD, YYYY-MM-DD HH:MM:SS)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment