Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15411169
D18777.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
2 KB
Referenced Files
None
Subscribers
None
D18777.diff
View Options
diff --git a/src/applications/maniphest/conduit/ManiphestGetTaskTransactionsConduitAPIMethod.php b/src/applications/maniphest/conduit/ManiphestGetTaskTransactionsConduitAPIMethod.php
--- a/src/applications/maniphest/conduit/ManiphestGetTaskTransactionsConduitAPIMethod.php
+++ b/src/applications/maniphest/conduit/ManiphestGetTaskTransactionsConduitAPIMethod.php
@@ -21,6 +21,16 @@
return 'nonempty list<dict<string, wild>>';
}
+ public function getMethodStatus() {
+ return self::METHOD_STATUS_FROZEN;
+ }
+
+ public function getMethodStatusDescription() {
+ return pht(
+ 'This method is frozen and will eventually be deprecated. New code '.
+ 'should use "transaction.search" instead.');
+ }
+
protected function execute(ConduitAPIRequest $request) {
$results = array();
$task_ids = $request->getValue('ids');
diff --git a/src/applications/maniphest/xaction/ManiphestTaskPriorityTransaction.php b/src/applications/maniphest/xaction/ManiphestTaskPriorityTransaction.php
--- a/src/applications/maniphest/xaction/ManiphestTaskPriorityTransaction.php
+++ b/src/applications/maniphest/xaction/ManiphestTaskPriorityTransaction.php
@@ -6,20 +6,17 @@
const TRANSACTIONTYPE = 'priority';
public function generateOldValue($object) {
- if ($this->isNewObject()) {
- return null;
- }
- return $object->getPriority();
+ return (string)$object->getPriority();
}
public function generateNewValue($object, $value) {
// `$value` is supposed to be a keyword, but if the priority
// assigned to a task has been removed from the config,
// no such keyword will be available. Other edits to the task
- // should still be allowed, even if the priority is no longer
+ // should still be allowed, even if the priority is no longer
// valid, so treat this as a no-op.
if ($value === ManiphestTaskPriority::UNKNOWN_PRIORITY_KEYWORD) {
- return $object->getPriority();
+ return (string)$object->getPriority();
}
return (string)ManiphestTaskPriority::getTaskPriorityFromKeyword($value);
diff --git a/src/applications/maniphest/xaction/ManiphestTaskStatusTransaction.php b/src/applications/maniphest/xaction/ManiphestTaskStatusTransaction.php
--- a/src/applications/maniphest/xaction/ManiphestTaskStatusTransaction.php
+++ b/src/applications/maniphest/xaction/ManiphestTaskStatusTransaction.php
@@ -6,9 +6,6 @@
const TRANSACTIONTYPE = 'status';
public function generateOldValue($object) {
- if ($this->isNewObject()) {
- return null;
- }
return $object->getStatus();
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Mar 20, 8:53 AM (2 d, 21 h ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7387894
Default Alt Text
D18777.diff (2 KB)
Attached To
Mode
D18777: Freeze "maniphest.gettasktransactions" and make status/priority transactions more consistent
Attached
Detach File
Event Timeline
Log In to Comment