public function deleteAjaxActionAuth(Param\AjaxString $id = null, Param\AjaxString $module = null) { if (is_null($id) || is_null($module)) { $this->ajax->setResponse('success', false); die; } if (\Difra\Plugins\Comments\Comment::checkDeleteRights($id->val(), $module->val())) { \Difra\Plugins\Comments\Comment::delete($id->val(), $module->val()); $this->ajax->setResponse('success', true); return; } $this->ajax->setResponse('success', false); }
public function deleteAjaxAction(Param\AnyString $module, Param\AnyInt $commentId) { \Difra\Plugins\Comments\Comment::delete($commentId->val(), $module->val()); $this->ajax->refresh(); }