Admin_ElementController::noteAddAction PHP Method

noteAddAction() public method

public noteAddAction ( )
    public function noteAddAction()
    {
        $this->checkPermission("notes_events");
        $note = new Element\Note();
        $note->setCid((int) $this->getParam("cid"));
        $note->setCtype($this->getParam("ctype"));
        $note->setDate(time());
        $note->setTitle($this->getParam("title"));
        $note->setDescription($this->getParam("description"));
        $note->setType($this->getParam("type"));
        $note->save();
        $this->_helper->json(["success" => true]);
    }