mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-19 02:56:15 +00:00
Fixing error introduced in [4311] the DboSource::limit() does not return results as expected.
When column is tinyint(1) is $limit = LIMIT tinyint(1). All others are similar result with $limit = LIMIT [column type][#] git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@4328 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
parent
4d96ad09f1
commit
ea2c7819f3
2 changed files with 4 additions and 4 deletions
|
@ -365,8 +365,8 @@ class DboMysql extends DboSource {
|
|||
}
|
||||
|
||||
$col = r(')', '', $real);
|
||||
$limit = $this->limit($real);
|
||||
@list($col) = explode('(', $col);
|
||||
$limit = null;
|
||||
@list($col, $limit) = explode('(', $col);
|
||||
|
||||
if (in_array($col, array('date', 'time', 'datetime', 'timestamp'))) {
|
||||
return $col;
|
||||
|
|
|
@ -484,7 +484,7 @@ class Model extends Overloadable {
|
|||
* @return void
|
||||
*/
|
||||
function bind($assoc, $params, $permanent = true) {
|
||||
|
||||
|
||||
}
|
||||
/**
|
||||
* Bind model associations on the fly.
|
||||
|
@ -1516,7 +1516,7 @@ class Model extends Overloadable {
|
|||
$value = null;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if (strpos($field, '.') === false) {
|
||||
unset($fields[$field]);
|
||||
$fields[$this->name . '.' . $field] = $value;
|
||||
|
|
Loading…
Add table
Reference in a new issue