From 03dbe16b7762cc1a9e57df4e9e34bc04f46bb57f Mon Sep 17 00:00:00 2001
From: wei <>
Date: Tue, 3 Apr 2007 01:38:15 +0000
Subject: update js onclick handler context for controls with js counterpart.

---
 framework/Data/SqlMap/Statements/TCachingStatement.php | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

(limited to 'framework/Data/SqlMap')

diff --git a/framework/Data/SqlMap/Statements/TCachingStatement.php b/framework/Data/SqlMap/Statements/TCachingStatement.php
index 7d0c0824..051a8ec3 100644
--- a/framework/Data/SqlMap/Statements/TCachingStatement.php
+++ b/framework/Data/SqlMap/Statements/TCachingStatement.php
@@ -45,7 +45,7 @@ class TCachingStatement implements IMappedStatement
 	public function executeQueryForMap($connection, $parameter,$keyProperty, $valueProperty=null, $delegate=null)
 	{
 		$sql = $this->createCommand($connection, $parameter);
-		$key = $this->getCacheKey(array($sql, $keyProperty, $valueProperty));
+		$key = $this->getCacheKey(array(clone($sql), $keyProperty, $valueProperty));
 		$map = $this->getStatement()->getCache()->get($key);
 		if(is_null($map))
 		{
@@ -69,7 +69,7 @@ class TCachingStatement implements IMappedStatement
 	public function executeQueryForList($connection, $parameter, $result=null, $skip=-1, $max=-1, $delegate=null)
 	{
 		$sql = $this->createCommand($connection, $parameter);
-		$key = $this->getCacheKey(array($sql, $skip, $max));
+		$key = $this->getCacheKey(array(clone($sql), $parameter, $skip, $max));
 		$list = $this->getStatement()->getCache()->get($key);
 		if(is_null($list))
 		{
@@ -83,7 +83,7 @@ class TCachingStatement implements IMappedStatement
 	public function executeQueryForObject($connection, $parameter, $result=null)
 	{
 		$sql = $this->createCommand($connection, $parameter);
-		$key = $this->getCacheKey($sql);
+		$key = $this->getCacheKey(array(clone($sql), $parameter));
 		$object = $this->getStatement()->getCache()->get($key);
 		if(is_null($object))
 		{
-- 
cgit v1.2.3