diff options
author | Christophe.Boulain <> | 2009-03-16 10:41:42 +0000 |
---|---|---|
committer | Christophe.Boulain <> | 2009-03-16 10:41:42 +0000 |
commit | 306c8f71af808b0002008a5585c2ac9ff69aeb1e (patch) | |
tree | a1e4a083250a15bd2a3073abb3ed2344085fa356 | |
parent | 19652f245a2dde0e8ac7a6be57748384f8edcc51 (diff) |
Fixed Issue#99
-rw-r--r-- | HISTORY | 1 | ||||
-rw-r--r-- | framework/Data/ActiveRecord/TActiveRecordGateway.php | 2 | ||||
-rw-r--r-- | framework/Data/DataGateway/TDataGatewayCommand.php | 2 |
3 files changed, 3 insertions, 2 deletions
@@ -2,6 +2,7 @@ Version 3.1.5 (to be released) BUG: URL wildcard patterns didn't work with subfolders BUG: Issue#87 - TinyMCE : empty string disapears after encoding JS, that's a problem! (Christophe) BUG: Issue#96 - THttpResponse::redirect don't send status code (Christophe) +BUG: Issue#99 - TActiveRecord::save(): confusion with order of keys in table/index (Christophe) BUG: Issue#107 - typo in TDbConnection::getCharset() (Christophe) BUG: Issue#127 - TDataSourceConfig::findConnectionByID try to access private var (Cristophe) BUG: Issue#129 - TDbLogRoute::init don't close the sql command (Christophe) diff --git a/framework/Data/ActiveRecord/TActiveRecordGateway.php b/framework/Data/ActiveRecord/TActiveRecordGateway.php index 6cce9eb9..e588b976 100644 --- a/framework/Data/ActiveRecord/TActiveRecordGateway.php +++ b/framework/Data/ActiveRecord/TActiveRecordGateway.php @@ -349,7 +349,7 @@ class TActiveRecordGateway extends TComponent $tableInfo->getTableFullName(), $name); } if($column->getIsPrimaryKey()) - $primary[] = $value; + $primary[$name] = $value; else $values[$name] = $value; } diff --git a/framework/Data/DataGateway/TDataGatewayCommand.php b/framework/Data/DataGateway/TDataGatewayCommand.php index 35e4dcbe..7425e6c4 100644 --- a/framework/Data/DataGateway/TDataGatewayCommand.php +++ b/framework/Data/DataGateway/TDataGatewayCommand.php @@ -276,7 +276,7 @@ class TDataGatewayCommand extends TComponent {
$column = $this->getTableInfo()->getColumn($key)->getColumnName();
$criteria[] = $column.' = :'.$key;
- $bindings[$key] = $values[$i++];
+ $bindings[$key] = isset($values[$key])?$values[$key]:$values[$i++];
}
return array(implode(' AND ', $criteria), $bindings);
}
|