mirror of
https://we.phorge.it/source/phorge.git
synced 2025-01-08 22:01:03 +01:00
b32a00dbac
Summary: Updates Legalpad to use EditEngine, paving the way for //transaction comments//. Spooky. Test Plan: - New Document - Require signing, Corp - see fail - Require signing, Noone - see fail - Require signing, Ind - get asked to sign - Edit Document Reviewers: epriestley Reviewed By: epriestley Subscribers: Korvin Differential Revision: https://secure.phabricator.com/D17862
29 lines
697 B
PHP
29 lines
697 B
PHP
<?php
|
|
|
|
abstract class LegalpadController extends PhabricatorController {
|
|
|
|
public function buildSideNav($for_app = false) {
|
|
$user = $this->getRequest()->getUser();
|
|
|
|
$nav = new AphrontSideNavFilterView();
|
|
$nav->setBaseURI(new PhutilURI($this->getApplicationURI()));
|
|
|
|
if ($for_app) {
|
|
$nav->addFilter('edit/', pht('Create Document'));
|
|
}
|
|
|
|
id(new LegalpadDocumentSearchEngine())
|
|
->setViewer($user)
|
|
->addNavigationItems($nav->getMenu());
|
|
|
|
$nav->addLabel(pht('Signatures'));
|
|
$nav->addFilter('signatures/', pht('Find Signatures'));
|
|
|
|
return $nav;
|
|
}
|
|
|
|
public function buildApplicationMenu() {
|
|
return $this->buildSideNav(true)->getMenu();
|
|
}
|
|
|
|
}
|