private function getTransformedContent(WikiPage $wiki_page, WikiPageVersion $version, WikiRequest $request) { $dbi = $request->_dbi; $page_db = $dbi->getPage($wiki_page->getPagename()); $revision = $page_db->getRevision($version->getVersionId()); return $revision->getTransformedContent(); }
<td><strong><?php echo $this->t('user_note_edits'); ?> </strong></td> <td><?php echo $this->linkTo(NoteVersion::where(['user_id' => $this->user->id])->count(), array('note#history', 'user_id' => $this->user->id)); ?> </td> </tr> <tr> <td><strong><?php echo $this->t('user_wiki_edits'); ?> </strong></td> <td><?php echo $this->linkTo(WikiPageVersion::where(['user_id' => $this->user->id])->count(), array('wiki#recent_changes', 'user_id' => $this->user->id)); ?> </td> </tr> <tr> <td><strong><?php echo $this->t('user_forum_post'); ?> </strong></td> <td><?php echo ForumPost::where(['creator_id' => $this->user->id])->count(); ?> </td> </tr> <?php if ($this->user->invited_by) {
public function prev() { WikiPageVersion::where('wiki_page_id = ? AND version = ?', $this->wiki_page_id, $this->version - 1)->first(); }
public function history() { $this->set_title('Wiki History'); if ($this->params()->title) { $wiki = WikiPage::find_by_title($this->params()->title); $wiki_id = $wiki ? $wiki->id : null; } elseif ($this->params()->id) { $wiki_id = $this->params()->id; } else { $wiki_id = null; } $this->wiki_pages = WikiPageVersion::where('wiki_page_id = ?', $wiki_id)->order('version DESC')->take(); $this->respond_to_list("wiki_pages"); }