@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<?php
2
3final class ManiphestCloseEmailCommand
4 extends ManiphestEmailCommand {
5
6 public function getCommand() {
7 return 'close';
8 }
9
10 public function getCommandSummary() {
11 return pht(
12 'Close a task. This changes the task status to the default closed '.
13 'status. For a more powerful (but less concise) way to change task '.
14 'statuses, see `%s`.',
15 '!status');
16 }
17
18 public function buildTransactions(
19 PhabricatorUser $viewer,
20 PhabricatorApplicationTransactionInterface $object,
21 PhabricatorMetaMTAReceivedMail $mail,
22 $command,
23 array $argv) {
24 $xactions = array();
25
26 $xactions[] = $object->getApplicationTransactionTemplate()
27 ->setTransactionType(ManiphestTaskStatusTransaction::TRANSACTIONTYPE)
28 ->setNewValue(ManiphestTaskStatus::getDefaultClosedStatus());
29
30 return $xactions;
31 }
32
33}