Anteriormente para leer datos de los modelos de las bases de datos utilizaba la siguiente sentencia:
- $this->Modelo->id = 2;
$modelo = $this->Modelo->read();
$this->set(‘modelo’, $modelo);
Esa sentencia fue remplazada por la simple, facil y limpia:
- $this->set(‘modelo’, $this->Modelo->findById(2));
Saludos
No hay Trackbacks
7 Comentarios
Ey también puedes ocupar:
$this->set(“modelo”, $this->Modelo->read(null, $id));
Saludos
EN UN FORO UN PERUANO ESTA HACIENDO BURLA DE TU FOTO
http://es.5wk.com/viewtopic.php?f=4&t=126717
http://es.5wk.com/viewtopic.php?f=4&t=126730
$modelo = $modeloManager->encontrar($id);
//Y con Inyección
$modeloManager = new ModeloManager(new ModeloDao());
$modelo = $modeloManager->encontrar($id);
//ModeloDao representa tu capa de persistencia, puedes cambiar el ORM y luego sólo cambias los cuerpos de los DAO, y por otro lado el Manager es una clase de estereotipo de control encargada de la capa de negocio – normalmente encontrar,encontrarTodos, borrar, etc.
Hi!
Give me any link for downloading XRumer 5 warez!
Thank you…
Very-very much.
I’m so need this program for promote my online projects! This software is the best thing for online promo and mass posting, you know…
And, dont send me XRumer 2.9 and XRumer 3.0 – that versions are too old!
P.S. Google cant help me((((
Does anyone knows what should we expect in 2010? they promise more problems on wall stree? I are heading toward dipression?
I noticed that this is not the first time at all that you write about the topic. Why have you chosen it again?
????? ?? ???? ???????