OEModule\PASAPI\resources\Patient::deleteAddresses PHP Метод

deleteAddresses() приватный Метод

private deleteAddresses ( Contact $contact, $except_ids = [] )
$contact Contact
    private function deleteAddresses(\Contact $contact, $except_ids = array())
    {
        // delete any address that are no longer relevant
        $matched_string = implode(',', $except_ids);
        $condition_str = 'contact_id = :contact_id';
        if ($matched_string) {
            $condition_str .= " AND id NOT IN({$matched_string})";
        }
        \Address::model()->deleteAll(array('condition' => $condition_str, 'params' => array(':contact_id' => $contact->id)));
    }