implemented editing of patients