Beispiel #1
0
 private function _check_duplicates($name)
 {
     if ($name == '') {
         return false;
     }
     // Check for duplicates
     $qb = org_openpsa_calendar_resource_dba::new_query_builder();
     $qb->add_constraint('name', '=', $name);
     if ($this->id) {
         $qb->add_constraint('id', '<>', $this->id);
     }
     $result = $qb->execute();
     if (count($result) > 0) {
         return true;
     }
     return false;
 }