@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.

Swap duplicate close status on Ponder for invalid

Summary: Until we have a proper close as duplicate workflow for Ponder, remove the option with something more sensible.

Test Plan: Closed a question as invalid, saw it closed and in feed.

Reviewers: epriestley

Reviewed By: epriestley

Subscribers: Korvin

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

+16 -14
+2
resources/sql/autopatches/20150829.ponder.dupe.1.sql
··· 1 + UPDATE {$NAMESPACE}_ponder.ponder_question 2 + SET status = 'invalid' WHERE status = 'duplicate';
+10 -10
src/applications/ponder/constants/PonderQuestionStatus.php
··· 5 5 const STATUS_OPEN = 'open'; 6 6 const STATUS_CLOSED_RESOLVED = 'resolved'; 7 7 const STATUS_CLOSED_OBSOLETE = 'obsolete'; 8 - const STATUS_CLOSED_DUPLICATE = 'duplicate'; 8 + const STATUS_CLOSED_INVALID = 'invalid'; 9 9 10 10 public static function getQuestionStatusMap() { 11 11 return array( 12 12 self::STATUS_OPEN => pht('Open'), 13 13 self::STATUS_CLOSED_RESOLVED => pht('Closed, Resolved'), 14 14 self::STATUS_CLOSED_OBSOLETE => pht('Closed, Obsolete'), 15 - self::STATUS_CLOSED_DUPLICATE => pht('Closed, Duplicate'), 15 + self::STATUS_CLOSED_INVALID => pht('Closed, Invalid'), 16 16 ); 17 17 } 18 18 ··· 21 21 self::STATUS_OPEN => pht('Open'), 22 22 self::STATUS_CLOSED_RESOLVED => pht('Closed, Resolved'), 23 23 self::STATUS_CLOSED_OBSOLETE => pht('Closed, Obsolete'), 24 - self::STATUS_CLOSED_DUPLICATE => pht('Closed, Duplicate'), 24 + self::STATUS_CLOSED_INVALID => pht('Closed, Invalid'), 25 25 ); 26 26 return idx($map, $status, pht('Unknown')); 27 27 } ··· 31 31 self::STATUS_OPEN => pht('Open'), 32 32 self::STATUS_CLOSED_RESOLVED => pht('Resolved'), 33 33 self::STATUS_CLOSED_OBSOLETE => pht('Obsolete'), 34 - self::STATUS_CLOSED_DUPLICATE => pht('Duplicate'), 34 + self::STATUS_CLOSED_INVALID => pht('Invalid'), 35 35 ); 36 36 return idx($map, $status, pht('Unknown')); 37 37 } ··· 43 43 self::STATUS_CLOSED_RESOLVED => 44 44 pht('This question has been answered or resolved.'), 45 45 self::STATUS_CLOSED_OBSOLETE => 46 - pht('This question is no longer valid or out of date.'), 47 - self::STATUS_CLOSED_DUPLICATE => 48 - pht('This question is a duplicate of another question.'), 46 + pht('This question is out of date.'), 47 + self::STATUS_CLOSED_INVALID => 48 + pht('This question is invalid.'), 49 49 ); 50 50 return idx($map, $status, pht('Unknown')); 51 51 } ··· 55 55 self::STATUS_OPEN => PHUITagView::COLOR_BLUE, 56 56 self::STATUS_CLOSED_RESOLVED => PHUITagView::COLOR_BLACK, 57 57 self::STATUS_CLOSED_OBSOLETE => PHUITagView::COLOR_BLACK, 58 - self::STATUS_CLOSED_DUPLICATE => PHUITagView::COLOR_BLACK, 58 + self::STATUS_CLOSED_INVALID => PHUITagView::COLOR_BLACK, 59 59 ); 60 60 61 61 return idx($map, $status); ··· 66 66 self::STATUS_OPEN => 'fa-question-circle', 67 67 self::STATUS_CLOSED_RESOLVED => 'fa-check', 68 68 self::STATUS_CLOSED_OBSOLETE => 'fa-ban', 69 - self::STATUS_CLOSED_DUPLICATE => 'fa-clone', 69 + self::STATUS_CLOSED_INVALID => 'fa-ban', 70 70 ); 71 71 72 72 return idx($map, $status); ··· 82 82 return array( 83 83 self::STATUS_CLOSED_RESOLVED, 84 84 self::STATUS_CLOSED_OBSOLETE, 85 - self::STATUS_CLOSED_DUPLICATE, 85 + self::STATUS_CLOSED_INVALID, 86 86 ); 87 87 } 88 88
+4 -4
src/applications/ponder/storage/PonderQuestionTransaction.php
··· 100 100 return pht( 101 101 '%s closed this question as obsolete.', 102 102 $this->renderHandleLink($author_phid)); 103 - case PonderQuestionStatus::STATUS_CLOSED_DUPLICATE: 103 + case PonderQuestionStatus::STATUS_CLOSED_INVALID: 104 104 return pht( 105 - '%s closed this question as a duplicate.', 105 + '%s closed this question as invalid.', 106 106 $this->renderHandleLink($author_phid)); 107 107 } 108 108 } ··· 272 272 '%s closed %s as resolved.', 273 273 $this->renderHandleLink($author_phid), 274 274 $this->renderHandleLink($object_phid)); 275 - case PonderQuestionStatus::STATUS_CLOSED_DUPLICATE: 275 + case PonderQuestionStatus::STATUS_CLOSED_INVALID: 276 276 return pht( 277 - '%s closed %s as duplicate.', 277 + '%s closed %s as invalid.', 278 278 $this->renderHandleLink($author_phid), 279 279 $this->renderHandleLink($object_phid)); 280 280 case PonderQuestionStatus::STATUS_CLOSED_OBSOLETE: