mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 03:18:26 +00:00
Removing method no longer in use.
git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@7811 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
parent
89bf77ae01
commit
989f9f0cbc
1 changed files with 0 additions and 52 deletions
|
@ -2466,58 +2466,6 @@ class Model extends Overloadable {
|
|||
|
||||
return false;
|
||||
}
|
||||
/**
|
||||
* Top secret
|
||||
*
|
||||
* @return array
|
||||
* @access public
|
||||
*/
|
||||
function normalizeFindParams($type, $data, $altType = null, $r = array(), $_this = null) {
|
||||
if ($_this == null) {
|
||||
$_this = $this;
|
||||
$root = true;
|
||||
}
|
||||
|
||||
foreach ((array)$data as $name => $children) {
|
||||
if (is_numeric($name)) {
|
||||
$name = $children;
|
||||
$children = array();
|
||||
}
|
||||
|
||||
if (strpos($name, '.') !== false) {
|
||||
$chain = explode('.', $name);
|
||||
$name = array_shift($chain);
|
||||
$children = array(join('.', $chain) => $children);
|
||||
}
|
||||
|
||||
if (!empty($children)) {
|
||||
if ($_this->name == $name) {
|
||||
$r = array_merge($r, $this->normalizeFindParams($type, $children, $altType, $r, $_this));
|
||||
} else {
|
||||
if (!$_this->getAssociated($name)) {
|
||||
$r[$altType][$name] = $children;
|
||||
} else {
|
||||
$r[$name] = $this->normalizeFindParams($type, $children, $altType, @$r[$name], $_this->{$name});;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if ($_this->getAssociated($name)) {
|
||||
$r[$name] = array($type => null);
|
||||
} else {
|
||||
if ($altType != null) {
|
||||
$r[$type][] = $name;
|
||||
} else {
|
||||
$r[$type] = $name;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (isset($root)) {
|
||||
return array($this->name => $r);
|
||||
}
|
||||
return $r;
|
||||
}
|
||||
/**
|
||||
* Returns the ID of the last record this model inserted.
|
||||
*
|
||||
|
|
Loading…
Reference in a new issue