Merging fixes to trunk

Revision: [1817]
Adding fix from Ticket #287
Removing a change to DboSource::generateAssociationQuery()

git-svn-id: https://svn.cakephp.org/repo/trunk/cake@1818 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
phpnut 2006-01-17 05:30:08 +00:00
parent 9ca1ce91d8
commit f718229a04
2 changed files with 4 additions and 4 deletions

View file

@ -6,4 +6,4 @@
// +---------------------------------------------------------------------------------------------------+ // // +---------------------------------------------------------------------------------------------------+ //
/////////////////////////////////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////////////////////////////////
0.10.6.1816 RC 1 0.10.6.1818 RC 1

View file

@ -462,7 +462,7 @@ class DboSource extends DataSource
} }
else else
{ {
if(isset($this->joinFieldJoin) && !isset($queryData['fields'])) if(isset($this->joinFieldJoin))// && !isset($queryData['fields']))
{ {
$joinFields = ', '; $joinFields = ', ';
$joinFields .= join(', ', $this->joinFieldJoin['fields']); $joinFields .= join(', ', $this->joinFieldJoin['fields']);
@ -660,9 +660,9 @@ class DboSource extends DataSource
$updates[] = $this->name($field).'='.$this->value($value); $updates[] = $this->name($field).'='.$this->value($value);
} }
$sql = 'UPDATE '.$this->name($model->table).' AS '.$this->name($model->name); $sql = 'UPDATE '.$this->name($model->table);
$sql .= ' SET '.join(',', $updates); $sql .= ' SET '.join(',', $updates);
$sql .= ' WHERE '.$model->escapeField($model->primaryKey).'='.$this->value($model->getID()); $sql .= ' WHERE '.$this->name($model->primaryKey).'='.$this->value($model->getID());
return $this->execute($sql); return $this->execute($sql);
} }