Page MenuHomePhabricator

D14796.diff
No OneTemporary

D14796.diff

diff --git a/src/__phutil_library_map__.php b/src/__phutil_library_map__.php
--- a/src/__phutil_library_map__.php
+++ b/src/__phutil_library_map__.php
@@ -238,6 +238,7 @@
'ConduitMethodDoesNotExistException' => 'applications/conduit/protocol/exception/ConduitMethodDoesNotExistException.php',
'ConduitMethodNotFoundException' => 'applications/conduit/protocol/exception/ConduitMethodNotFoundException.php',
'ConduitPHIDListParameterType' => 'applications/conduit/parametertype/ConduitPHIDListParameterType.php',
+ 'ConduitPHIDParameterType' => 'applications/conduit/parametertype/ConduitPHIDParameterType.php',
'ConduitParameterType' => 'applications/conduit/parametertype/ConduitParameterType.php',
'ConduitPingConduitAPIMethod' => 'applications/conduit/method/ConduitPingConduitAPIMethod.php',
'ConduitProjectListParameterType' => 'applications/conduit/parametertype/ConduitProjectListParameterType.php',
@@ -248,6 +249,7 @@
'ConduitStringParameterType' => 'applications/conduit/parametertype/ConduitStringParameterType.php',
'ConduitTokenGarbageCollector' => 'applications/conduit/garbagecollector/ConduitTokenGarbageCollector.php',
'ConduitUserListParameterType' => 'applications/conduit/parametertype/ConduitUserListParameterType.php',
+ 'ConduitWildParameterType' => 'applications/conduit/parametertype/ConduitWildParameterType.php',
'ConpherenceColumnViewController' => 'applications/conpherence/controller/ConpherenceColumnViewController.php',
'ConpherenceConduitAPIMethod' => 'applications/conpherence/conduit/ConpherenceConduitAPIMethod.php',
'ConpherenceConfigOptions' => 'applications/conpherence/config/ConpherenceConfigOptions.php',
@@ -4103,6 +4105,7 @@
'ConduitMethodDoesNotExistException' => 'ConduitMethodNotFoundException',
'ConduitMethodNotFoundException' => 'ConduitException',
'ConduitPHIDListParameterType' => 'ConduitListParameterType',
+ 'ConduitPHIDParameterType' => 'ConduitListParameterType',
'ConduitParameterType' => 'Phobject',
'ConduitPingConduitAPIMethod' => 'ConduitAPIMethod',
'ConduitProjectListParameterType' => 'ConduitListParameterType',
@@ -4113,6 +4116,7 @@
'ConduitStringParameterType' => 'ConduitListParameterType',
'ConduitTokenGarbageCollector' => 'PhabricatorGarbageCollector',
'ConduitUserListParameterType' => 'ConduitListParameterType',
+ 'ConduitWildParameterType' => 'ConduitListParameterType',
'ConpherenceColumnViewController' => 'ConpherenceController',
'ConpherenceConduitAPIMethod' => 'ConduitAPIMethod',
'ConpherenceConfigOptions' => 'PhabricatorApplicationConfigOptions',
diff --git a/src/applications/conduit/parametertype/ConduitPHIDParameterType.php b/src/applications/conduit/parametertype/ConduitPHIDParameterType.php
new file mode 100644
--- /dev/null
+++ b/src/applications/conduit/parametertype/ConduitPHIDParameterType.php
@@ -0,0 +1,35 @@
+<?php
+
+final class ConduitPHIDParameterType
+ extends ConduitListParameterType {
+
+ protected function getParameterValue(array $request, $key) {
+ $value = parent::getParameterValue($request, $key);
+
+ if (!is_string($value)) {
+ $this->raiseValidationException(
+ $request,
+ $key,
+ pht('Expected PHID, got something else.'));
+ }
+
+ return $value;
+ }
+
+ protected function getParameterTypeName() {
+ return 'phid';
+ }
+
+ protected function getParameterFormatDescriptions() {
+ return array(
+ pht('A PHID.'),
+ );
+ }
+
+ protected function getParameterExamples() {
+ return array(
+ '"PHID-WXYZ-1111222233334444"',
+ );
+ }
+
+}
diff --git a/src/applications/conduit/parametertype/ConduitWildParameterType.php b/src/applications/conduit/parametertype/ConduitWildParameterType.php
new file mode 100644
--- /dev/null
+++ b/src/applications/conduit/parametertype/ConduitWildParameterType.php
@@ -0,0 +1,22 @@
+<?php
+
+final class ConduitWildParameterType
+ extends ConduitListParameterType {
+
+ protected function getParameterTypeName() {
+ return 'wild';
+ }
+
+ protected function getParameterFormatDescriptions() {
+ return array(
+ pht('Any mixed or complex value. Check the documentation for details.'),
+ );
+ }
+
+ protected function getParameterExamples() {
+ return array(
+ pht('(Wildcard)'),
+ );
+ }
+
+}
diff --git a/src/applications/maniphest/editor/ManiphestEditEngine.php b/src/applications/maniphest/editor/ManiphestEditEngine.php
--- a/src/applications/maniphest/editor/ManiphestEditEngine.php
+++ b/src/applications/maniphest/editor/ManiphestEditEngine.php
@@ -76,6 +76,8 @@
->setKey('parent')
->setLabel(pht('Parent Task'))
->setDescription(pht('Task to make this a subtask of.'))
+ ->setConduitDescription(pht('Create as a subtask of another task.'))
+ ->setConduitTypeDescription(pht('PHID of the parent task.'))
->setAliases(array('parentPHID'))
->setTransactionType(ManiphestTransaction::TYPE_PARENT)
->setHandleParameterType(new ManiphestTaskListHTTPParameterType())
@@ -87,6 +89,8 @@
->setKey('column')
->setLabel(pht('Column'))
->setDescription(pht('Workboard column to create this task into.'))
+ ->setConduitDescription(pht('Create into a workboard column.'))
+ ->setConduitTypeDescription(pht('PHID of workboard column.'))
->setAliases(array('columnPHID'))
->setTransactionType(ManiphestTransaction::TYPE_COLUMN)
->setSingleValue(null)
@@ -98,6 +102,8 @@
->setKey('title')
->setLabel(pht('Title'))
->setDescription(pht('Name of the task.'))
+ ->setConduitDescription(pht('Rename the task.'))
+ ->setConduitTypeDescription(pht('New task name.'))
->setTransactionType(ManiphestTransaction::TYPE_TITLE)
->setIsRequired(true)
->setValue($object->getTitle()),
@@ -106,6 +112,9 @@
->setAliases(array('ownerPHID', 'assign', 'assigned'))
->setLabel(pht('Assigned To'))
->setDescription(pht('User who is responsible for the task.'))
+ ->setConduitDescription(pht('Reassign the task.'))
+ ->setConduitTypeDescription(
+ pht('New task owner, or `null` to unassign.'))
->setTransactionType(ManiphestTransaction::TYPE_OWNER)
->setIsCopyable(true)
->setSingleValue($object->getOwnerPHID())
@@ -115,6 +124,8 @@
->setKey('status')
->setLabel(pht('Status'))
->setDescription(pht('Status of the task.'))
+ ->setConduitDescription(pht('Change the task status.'))
+ ->setConduitTypeDescription(pht('New task status constant.'))
->setTransactionType(ManiphestTransaction::TYPE_STATUS)
->setIsCopyable(true)
->setValue($object->getStatus())
@@ -125,6 +136,8 @@
->setKey('priority')
->setLabel(pht('Priority'))
->setDescription(pht('Priority of the task.'))
+ ->setConduitDescription(pht('Change the priority of the task.'))
+ ->setConduitTypeDescription(pht('New task priority constant.'))
->setTransactionType(ManiphestTransaction::TYPE_PRIORITY)
->setIsCopyable(true)
->setValue($object->getPriority())
@@ -134,6 +147,8 @@
->setKey('description')
->setLabel(pht('Description'))
->setDescription(pht('Task description.'))
+ ->setConduitDescription(pht('Update the task description.'))
+ ->setConduitTypeDescription(pht('New task description.'))
->setTransactionType(ManiphestTransaction::TYPE_DESCRIPTION)
->setValue($object->getDescription()),
);
diff --git a/src/applications/owners/editor/PhabricatorOwnersPackageEditEngine.php b/src/applications/owners/editor/PhabricatorOwnersPackageEditEngine.php
--- a/src/applications/owners/editor/PhabricatorOwnersPackageEditEngine.php
+++ b/src/applications/owners/editor/PhabricatorOwnersPackageEditEngine.php
@@ -122,9 +122,12 @@
id(new PhabricatorConduitEditField())
->setKey('paths.set')
->setLabel(pht('Paths'))
- ->setDescription(pht('Set paths for this package.'))
->setIsConduitOnly(true)
->setTransactionType(PhabricatorOwnersPackageTransaction::TYPE_PATHS)
+ ->setConduitDescription(
+ pht('Overwrite existing package paths with new paths.'))
+ ->setConduitTypeDescription(
+ pht('List of dictionaries, each describing a path.'))
->setConduitDocumentation($paths_help),
);
}
diff --git a/src/applications/paste/editor/PhabricatorPasteEditEngine.php b/src/applications/paste/editor/PhabricatorPasteEditEngine.php
--- a/src/applications/paste/editor/PhabricatorPasteEditEngine.php
+++ b/src/applications/paste/editor/PhabricatorPasteEditEngine.php
@@ -59,38 +59,46 @@
id(new PhabricatorTextEditField())
->setKey('title')
->setLabel(pht('Title'))
- ->setDescription(pht('Name of the paste.'))
->setTransactionType(PhabricatorPasteTransaction::TYPE_TITLE)
+ ->setDescription(pht('The title of the paste.'))
+ ->setConduitDescription(pht('Retitle the paste.'))
+ ->setConduitTypeDescription(pht('New paste title.'))
->setValue($object->getTitle()),
id(new PhabricatorSelectEditField())
->setKey('language')
->setLabel(pht('Language'))
- ->setDescription(
- pht(
- 'Programming language to interpret the paste as for syntax '.
- 'highlighting. By default, the language is inferred from the '.
- 'title.'))
- ->setAliases(array('lang'))
->setTransactionType(PhabricatorPasteTransaction::TYPE_LANGUAGE)
+ ->setAliases(array('lang'))
->setIsCopyable(true)
- ->setValue($object->getLanguage())
- ->setOptions($langs),
+ ->setOptions($langs)
+ ->setDescription(
+ pht(
+ 'Language used for syntax highlighting. By default, inferred '.
+ 'from the title.'))
+ ->setConduitDescription(
+ pht('Change language used for syntax highlighting.'))
+ ->setConduitTypeDescription(pht('New highlighting language.'))
+ ->setValue($object->getLanguage()),
id(new PhabricatorTextAreaEditField())
->setKey('text')
->setLabel(pht('Text'))
- ->setDescription(pht('The main body text of the paste.'))
->setTransactionType(PhabricatorPasteTransaction::TYPE_CONTENT)
->setMonospaced(true)
->setHeight(AphrontFormTextAreaControl::HEIGHT_VERY_TALL)
+ ->setDescription(pht('The main body text of the paste.'))
+ ->setConduitDescription(pht('Change the paste content.'))
+ ->setConduitTypeDescription(pht('New body content.'))
->setValue($object->getRawContent()),
id(new PhabricatorSelectEditField())
->setKey('status')
->setLabel(pht('Status'))
- ->setDescription(pht('Active or archive the paste.'))
->setTransactionType(PhabricatorPasteTransaction::TYPE_STATUS)
->setIsConduitOnly(true)
- ->setValue($object->getStatus())
- ->setOptions(PhabricatorPaste::getStatusNameMap()),
+ ->setOptions(PhabricatorPaste::getStatusNameMap())
+ ->setDescription(pht('Active or archived status.'))
+ ->setConduitDescription(pht('Active or archive the paste.'))
+ ->setConduitTypeDescription(pht('New paste status constant.'))
+ ->setValue($object->getStatus()),
);
}
diff --git a/src/applications/policy/editor/PhabricatorPolicyEditEngineExtension.php b/src/applications/policy/editor/PhabricatorPolicyEditEngineExtension.php
--- a/src/applications/policy/editor/PhabricatorPolicyEditEngineExtension.php
+++ b/src/applications/policy/editor/PhabricatorPolicyEditEngineExtension.php
@@ -81,13 +81,14 @@
$policy_field = id(new PhabricatorPolicyEditField())
->setKey($key)
->setLabel($label)
- ->setDescription($description)
->setAliases($aliases)
->setIsCopyable(true)
->setCapability($capability)
->setPolicies($policies)
->setTransactionType($type)
->setEditTypeKey($edit)
+ ->setConduitDescription($description)
+ ->setConduitTypeDescription(pht('New policy PHID or constant.'))
->setValue($object->getPolicy($capability));
$fields[] = $policy_field;
@@ -99,12 +100,14 @@
->setKey('spacePHID')
->setLabel(pht('Space'))
->setEditTypeKey('space')
- ->setDescription(
- pht('Shifts the object in the Spaces application.'))
->setIsCopyable(true)
->setIsReorderable(false)
->setAliases(array('space', 'policy.space'))
->setTransactionType($type_space)
+ ->setDescription(pht('Select a space for the object.'))
+ ->setConduitDescription(
+ pht('Shift the object between spaces.'))
+ ->setConduitTypeDescription(pht('New space PHID.'))
->setValue($object->getSpacePHID());
$fields[] = $space_field;
diff --git a/src/applications/project/engineextension/PhabricatorProjectsEditEngineExtension.php b/src/applications/project/engineextension/PhabricatorProjectsEditEngineExtension.php
--- a/src/applications/project/engineextension/PhabricatorProjectsEditEngineExtension.php
+++ b/src/applications/project/engineextension/PhabricatorProjectsEditEngineExtension.php
@@ -46,19 +46,27 @@
->setKey('projectPHIDs')
->setLabel(pht('Projects'))
->setEditTypeKey('projects')
- ->setDescription(pht('Add or remove associated projects.'))
->setAliases(array('project', 'projects'))
->setIsCopyable(true)
->setUseEdgeTransactions(true)
- ->setEdgeTransactionDescriptions(
- pht('Add projects.'),
- pht('Remove projects.'),
- pht('Set associated projects, overwriting current value.'))
->setCommentActionLabel(pht('Change Projects'))
+ ->setDescription(pht('Select projects for the object.'))
->setTransactionType($edge_type)
->setMetadataValue('edge:type', $project_edge_type)
->setValue($project_phids);
+ $projects_field->setViewer($engine->getViewer());
+
+ $edit_add = $projects_field->getConduitEditType('projects.add')
+ ->setConduitDescription(pht('Add projects.'));
+
+ $edit_set = $projects_field->getConduitEditType('projects.set')
+ ->setConduitDescription(
+ pht('Set projects, overwriting current value.'));
+
+ $edit_rem = $projects_field->getConduitEditType('projects.remove')
+ ->setConduitDescription(pht('Remove projects.'));
+
return array(
$projects_field,
);
diff --git a/src/applications/subscriptions/engineextension/PhabricatorSubscriptionsEditEngineExtension.php b/src/applications/subscriptions/engineextension/PhabricatorSubscriptionsEditEngineExtension.php
--- a/src/applications/subscriptions/engineextension/PhabricatorSubscriptionsEditEngineExtension.php
+++ b/src/applications/subscriptions/engineextension/PhabricatorSubscriptionsEditEngineExtension.php
@@ -41,18 +41,25 @@
->setKey('subscriberPHIDs')
->setLabel(pht('Subscribers'))
->setEditTypeKey('subscribers')
- ->setDescription(pht('Manage subscribers.'))
->setAliases(array('subscriber', 'subscribers'))
->setIsCopyable(true)
->setUseEdgeTransactions(true)
- ->setEdgeTransactionDescriptions(
- pht('Add subscribers.'),
- pht('Remove subscribers.'),
- pht('Set subscribers, overwriting current value.'))
->setCommentActionLabel(pht('Change Subscribers'))
->setTransactionType($subscribers_type)
->setValue($sub_phids);
+ $subscribers_field->setViewer($engine->getViewer());
+
+ $edit_add = $subscribers_field->getConduitEditType('subscribers.add')
+ ->setConduitDescription(pht('Add subscribers.'));
+
+ $edit_set = $subscribers_field->getConduitEditType('subscribers.set')
+ ->setConduitDescription(
+ pht('Set subscribers, overwriting current value.'));
+
+ $edit_rem = $subscribers_field->getConduitEditType('subscribers.remove')
+ ->setConduitDescription(pht('Remove subscribers.'));
+
return array(
$subscribers_field,
);
diff --git a/src/applications/transactions/editengine/PhabricatorEditEngine.php b/src/applications/transactions/editengine/PhabricatorEditEngine.php
--- a/src/applications/transactions/editengine/PhabricatorEditEngine.php
+++ b/src/applications/transactions/editengine/PhabricatorEditEngine.php
@@ -64,6 +64,10 @@
abstract public function getEngineApplicationClass();
abstract protected function buildCustomEditFields($object);
+ protected function didBuildCustomEditFields($object, array $fields) {
+ return;
+ }
+
public function getFieldsForConfig(
PhabricatorEditEngineConfiguration $config) {
@@ -82,6 +86,15 @@
$fields = $this->buildCustomEditFields($object);
+ foreach ($fields as $field) {
+ $field
+ ->setViewer($viewer)
+ ->setObject($object);
+ }
+
+ $fields = mpull($fields, null, 'getKey');
+ $this->didBuildCustomEditFields($object, $fields);
+
$extensions = PhabricatorEditEngineExtension::getAllEnabledExtensions();
foreach ($extensions as $extension) {
$extension->setViewer($viewer);
@@ -96,19 +109,22 @@
assert_instances_of($extension_fields, 'PhabricatorEditField');
foreach ($extension_fields as $field) {
- $fields[] = $field;
+ $field
+ ->setViewer($viewer)
+ ->setObject($object);
+ }
+
+ $extension_fields = mpull($extension_fields, null, 'getKey');
+ $extension->didBuildCustomEditFields($this, $object, $extension_fields);
+
+ foreach ($extension_fields as $key => $field) {
+ $fields[$key] = $field;
}
}
$config = $this->getEditEngineConfiguration();
$fields = $config->applyConfigurationToFields($this, $object, $fields);
- foreach ($fields as $field) {
- $field
- ->setViewer($viewer)
- ->setObject($object);
- }
-
return $fields;
}
@@ -1595,6 +1611,11 @@
foreach ($xactions as $xaction) {
$type = $types[$xaction['type']];
+ // Let the parameter type interpret the value. This allows you to
+ // use usernames in list<user> fields, for example.
+ $parameter_type = $type->getConduitParameterType();
+ $xaction['value'] = $parameter_type->getValue($xaction, 'value');
+
$type_xactions = $type->generateTransactions(
clone $template,
$xaction);
diff --git a/src/applications/transactions/editengine/PhabricatorEditEngineAPIMethod.php b/src/applications/transactions/editengine/PhabricatorEditEngineAPIMethod.php
--- a/src/applications/transactions/editengine/PhabricatorEditEngineAPIMethod.php
+++ b/src/applications/transactions/editengine/PhabricatorEditEngineAPIMethod.php
@@ -146,17 +146,16 @@
);
$key = pht('Key');
- $summary = pht('Summary');
$description = pht('Description');
$head_type = pht('Type');
$table = array();
- $table[] = "| {$key} | {$summary} |";
+ $table[] = "| {$key} | {$description} |";
$table[] = '|--------|----------------|';
foreach ($types as $type) {
$edit_type = $type->getEditType();
- $edit_summary = $type->getSummary();
- $table[] = "| `{$edit_type}` | {$edit_summary} |";
+ $edit_description = $type->getConduitDescription();
+ $table[] = "| `{$edit_type}` | {$edit_description} |";
}
$out[] = implode("\n", $table);
@@ -166,7 +165,7 @@
$section[] = pht('Edit Type: %s', $type->getEditType());
$section[] = '---------';
$section[] = null;
- $section[] = $type->getDescription();
+ $section[] = $type->getConduitDescription();
$section[] = null;
$section[] = pht(
'This edit generates transactions of type `%s` internally.',
@@ -183,12 +182,8 @@
'Use `%s` to select this edit type.',
$type->getEditType());
- $value_type = $type->getValueType();
- if (!strlen($value_type)) {
- $value_type = '?';
- }
-
- $value_description = $type->getValueDescription();
+ $value_type = $type->getConduitType();
+ $value_description = $type->getConduitTypeDescription();
$table = array();
$table[] = "| {$key} | {$head_type} | {$description} |";
diff --git a/src/applications/transactions/editengineextension/PhabricatorCommentEditEngineExtension.php b/src/applications/transactions/editengineextension/PhabricatorCommentEditEngineExtension.php
--- a/src/applications/transactions/editengineextension/PhabricatorCommentEditEngineExtension.php
+++ b/src/applications/transactions/editengineextension/PhabricatorCommentEditEngineExtension.php
@@ -41,13 +41,15 @@
$comment_field = id(new PhabricatorCommentEditField())
->setKey('comment')
->setLabel(pht('Comments'))
- ->setDescription(pht('Add comments.'))
->setAliases(array('comments'))
->setIsHidden(true)
->setIsReorderable(false)
->setIsDefaultable(false)
->setIsLockable(false)
->setTransactionType($comment_type)
+ ->setConduitDescription(pht('Make comments.'))
+ ->setConduitTypeDescription(
+ pht('Comment to add, formatted as remarkup.'))
->setValue(null);
return array(
diff --git a/src/applications/transactions/editengineextension/PhabricatorEditEngineExtension.php b/src/applications/transactions/editengineextension/PhabricatorEditEngineExtension.php
--- a/src/applications/transactions/editengineextension/PhabricatorEditEngineExtension.php
+++ b/src/applications/transactions/editengineextension/PhabricatorEditEngineExtension.php
@@ -32,6 +32,13 @@
PhabricatorEditEngine $engine,
PhabricatorApplicationTransactionInterface $object);
+ public function didBuildCustomEditFields(
+ PhabricatorEditEngine $engine,
+ PhabricatorApplicationTransactionInterface $object,
+ array $fields) {
+ return;
+ }
+
final public static function getAllExtensions() {
return id(new PhutilClassMapQuery())
->setAncestorClass(__CLASS__)
diff --git a/src/applications/transactions/editfield/PhabricatorCommentEditField.php b/src/applications/transactions/editfield/PhabricatorCommentEditField.php
--- a/src/applications/transactions/editfield/PhabricatorCommentEditField.php
+++ b/src/applications/transactions/editfield/PhabricatorCommentEditField.php
@@ -11,6 +11,10 @@
return new PhabricatorCommentEditType();
}
+ protected function newConduitParameterType() {
+ return new ConduitStringParameterType();
+ }
+
public function shouldGenerateTransactionsFromSubmit() {
return false;
}
diff --git a/src/applications/transactions/editfield/PhabricatorConduitEditField.php b/src/applications/transactions/editfield/PhabricatorConduitEditField.php
--- a/src/applications/transactions/editfield/PhabricatorConduitEditField.php
+++ b/src/applications/transactions/editfield/PhabricatorConduitEditField.php
@@ -11,4 +11,8 @@
return null;
}
+ protected function newConduitParameterType() {
+ return new ConduitWildParameterType();
+ }
+
}
diff --git a/src/applications/transactions/editfield/PhabricatorEditField.php b/src/applications/transactions/editfield/PhabricatorEditField.php
--- a/src/applications/transactions/editfield/PhabricatorEditField.php
+++ b/src/applications/transactions/editfield/PhabricatorEditField.php
@@ -12,10 +12,13 @@
private $object;
private $transactionType;
private $metadata = array();
- private $description;
private $editTypeKey;
private $isRequired;
+
+ private $description;
+ private $conduitDescription;
private $conduitDocumentation;
+ private $conduitTypeDescription;
private $commentActionLabel;
private $commentActionValue;
@@ -35,6 +38,8 @@
private $isCopyable = false;
private $isConduitOnly = false;
+ private $conduitEditTypes;
+
public function setKey($key) {
$this->key = $key;
return $this;
@@ -80,15 +85,6 @@
return $this->object;
}
- public function setDescription($description) {
- $this->description = $description;
- return $this;
- }
-
- public function getDescription() {
- return $this->description;
- }
-
public function setIsLocked($is_locked) {
$this->isLocked = $is_locked;
return $this;
@@ -125,6 +121,45 @@
return $this->isConduitOnly;
}
+ public function setDescription($description) {
+ $this->description = $description;
+ return $this;
+ }
+
+ public function getDescription() {
+ return $this->description;
+ }
+
+ public function setConduitDescription($conduit_description) {
+ $this->conduitDescription = $conduit_description;
+ return $this;
+ }
+
+ public function getConduitDescription() {
+ if ($this->conduitDescription === null) {
+ return $this->getDescription();
+ }
+ return $this->conduitDescription;
+ }
+
+ public function setConduitDocumentation($conduit_documentation) {
+ $this->conduitDocumentation = $conduit_documentation;
+ return $this;
+ }
+
+ public function getConduitDocumentation() {
+ return $this->conduitDocumentation;
+ }
+
+ public function setConduitTypeDescription($conduit_type_description) {
+ $this->conduitTypeDescription = $conduit_type_description;
+ return $this;
+ }
+
+ public function getConduitTypeDescription() {
+ return $this->conduitTypeDescription;
+ }
+
public function setIsEditDefaults($is_edit_defaults) {
$this->isEditDefaults = $is_edit_defaults;
return $this;
@@ -516,6 +551,20 @@
return new AphrontStringHTTPParameterType();
}
+ public function getConduitParameterType() {
+ $type = $this->newConduitParameterType();
+
+ if (!$type) {
+ return null;
+ }
+
+ $type->setViewer($this->getViewer());
+
+ return $type;
+ }
+
+ abstract protected function newConduitParameterType();
+
public function setEditTypeKey($edit_type_key) {
$this->editTypeKey = $edit_type_key;
return $this;
@@ -529,16 +578,13 @@
}
protected function newEditType() {
- // TODO: This could be a little cleaner.
- $http_type = $this->getHTTPParameterType();
- if ($http_type) {
- $value_type = $http_type->getTypeName();
- } else {
- $value_type = 'wild';
+ $parameter_type = $this->getConduitParameterType();
+ if (!$parameter_type) {
+ return null;
}
return id(new PhabricatorSimpleEditType())
- ->setValueType($value_type);
+ ->setConduitParameterType($parameter_type);
}
protected function getEditType() {
@@ -549,19 +595,49 @@
}
$type_key = $this->getEditTypeKey();
+ $edit_type = $this->newEditType();
+ if (!$edit_type) {
+ return null;
+ }
- return $this->newEditType()
+ return $edit_type
->setEditType($type_key)
->setTransactionType($transaction_type)
- ->setDescription($this->getDescription())
- ->setMetadata($this->getMetadata())
- ->setConduitDocumentation($this->getConduitDocumentation());
+ ->setMetadata($this->getMetadata());
+ }
+
+ final public function getConduitEditTypes() {
+ if ($this->conduitEditTypes === null) {
+ $edit_types = $this->newConduitEditTypes();
+ $edit_types = mpull($edit_types, null, 'getEditType');
+
+ foreach ($edit_types as $edit_type) {
+ $edit_type->setEditField($this);
+ }
+
+ $this->conduitEditTypes = $edit_types;
+ }
+
+ return $this->conduitEditTypes;
+ }
+
+ final public function getConduitEditType($key) {
+ $edit_types = $this->getConduitEditTypes();
+
+ if (empty($edit_types[$key])) {
+ throw new Exception(
+ pht(
+ 'This EditField does not provide a Conduit EditType with key "%s".',
+ $key));
+ }
+
+ return $edit_types[$key];
}
- public function getConduitEditTypes() {
+ protected function newConduitEditTypes() {
$edit_type = $this->getEditType();
- if ($edit_type === null) {
+ if (!$edit_type) {
return array();
}
@@ -679,13 +755,8 @@
return $edit_type->generateTransactions($template, $spec);
}
- public function setConduitDocumentation($conduit_documentation) {
- $this->conduitDocumentation = $conduit_documentation;
- return $this;
- }
- public function getConduitDocumentation() {
- return $this->conduitDocumentation;
- }
+
+
}
diff --git a/src/applications/transactions/editfield/PhabricatorInstructionsEditField.php b/src/applications/transactions/editfield/PhabricatorInstructionsEditField.php
--- a/src/applications/transactions/editfield/PhabricatorInstructionsEditField.php
+++ b/src/applications/transactions/editfield/PhabricatorInstructionsEditField.php
@@ -11,4 +11,8 @@
return null;
}
+ protected function newConduitParameterType() {
+ return null;
+ }
+
}
diff --git a/src/applications/transactions/editfield/PhabricatorPHIDListEditField.php b/src/applications/transactions/editfield/PhabricatorPHIDListEditField.php
--- a/src/applications/transactions/editfield/PhabricatorPHIDListEditField.php
+++ b/src/applications/transactions/editfield/PhabricatorPHIDListEditField.php
@@ -4,7 +4,6 @@
extends PhabricatorEditField {
private $useEdgeTransactions;
- private $transactionDescriptions = array();
private $isSingleValue;
public function setUseEdgeTransactions($use_edge_transactions) {
@@ -16,15 +15,6 @@
return $this->useEdgeTransactions;
}
- public function setEdgeTransactionDescriptions($add, $rem, $set) {
- $this->transactionDescriptions = array(
- '+' => $add,
- '-' => $rem,
- '=' => $set,
- );
- return $this;
- }
-
public function setSingleValue($value) {
if ($value === null) {
$value = array();
@@ -44,6 +34,10 @@
return new AphrontPHIDListHTTPParameterType();
}
+ protected function newConduitParameterType() {
+ return new ConduitPHIDListParameterType();
+ }
+
protected function getValueFromRequest(AphrontRequest $request, $key) {
$value = parent::getValueFromRequest($request, $key);
if ($this->getIsSingleValue()) {
@@ -105,9 +99,9 @@
return $type;
}
- public function getConduitEditTypes() {
+ protected function newConduitEditTypes() {
if (!$this->getUseEdgeTransactions()) {
- return parent::getConduitEditTypes();
+ return parent::newConduitEditTypes();
}
$transaction_type = $this->getTransactionType();
@@ -116,27 +110,26 @@
}
$type_key = $this->getEditTypeKey();
- $strings = $this->transactionDescriptions;
$base = $this->getEditType();
$add = id(clone $base)
->setEditType($type_key.'.add')
->setEdgeOperation('+')
- ->setDescription(idx($strings, '+'))
- ->setValueDescription(pht('List of PHIDs to add.'));
+ ->setConduitTypeDescription(pht('List of PHIDs to add.'))
+ ->setConduitParameterType($this->getConduitParameterType());
$rem = id(clone $base)
->setEditType($type_key.'.remove')
->setEdgeOperation('-')
- ->setDescription(idx($strings, '-'))
- ->setValueDescription(pht('List of PHIDs to remove.'));
+ ->setConduitTypeDescription(pht('List of PHIDs to remove.'))
+ ->setConduitParameterType($this->getConduitParameterType());
$set = id(clone $base)
->setEditType($type_key.'.set')
->setEdgeOperation('=')
- ->setDescription(idx($strings, '='))
- ->setValueDescription(pht('List of PHIDs to set.'));
+ ->setConduitTypeDescription(pht('List of PHIDs to set.'))
+ ->setConduitParameterType($this->getConduitParameterType());
return array(
$add,
diff --git a/src/applications/transactions/editfield/PhabricatorPolicyEditField.php b/src/applications/transactions/editfield/PhabricatorPolicyEditField.php
--- a/src/applications/transactions/editfield/PhabricatorPolicyEditField.php
+++ b/src/applications/transactions/editfield/PhabricatorPolicyEditField.php
@@ -55,4 +55,9 @@
return new AphrontPHIDHTTPParameterType();
}
+ protected function newConduitParameterType() {
+ return new ConduitStringParameterType();
+ }
+
+
}
diff --git a/src/applications/transactions/editfield/PhabricatorProjectsEditField.php b/src/applications/transactions/editfield/PhabricatorProjectsEditField.php
--- a/src/applications/transactions/editfield/PhabricatorProjectsEditField.php
+++ b/src/applications/transactions/editfield/PhabricatorProjectsEditField.php
@@ -11,4 +11,8 @@
return new AphrontProjectListHTTPParameterType();
}
+ protected function newConduitParameterType() {
+ return new ConduitProjectListParameterType();
+ }
+
}
diff --git a/src/applications/transactions/editfield/PhabricatorRemarkupEditField.php b/src/applications/transactions/editfield/PhabricatorRemarkupEditField.php
--- a/src/applications/transactions/editfield/PhabricatorRemarkupEditField.php
+++ b/src/applications/transactions/editfield/PhabricatorRemarkupEditField.php
@@ -7,4 +7,8 @@
return new PhabricatorRemarkupControl();
}
+ protected function newConduitParameterType() {
+ return new ConduitStringParameterType();
+ }
+
}
diff --git a/src/applications/transactions/editfield/PhabricatorSelectEditField.php b/src/applications/transactions/editfield/PhabricatorSelectEditField.php
--- a/src/applications/transactions/editfield/PhabricatorSelectEditField.php
+++ b/src/applications/transactions/editfield/PhabricatorSelectEditField.php
@@ -31,4 +31,8 @@
->setOptions($this->getOptions());
}
+ protected function newConduitParameterType() {
+ return new ConduitStringParameterType();
+ }
+
}
diff --git a/src/applications/transactions/editfield/PhabricatorSpaceEditField.php b/src/applications/transactions/editfield/PhabricatorSpaceEditField.php
--- a/src/applications/transactions/editfield/PhabricatorSpaceEditField.php
+++ b/src/applications/transactions/editfield/PhabricatorSpaceEditField.php
@@ -13,4 +13,8 @@
return new AphrontPHIDHTTPParameterType();
}
+ protected function newConduitParameterType() {
+ return new ConduitPHIDParameterType();
+ }
+
}
diff --git a/src/applications/transactions/editfield/PhabricatorSubscribersEditField.php b/src/applications/transactions/editfield/PhabricatorSubscribersEditField.php
--- a/src/applications/transactions/editfield/PhabricatorSubscribersEditField.php
+++ b/src/applications/transactions/editfield/PhabricatorSubscribersEditField.php
@@ -13,4 +13,8 @@
return new AphrontUserListHTTPParameterType();
}
+ protected function newConduitParameterType() {
+ return new ConduitUserListParameterType();
+ }
+
}
diff --git a/src/applications/transactions/editfield/PhabricatorTextAreaEditField.php b/src/applications/transactions/editfield/PhabricatorTextAreaEditField.php
--- a/src/applications/transactions/editfield/PhabricatorTextAreaEditField.php
+++ b/src/applications/transactions/editfield/PhabricatorTextAreaEditField.php
@@ -39,4 +39,8 @@
return $control;
}
+ protected function newConduitParameterType() {
+ return new ConduitStringParameterType();
+ }
+
}
diff --git a/src/applications/transactions/editfield/PhabricatorTextEditField.php b/src/applications/transactions/editfield/PhabricatorTextEditField.php
--- a/src/applications/transactions/editfield/PhabricatorTextEditField.php
+++ b/src/applications/transactions/editfield/PhabricatorTextEditField.php
@@ -7,4 +7,8 @@
return new AphrontFormTextControl();
}
+ protected function newConduitParameterType() {
+ return new ConduitStringParameterType();
+ }
+
}
diff --git a/src/applications/transactions/editfield/PhabricatorUsersEditField.php b/src/applications/transactions/editfield/PhabricatorUsersEditField.php
--- a/src/applications/transactions/editfield/PhabricatorUsersEditField.php
+++ b/src/applications/transactions/editfield/PhabricatorUsersEditField.php
@@ -11,4 +11,8 @@
return new AphrontUserListHTTPParameterType();
}
+ protected function newConduitParameterType() {
+ return new ConduitUserListParameterType();
+ }
+
}
diff --git a/src/applications/transactions/edittype/PhabricatorCommentEditType.php b/src/applications/transactions/edittype/PhabricatorCommentEditType.php
--- a/src/applications/transactions/edittype/PhabricatorCommentEditType.php
+++ b/src/applications/transactions/edittype/PhabricatorCommentEditType.php
@@ -2,8 +2,8 @@
final class PhabricatorCommentEditType extends PhabricatorEditType {
- public function getValueType() {
- return id(new AphrontStringHTTPParameterType())->getTypeName();
+ protected function newConduitParameterType() {
+ return new ConduitStringParameterType();
}
public function generateTransactions(
@@ -19,8 +19,4 @@
return array($xaction);
}
- public function getValueDescription() {
- return pht('Comment to add, formated as remarkup.');
- }
-
}
diff --git a/src/applications/transactions/edittype/PhabricatorEdgeEditType.php b/src/applications/transactions/edittype/PhabricatorEdgeEditType.php
--- a/src/applications/transactions/edittype/PhabricatorEdgeEditType.php
+++ b/src/applications/transactions/edittype/PhabricatorEdgeEditType.php
@@ -34,13 +34,4 @@
return array($xaction);
}
- public function setValueDescription($value_description) {
- $this->valueDescription = $value_description;
- return $this;
- }
-
- public function getValueDescription() {
- return $this->valueDescription;
- }
-
}
diff --git a/src/applications/transactions/edittype/PhabricatorEditType.php b/src/applications/transactions/edittype/PhabricatorEditType.php
--- a/src/applications/transactions/edittype/PhabricatorEditType.php
+++ b/src/applications/transactions/edittype/PhabricatorEditType.php
@@ -3,34 +3,16 @@
abstract class PhabricatorEditType extends Phobject {
private $editType;
+ private $editField;
private $transactionType;
private $label;
private $field;
- private $description;
- private $summary;
private $metadata = array();
- private $conduitDocumentation;
-
- public function setDescription($description) {
- $this->description = $description;
- return $this;
- }
-
- public function getDescription() {
- return $this->description;
- }
-
- public function setSummary($summary) {
- $this->summary = $summary;
- return $this;
- }
- public function getSummary() {
- if ($this->summary === null) {
- return $this->getDescription();
- }
- return $this->summary;
- }
+ private $conduitDescription;
+ private $conduitDocumentation;
+ private $conduitTypeDescription;
+ private $conduitParameterType;
public function setLabel($label) {
$this->label = $label;
@@ -59,15 +41,6 @@
return $this->editType;
}
- public function setConduitDocumentation($conduit_documentation) {
- $this->conduitDocumentation = $conduit_documentation;
- return $this;
- }
-
- public function getConduitDocumentation() {
- return $this->conduitDocumentation;
- }
-
public function setMetadata($metadata) {
$this->metadata = $metadata;
return $this;
@@ -90,9 +63,6 @@
PhabricatorApplicationTransaction $template,
array $spec);
- abstract public function getValueType();
- abstract public function getValueDescription();
-
protected function newTransaction(
PhabricatorApplicationTransaction $template) {
@@ -106,4 +76,83 @@
return $xaction;
}
+ public function setEditField(PhabricatorEditField $edit_field) {
+ $this->editField = $edit_field;
+ return $this;
+ }
+
+ public function getEditField() {
+ return $this->editField;
+ }
+
+/* -( Conduit )------------------------------------------------------------ */
+
+
+ protected function newConduitParameterType() {
+ if ($this->conduitParameterType) {
+ return clone $this->conduitParameterType;
+ }
+
+ return null;
+ }
+
+ public function setConduitParameterType(ConduitParameterType $type) {
+ $this->conduitParameterType = $type;
+ return $this;
+ }
+
+ public function getConduitParameterType() {
+ return $this->newConduitParameterType();
+ }
+
+ public function getConduitType() {
+ $parameter_type = $this->getConduitParameterType();
+ return $parameter_type->getTypeName();
+ }
+
+ public function setConduitTypeDescription($conduit_type_description) {
+ $this->conduitTypeDescription = $conduit_type_description;
+ return $this;
+ }
+
+ public function getConduitTypeDescription() {
+ if ($this->conduitTypeDescription === null) {
+ if ($this->getEditField()) {
+ return $this->getEditField()->getConduitTypeDescription();
+ }
+ }
+
+ return $this->conduitTypeDescription;
+ }
+
+ public function setConduitDescription($conduit_description) {
+ $this->conduitDescription = $conduit_description;
+ return $this;
+ }
+
+ public function getConduitDescription() {
+ if ($this->conduitDescription === null) {
+ if ($this->getEditField()) {
+ return $this->getEditField()->getConduitDescription();
+ }
+ }
+
+ return $this->conduitDescription;
+ }
+
+ public function setConduitDocumentation($conduit_documentation) {
+ $this->conduitDocumentation = $conduit_documentation;
+ return $this;
+ }
+
+ public function getConduitDocumentation() {
+ if ($this->conduitDocumentation === null) {
+ if ($this->getEditField()) {
+ return $this->getEditField()->getConduitDocumentation();
+ }
+ }
+
+ return $this->conduitDocumentation;
+ }
+
}
diff --git a/src/applications/transactions/edittype/PhabricatorPHIDListEditType.php b/src/applications/transactions/edittype/PhabricatorPHIDListEditType.php
--- a/src/applications/transactions/edittype/PhabricatorPHIDListEditType.php
+++ b/src/applications/transactions/edittype/PhabricatorPHIDListEditType.php
@@ -42,4 +42,17 @@
}
}
+ protected function newConduitParameterType() {
+ $default = parent::newConduitParameterType();
+ if ($default) {
+ return $default;
+ }
+
+ if ($this->getIsSingleValue()) {
+ return new ConduitPHIDParameterType();
+ } else {
+ return new ConduitPHIDListParameterType();
+ }
+ }
+
}
diff --git a/src/applications/transactions/edittype/PhabricatorSimpleEditType.php b/src/applications/transactions/edittype/PhabricatorSimpleEditType.php
--- a/src/applications/transactions/edittype/PhabricatorSimpleEditType.php
+++ b/src/applications/transactions/edittype/PhabricatorSimpleEditType.php
@@ -2,20 +2,6 @@
final class PhabricatorSimpleEditType extends PhabricatorEditType {
- private $valueType;
- private $valueDescription;
- private $phuixControlType;
- private $phuixControlSpecification = array();
-
- public function setValueType($value_type) {
- $this->valueType = $value_type;
- return $this;
- }
-
- public function getValueType() {
- return $this->valueType;
- }
-
public function generateTransactions(
PhabricatorApplicationTransaction $template,
array $spec) {
@@ -26,13 +12,4 @@
return array($edit);
}
- public function setValueDescription($value_description) {
- $this->valueDescription = $value_description;
- return $this;
- }
-
- public function getValueDescription() {
- return $this->valueDescription;
- }
-
}
diff --git a/src/infrastructure/customfield/editor/PhabricatorCustomFieldEditField.php b/src/infrastructure/customfield/editor/PhabricatorCustomFieldEditField.php
--- a/src/infrastructure/customfield/editor/PhabricatorCustomFieldEditField.php
+++ b/src/infrastructure/customfield/editor/PhabricatorCustomFieldEditField.php
@@ -5,6 +5,7 @@
private $customField;
private $httpParameterType;
+ private $conduitParameterType;
public function setCustomField(PhabricatorCustomField $custom_field) {
$this->customField = $custom_field;
@@ -25,6 +26,16 @@
return $this->httpParameterType;
}
+ public function setCustomFieldConduitParameterType(
+ ConduitParameterType $type) {
+ $this->conduitParameterType = $type;
+ return $this;
+ }
+
+ public function getCustomFieldConduitParameterType() {
+ return $this->conduitParameterType;
+ }
+
protected function buildControl() {
$field = $this->getCustomField();
$clone = clone $field;
@@ -36,14 +47,15 @@
}
protected function newEditType() {
- $type = id(new PhabricatorCustomFieldEditType())
- ->setCustomField($this->getCustomField());
-
- $http_type = $this->getHTTPParameterType();
- if ($http_type) {
- $type->setValueType($http_type->getTypeName());
+ $conduit_type = $this->newConduitParameterType();
+ if (!$conduit_type) {
+ return null;
}
+ $type = id(new PhabricatorCustomFieldEditType())
+ ->setCustomField($this->getCustomField())
+ ->setConduitParameterType($conduit_type);
+
return $type;
}
@@ -71,14 +83,14 @@
return $clone->getNewValueForApplicationTransactions();
}
- public function getConduitEditTypes() {
+ protected function newConduitEditTypes() {
$field = $this->getCustomField();
if (!$field->shouldAppearInConduitTransactions()) {
return array();
}
- return parent::getConduitEditTypes();
+ return parent::newConduitEditTypes();
}
protected function newHTTPParameterType() {
@@ -91,6 +103,16 @@
return null;
}
+ protected function newConduitParameterType() {
+ $type = $this->getCustomFieldConduitParameterType();
+
+ if ($type) {
+ return clone $type;
+ }
+
+ return null;
+ }
+
public function getAllReadValueFromRequestKeys() {
$keys = array();
diff --git a/src/infrastructure/customfield/editor/PhabricatorCustomFieldEditType.php b/src/infrastructure/customfield/editor/PhabricatorCustomFieldEditType.php
--- a/src/infrastructure/customfield/editor/PhabricatorCustomFieldEditType.php
+++ b/src/infrastructure/customfield/editor/PhabricatorCustomFieldEditType.php
@@ -4,7 +4,6 @@
extends PhabricatorEditType {
private $customField;
- private $valueType;
public function setCustomField(PhabricatorCustomField $custom_field) {
$this->customField = $custom_field;
@@ -15,25 +14,11 @@
return $this->customField;
}
- public function setValueType($value_type) {
- $this->valueType = $value_type;
- return $this;
- }
-
- public function getValueType() {
- return $this->valueType;
- }
-
public function getMetadata() {
$field = $this->getCustomField();
return parent::getMetadata() + $field->getApplicationTransactionMetadata();
}
- public function getValueDescription() {
- $field = $this->getCustomField();
- return $field->getFieldDescription();
- }
-
public function generateTransactions(
PhabricatorApplicationTransaction $template,
array $spec) {
diff --git a/src/infrastructure/customfield/field/PhabricatorCustomField.php b/src/infrastructure/customfield/field/PhabricatorCustomField.php
--- a/src/infrastructure/customfield/field/PhabricatorCustomField.php
+++ b/src/infrastructure/customfield/field/PhabricatorCustomField.php
@@ -1106,6 +1106,11 @@
$field->setCustomFieldHTTPParameterType($http_type);
}
+ $conduit_type = $this->getConduitEditParameterType();
+ if ($conduit_type) {
+ $field->setCustomFieldConduitParameterType($conduit_type);
+ }
+
return $field;
}
@@ -1348,6 +1353,17 @@
return null;
}
+ public function getConduitEditParameterType() {
+ return $this->newConduitEditParameterType();
+ }
+
+ protected function newConduitEditParameterType() {
+ if ($this->proxy) {
+ return $this->proxy->newConduitEditParameterType();
+ }
+ return null;
+ }
+
/* -( Herald )------------------------------------------------------------- */
diff --git a/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldBool.php b/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldBool.php
--- a/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldBool.php
+++ b/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldBool.php
@@ -136,4 +136,9 @@
protected function newConduitSearchParameterType() {
return new ConduitBoolParameterType();
}
+
+ protected function newConduitEditParameterType() {
+ return new ConduitBoolParameterType();
+ }
+
}
diff --git a/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldDate.php b/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldDate.php
--- a/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldDate.php
+++ b/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldDate.php
@@ -202,4 +202,8 @@
return null;
}
+ protected function newConduitEditParameterType() {
+ return new ConduitEpochParameterType();
+ }
+
}
diff --git a/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldInt.php b/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldInt.php
--- a/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldInt.php
+++ b/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldInt.php
@@ -120,4 +120,8 @@
return new ConduitIntParameterType();
}
+ protected function newConduitEditParameterType() {
+ return new ConduitIntParameterType();
+ }
+
}
diff --git a/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldLink.php b/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldLink.php
--- a/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldLink.php
+++ b/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldLink.php
@@ -87,4 +87,9 @@
protected function newConduitSearchParameterType() {
return new ConduitStringListParameterType();
}
+
+ protected function newConduitEditParameterType() {
+ return new ConduitStringParameterType();
+ }
+
}
diff --git a/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldSelect.php b/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldSelect.php
--- a/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldSelect.php
+++ b/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldSelect.php
@@ -143,4 +143,9 @@
protected function newConduitSearchParameterType() {
return new ConduitStringListParameterType();
}
+
+ protected function newConduitEditParameterType() {
+ return new ConduitStringParameterType();
+ }
+
}
diff --git a/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldUsers.php b/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldUsers.php
--- a/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldUsers.php
+++ b/src/infrastructure/customfield/standard/PhabricatorStandardCustomFieldUsers.php
@@ -19,4 +19,8 @@
return new ConduitUserListParameterType();
}
+ protected function newConduitEditParameterType() {
+ return new ConduitUserListParameterType();
+ }
+
}

File Metadata

Mime Type
text/plain
Expires
Fri, Oct 25, 6:41 PM (3 w, 3 d ago)
Storage Engine
amazon-s3
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
phabricator/secure/qd/tg/cp6ye6sciuabk4kn
Default Alt Text
D14796.diff (50 KB)

Event Timeline