Page MenuHomePhorge

AlmanacNamespaceEditor.php
No OneTemporary

Size
1 KB
Referenced Files
None
Subscribers
None

AlmanacNamespaceEditor.php

<?php
final class AlmanacNamespaceEditor
extends AlmanacEditor {
public function getEditorObjectsDescription() {
return pht('Almanac Namespace');
}
public function getCreateObjectTitle($author, $object) {
return pht('%s created this namespace.', $author);
}
public function getCreateObjectTitleForFeed($author, $object) {
return pht('%s created %s.', $author, $object);
}
protected function supportsSearch() {
return true;
}
public function getTransactionTypes() {
$types = parent::getTransactionTypes();
$types[] = PhabricatorTransactions::TYPE_VIEW_POLICY;
$types[] = PhabricatorTransactions::TYPE_EDIT_POLICY;
return $types;
}
protected function didCatchDuplicateKeyException(
PhabricatorLiskDAO $object,
array $xactions,
Exception $ex) {
$errors = array();
$errors[] = new PhabricatorApplicationTransactionValidationError(
null,
pht('Invalid'),
pht(
'Another namespace with this name already exists. Each namespace '.
'must have a unique name.'),
null);
throw new PhabricatorApplicationTransactionValidationException($errors);
}
}

File Metadata

Mime Type
text/x-php
Expires
Tue, May 6, 3:48 AM (1 d, 18 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
80022
Default Alt Text
AlmanacNamespaceEditor.php (1 KB)

Event Timeline