Beispiel #1
0
 public function getDefaultInterventionWithScenarioVersion(EiProjet $ei_project, EiVersion $ei_version, Doctrine_Connection $conn = null)
 {
     if ($conn == null) {
         $conn = Doctrine_Manager::connection();
     }
     return $conn->fetchRow("select s.id as subject_id,s.name as subject_name,sp.ei_version_id as sp_ei_version_id, s.package_id,s.package_ref ,t.name as ticket_name  from ei_subject s " . " inner join ei_ticket t on s.package_id=t.ticket_id and s.package_ref=t.ticket_ref " . " Left join ei_scenario_package sp on sp.package_id=t.ticket_id and sp.package_ref=t.ticket_ref and sp.ei_scenario_id=" . $ei_version->getEiScenarioId() . " inner join ei_user_default_package udp on t.ticket_id=udp.ticket_id and t.ticket_ref=udp.ticket_ref " . " where udp.user_id=" . $this->getUserId() . " and udp.user_ref=" . $this->getRefId() . " and s.project_id=" . $ei_project->getProjectId() . " and s.project_ref=" . $ei_project->getRefId());
 }
 public function getDefaultInterventionWithScenarioVersion(EiProjet $ei_project, EiVersion $ei_version, Doctrine_Connection $conn = null)
 {
     if ($conn == null) {
         $conn = Doctrine_Manager::connection();
     }
     return $conn->fetchRow("select sp.*, s.id as subject_id ,s.name as subject_name from ei_scenario_package sp\n                                inner join ei_subject s on sp.package_id= s.package_id and sp.package_ref=s.package_ref\n                                where sp.ei_scenario_id= " . $ei_version->getEiScenarioId() . " and sp.ei_version_id=" . $ei_version->getId() . " and s.project_id=" . $ei_project->getProjectId() . " and s.project_ref=" . $ei_project->getRefId());
 }