diff --git a/Westdc/Db/Dbh.php b/Westdc/Db/Dbh.php index 81064ff..cda4914 100644 --- a/Westdc/Db/Dbh.php +++ b/Westdc/Db/Dbh.php @@ -54,6 +54,7 @@ class Dbh } }else{ $sql = "INSERT INTO \"".$table."\" ($fields) VALUES ($datas) RETURNING id"; + //exit($sql); try{ $sth = $this->db->prepare($sql); if($sth->execute()) diff --git a/Westdc/File/Listener/DefaultFileUploadListener.php b/Westdc/File/Listener/DefaultFileUploadListener.php index 4d172bc..2cb4cbb 100644 --- a/Westdc/File/Listener/DefaultFileUploadListener.php +++ b/Westdc/File/Listener/DefaultFileUploadListener.php @@ -14,7 +14,7 @@ class DefaultFileUploadListener implements ListenerAggregateInterface function __construct() { - $this->serviceManager = new ServiceManager(); + $this->serviceManager = ServiceManager::getInstance(); $this->serviceManager = $this->serviceManager->getServiceManager(); } diff --git a/Westdc/Mail/Mail.php b/Westdc/Mail/Mail.php index 6a7b120..b6dd81b 100644 --- a/Westdc/Mail/Mail.php +++ b/Westdc/Mail/Mail.php @@ -43,7 +43,7 @@ class Mail extends AbstractEventManager implements ServiceManagerAwareInterface{ { if(!$this->serviceManager instanceof ServiceManager) { - $serviceManager = new WestdcServiceManager(); + $serviceManager = WestdcServiceManager::getInstance(); $this->serviceManager = $serviceManager->getServiceManager(); } diff --git a/Westdc/Mail/Sender.php b/Westdc/Mail/Sender.php index 51dbc9b..1205c22 100644 --- a/Westdc/Mail/Sender.php +++ b/Westdc/Mail/Sender.php @@ -29,7 +29,7 @@ class Sender implements ServiceManagerAwareInterface{ { if(!$this->serviceManager instanceof ServiceManager) { - $serviceManager = new WestdcServiceManager(); + $serviceManager = WestdcServiceManager::getInstance(); $this->serviceManager = $serviceManager->getServiceManager(); } } diff --git a/Westdc/Service/ServiceManager.php b/Westdc/Service/ServiceManager.php index e323740..d73764d 100644 --- a/Westdc/Service/ServiceManager.php +++ b/Westdc/Service/ServiceManager.php @@ -1,20 +1,25 @@ serviceManager = new Zend_ServiceManager; $this->serviceManager->addAbstractFactory(new ServiceFactory);