diff options
| author | michael pereira | 2011-03-22 12:29:36 +0100 |
|---|---|---|
| committer | michael pereira | 2011-03-22 12:29:36 +0100 |
| commit | 01da64858b8624588d5da7bd44763e55b41eefdf (patch) | |
| tree | 911c775c13c4a377d5e37e792f46108be4939f39 /application/models | |
| parent | fallback lösungen für fbgui hinzugefügt (diff) | |
| download | pbs2-01da64858b8624588d5da7bd44763e55b41eefdf.tar.gz pbs2-01da64858b8624588d5da7bd44763e55b41eefdf.tar.xz pbs2-01da64858b8624588d5da7bd44763e55b41eefdf.zip | |
Bootos fix
Diffstat (limited to 'application/models')
| -rw-r--r-- | application/models/BootOsMapper.php | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/application/models/BootOsMapper.php b/application/models/BootOsMapper.php index fab73f2..1856384 100644 --- a/application/models/BootOsMapper.php +++ b/application/models/BootOsMapper.php @@ -66,7 +66,7 @@ class Application_Model_BootOsMapper } } - public function find($id) + public function find($id, Application_Model_BootOs $botos = null) { $botos = new Application_Model_BootOs(); $result = $this->getDbTable()->find($id); @@ -76,8 +76,14 @@ class Application_Model_BootOsMapper $row = $result->current(); - $botos->setID($row->bootosID)->setConfigID($row->configID)->setGroupID($row->groupID)->setMembershipID($row->membershipID)->setTitle($row->title)->setPath_init($row->path_init)->setPath_kernel($row->path_kernel)->setDefaultkcl($row->defaultkcl)->setCreated($row->created)->setDescription($row->description)->setExpires($row->expires)->setPublic($row->public); - return $botos; + if($botos == null){ + $botos = new Application_Model_BootOs(); + $botos->setID($row->bootosID)->setConfigID($row->configID)->setGroupID($row->groupID)->setMembershipID($row->membershipID)->setTitle($row->title)->setPath_init($row->path_init)->setPath_kernel($row->path_kernel)->setDefaultkcl($row->defaultkcl)->setCreated($row->created)->setDescription($row->description)->setExpires($row->expires)->setPublic($row->public); + return $botos; + }else{ + $botos->setID($row->bootosID)->setConfigID($row->configID)->setGroupID($row->groupID)->setMembershipID($row->membershipID)->setTitle($row->title)->setPath_init($row->path_init)->setPath_kernel($row->path_kernel)->setDefaultkcl($row->defaultkcl)->setCreated($row->created)->setDescription($row->description)->setExpires($row->expires)->setPublic($row->public); + } + } public function fetchAll() |
