Make PhameBlog implement PhabricatorApplicationTransactionInterface
Summary: Ref T6367. Test Plan: Static correctness. Reviewers: btrahan Reviewed By: btrahan Subscribers: epriestley Maniphest Tasks: T6367 Differential Revision: https://secure.phabricator.com/D13143
This commit is contained in:
@@ -6273,6 +6273,7 @@ phutil_register_library_map(array(
|
|||||||
'PhameDAO',
|
'PhameDAO',
|
||||||
'PhabricatorPolicyInterface',
|
'PhabricatorPolicyInterface',
|
||||||
'PhabricatorMarkupInterface',
|
'PhabricatorMarkupInterface',
|
||||||
|
'PhabricatorApplicationTransactionInterface',
|
||||||
),
|
),
|
||||||
'PhameBlogDeleteController' => 'PhameController',
|
'PhameBlogDeleteController' => 'PhameController',
|
||||||
'PhameBlogEditController' => 'PhameController',
|
'PhameBlogEditController' => 'PhameController',
|
||||||
|
|||||||
@@ -1,7 +1,10 @@
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
final class PhameBlog extends PhameDAO
|
final class PhameBlog extends PhameDAO
|
||||||
implements PhabricatorPolicyInterface, PhabricatorMarkupInterface {
|
implements
|
||||||
|
PhabricatorPolicyInterface,
|
||||||
|
PhabricatorMarkupInterface,
|
||||||
|
PhabricatorApplicationTransactionInterface {
|
||||||
|
|
||||||
const MARKUP_FIELD_DESCRIPTION = 'markup:description';
|
const MARKUP_FIELD_DESCRIPTION = 'markup:description';
|
||||||
|
|
||||||
@@ -302,4 +305,26 @@ final class PhameBlog extends PhameDAO
|
|||||||
return (bool)$this->getPHID();
|
return (bool)$this->getPHID();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* -( PhabricatorApplicationTransactionInterface )------------------------- */
|
||||||
|
|
||||||
|
|
||||||
|
public function getApplicationTransactionEditor() {
|
||||||
|
return new PhameBlogEditor();
|
||||||
|
}
|
||||||
|
|
||||||
|
public function getApplicationTransactionObject() {
|
||||||
|
return $this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function getApplicationTransactionTemplate() {
|
||||||
|
return new PhameBlogTransaction();
|
||||||
|
}
|
||||||
|
|
||||||
|
public function willRenderTimeline(
|
||||||
|
PhabricatorApplicationTransactionView $timeline,
|
||||||
|
AphrontRequest $request) {
|
||||||
|
return $timeline;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user