Proyectos de Subversion LeadersLinked - Services

Rev

Rev 283 | Rev 603 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 283 Rev 558
Línea 284... Línea 284...
284
    public function insert($capsule)
284
    public function insert($capsule)
285
    {
285
    {
286
        $hydrator = new ObjectPropertyHydrator();
286
        $hydrator = new ObjectPropertyHydrator();
287
        $values = $hydrator->extract($capsule);
287
        $values = $hydrator->extract($capsule);
288
        $values = $this->removeEmpty($values);
288
        $values = $this->removeEmpty($values);
289
        $values['cost'] = isset($values['cost']) ? $values['cost'] : 0;
-
 
Línea 290... Línea 289...
290
        
289
        
291
        
290
        
Línea 307... Línea 306...
307
    public function update($capsule)
306
    public function update($capsule)
308
    {
307
    {
309
        $hydrator = new ObjectPropertyHydrator();
308
        $hydrator = new ObjectPropertyHydrator();
310
        $values = $hydrator->extract($capsule);
309
        $values = $hydrator->extract($capsule);
311
        $values = $this->removeEmpty($values);
310
        $values = $this->removeEmpty($values);
312
        $values['cost'] = isset($values['cost']) ? $values['cost'] : 0;
-
 
Línea 313... Línea 311...
313
        
311
        
314
        $update = $this->sql->update(self::_TABLE);
312
        $update = $this->sql->update(self::_TABLE);
315
        $update->set($values);
313
        $update->set($values);