public function actionDelete()
 {
     $object = CBaseManager::getWorkPlanCompetention(CRequest::getInt("id"));
     $plan = $object->plan_id;
     $object->remove();
     $this->redirect("workplancompetentions.php?action=index&plan_id=" . $plan);
 }
 public function actionDelete()
 {
     $object = CBaseManager::getWorkPlanCompetention(CRequest::getInt("id"));
     $plan = $object->plan_id;
     $type = $object->type;
     if (!is_null($object)) {
         $object->remove();
     }
     $items = CRequest::getArray("selectedInView");
     foreach ($items as $id) {
         $object = CBaseManager::getWorkPlanCompetention($id);
         $object->remove();
     }
     $this->redirect("workplancompetentions.php?action=index&plan_id=" . $plan . "&type=" . $type);
 }