art = new NLArticle($title, $body, $append); } // }}} // {{{ function formu() public function formu() { return 'include/form.valid.nl.tpl'; } // }}} // {{{ function editor() public function editor() { return 'include/form.valid.edit-nl.tpl'; } // }}} // {{{ function handle_editor() protected function handle_editor() { $this->art->_body = Env::v('nl_body'); $this->art->_title = Env::v('nl_title'); $this->art->_append = Env::v('nl_append'); return true; } // }}} // {{{ function _mail_subj protected function _mail_subj() { return "[Polytechnique.org/NL] Proposition d'article dans la NL"; } // }}} // {{{ function _mail_body protected function _mail_body($isok) { if ($isok) { return ' L\'article que tu avais proposé ('.$this->art->title().') vient d\'être validé.'; } else { return ' L\'article que tu avais proposé ('.$this->art->title().') a été refusé.'; } } // }}} // {{{ function commit() public function commit() { $nl = new Newsletter(); $nl->saveArticle($this->art); return true; } // }}} } // }}} // vim:set et sw=4 sts=4 sws=4 foldmethod=marker enc=utf-8: ?>