Proyectos de Subversion LeadersLinked - Antes de SPA

Rev

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

Rev 1 Rev 2338
Línea 105... Línea 105...
105
        ->unnest();
105
        ->unnest();
Línea 106... Línea 106...
106
        
106
        
107
        return $this->executeFetchAllObject($select, $prototype);
107
        return $this->executeFetchAllObject($select, $prototype);
Línea -... Línea 108...
-
 
108
    }
-
 
109
    
-
 
110
    public function fetchAllByCompanyId($company_id)
-
 
111
    {
-
 
112
        $prototype = new Conversation();
-
 
113
        
-
 
114
        $select = $this->sql->select(self::_TABLE);
-
 
115
        $select->where->and->nest()
-
 
116
        ->nest()
-
 
117
        ->equalTo('sender_company_id', $company_id)
-
 
118
        ->and->equalTo('sender_status', Conversation::STATUS_NORMAL)
-
 
119
        ->unnest()
-
 
120
        ->or->nest()
-
 
121
        ->equalTo('receiver_company_id', $company_id)
-
 
122
        ->and->equalTo('receiver_status', Conversation::STATUS_NORMAL)
-
 
123
        ->unnest()
-
 
124
        ->unnest();
-
 
125
        
Línea 108... Línea 126...
108
    }
126
        return $this->executeFetchAllObject($select, $prototype);
109
    
127
    }
110
    
128