@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Clean up some custom field strings in Feed

Summary: Fixes T9919. We were missing feed strings and US English localizations for some of this stuff.

Test Plan:
Before:

{F1018877}

After:

{F1018879}
{F1018880}
{F1018881}

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T9919

Differential Revision: https://secure.phabricator.com/D14721

+58
+40
src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldPHIDs.php
··· 145 145 } 146 146 } 147 147 148 + public function getApplicationTransactionTitleForFeed( 149 + PhabricatorApplicationTransaction $xaction) { 150 + $author_phid = $xaction->getAuthorPHID(); 151 + $object_phid = $xaction->getObjectPHID(); 152 + 153 + $old = $this->decodeValue($xaction->getOldValue()); 154 + $new = $this->decodeValue($xaction->getNewValue()); 155 + 156 + $add = array_diff($new, $old); 157 + $rem = array_diff($old, $new); 158 + 159 + if ($add && !$rem) { 160 + return pht( 161 + '%s updated %s for %s, added %d: %s.', 162 + $xaction->renderHandleLink($author_phid), 163 + $this->getFieldName(), 164 + $xaction->renderHandleLink($object_phid), 165 + phutil_count($add), 166 + $xaction->renderHandleList($add)); 167 + } else if ($rem && !$add) { 168 + return pht( 169 + '%s updated %s for %s, removed %s: %s.', 170 + $xaction->renderHandleLink($author_phid), 171 + $this->getFieldName(), 172 + $xaction->renderHandleLink($object_phid), 173 + phutil_count($rem), 174 + $xaction->renderHandleList($rem)); 175 + } else { 176 + return pht( 177 + '%s updated %s for %s, added %s: %s; removed %s: %s.', 178 + $xaction->renderHandleLink($author_phid), 179 + $this->getFieldName(), 180 + $xaction->renderHandleLink($object_phid), 181 + phutil_count($add), 182 + $xaction->renderHandleList($add), 183 + phutil_count($rem), 184 + $xaction->renderHandleList($rem)); 185 + } 186 + } 187 + 148 188 public function validateApplicationTransactions( 149 189 PhabricatorApplicationTransactionEditor $editor, 150 190 $type,
+18
src/infrastructure/internationalization/translation/PhabricatorUSEnglishTranslation.php
··· 1483 1483 'repositories for updates yet.', 1484 1484 ), 1485 1485 1486 + 1487 + '%s updated %s, added %d: %s.' => 1488 + '%s updated %s, added: %4$s.', 1489 + 1490 + '%s updated %s, removed %s: %s.' => 1491 + '%s updated %s, removed: %4$s.', 1492 + 1493 + '%s updated %s, added %s: %s; removed %s: %s.' => 1494 + '%s updated %s, added: %4$s; removed: %6$s.', 1495 + 1496 + '%s updated %s for %s, added %d: %s.' => 1497 + '%s updated %s for %s, added: %5$s.', 1498 + 1499 + '%s updated %s for %s, removed %s: %s.' => 1500 + '%s updated %s for %s, removed: %5$s.', 1501 + 1502 + '%s updated %s for %s, added %s: %s; removed %s: %s.' => 1503 + '%s updated %s for %s, added: %5$s; removed; %7$s.', 1486 1504 ); 1487 1505 } 1488 1506