From db546e5558c643aaa995ec926189c5914b157829 Mon Sep 17 00:00:00 2001 From: Chad Little Date: Wed, 19 Jul 2017 10:47:22 -0700 Subject: [PATCH] Fix Pholio new mock feed story Summary: Gives some strength to name (needed to over-ride new images) and new create copy. Test Plan: Create a new mock, see proper story in feed. Reviewers: epriestley Reviewed By: epriestley Subscribers: Korvin Differential Revision: https://secure.phabricator.com/D18246 --- src/applications/pholio/editor/PholioMockEditor.php | 8 ++++++++ .../pholio/xaction/PholioMockNameTransaction.php | 4 ++++ 2 files changed, 12 insertions(+) diff --git a/src/applications/pholio/editor/PholioMockEditor.php b/src/applications/pholio/editor/PholioMockEditor.php index ebd5703170..c0fcf31f83 100644 --- a/src/applications/pholio/editor/PholioMockEditor.php +++ b/src/applications/pholio/editor/PholioMockEditor.php @@ -22,6 +22,14 @@ final class PholioMockEditor extends PhabricatorApplicationTransactionEditor { return $this->newImages; } + public function getCreateObjectTitle($author, $object) { + return pht('%s created this mock.', $author); + } + + public function getCreateObjectTitleForFeed($author, $object) { + return pht('%s created %s.', $author, $object); + } + public function getTransactionTypes() { $types = parent::getTransactionTypes(); diff --git a/src/applications/pholio/xaction/PholioMockNameTransaction.php b/src/applications/pholio/xaction/PholioMockNameTransaction.php index a96475f223..d1231636af 100644 --- a/src/applications/pholio/xaction/PholioMockNameTransaction.php +++ b/src/applications/pholio/xaction/PholioMockNameTransaction.php @@ -9,6 +9,10 @@ final class PholioMockNameTransaction return $object->getName(); } + public function getActionStrength() { + return 1.4; + } + public function applyInternalEffects($object, $value) { $object->setName($value); if ($object->getOriginalName() === null) {