WIP sofar
This commit is contained in:
@@ -17,9 +17,13 @@ class ORM extends Kohana_ORM {
|
||||
public function find($id = NULL) {
|
||||
// Since TSM doesnt support LIMIT, we'll use find_all() but return the first record
|
||||
foreach ($this->find_all() as $object) {
|
||||
$this->_load_values($object->_object);
|
||||
// In TSM Primary Keys are in upper case
|
||||
if (is_null($id) OR $object->{$object->_primary_key} == strtoupper($id))
|
||||
$this->_load_values($object->_object);
|
||||
|
||||
return;
|
||||
// If we have found our item return
|
||||
if ($this->_loaded)
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user