/** * Adds an announce * * @param array $input Raw input data * @return boolean */ public function add(array $input) { $input = $this->prepareInput($input); $input['web_page_id'] = ''; $this->announceMapper->insert(ArrayUtils::arrayWithout($input, array('slug'))); $id = $this->getLastId(); $this->track('Announce "%s" has been added', $input['name']); $this->webPageManager->add($id, $input['slug'], 'Announcements', 'Announcement:Announce@indexAction', $this->announceMapper); return true; }