method getLastDate documentation in bbn\Appui\History
function(string $table, string $id, $column = NULL)
{
if ( $db = self::_get_db() ){
if (
$column &&
($id_col = self::getIdColumn($column, $table))
){
return self::$db->selectOne(self::$table, 'tst', [
'uid' => $id,
'col' => $id_col
], [
'tst' => 'DESC'
]);
}
else if ( !$column && ($where = self::_get_table_where($table)) ){
$tab = $db->escape(self::$table);
$chrono = $db->escape('tst');
$line = $db->escape('uid');
$sql = <<< MYSQL
SELECT $chrono
FROM $tab
WHERE $line = ?
AND ($where)
ORDER BY $chrono DESC
MYSQL;
return $db->getOne($sql, hex2bin($id));
}
}
return null;
}
BBN is a suite of PHP and JS libraries and VueJS components - all open-source! bbn.io, build applications, the quick way
This website uses cookies to ensure you get the best experience on our website.
© 2011-2024
BBN Solutions