mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-23 05:50:55 +01:00
Add Conduit edit endpoint for Macro
Summary: Opens up the edit endpoint for Macros Test Plan: Review /conduit/method/macro.edit/ Reviewers: epriestley Reviewed By: epriestley Subscribers: Korvin Differential Revision: https://secure.phabricator.com/D17866
This commit is contained in:
parent
d39758ca7c
commit
bc4edc946b
3 changed files with 22 additions and 1 deletions
|
@ -1451,6 +1451,7 @@ phutil_register_library_map(array(
|
|||
'LiskRawMigrationIterator' => 'infrastructure/storage/lisk/LiskRawMigrationIterator.php',
|
||||
'MacroConduitAPIMethod' => 'applications/macro/conduit/MacroConduitAPIMethod.php',
|
||||
'MacroCreateMemeConduitAPIMethod' => 'applications/macro/conduit/MacroCreateMemeConduitAPIMethod.php',
|
||||
'MacroEditConduitAPIMethod' => 'applications/macro/conduit/MacroEditConduitAPIMethod.php',
|
||||
'MacroEmojiExample' => 'applications/uiexample/examples/MacroEmojiExample.php',
|
||||
'MacroQueryConduitAPIMethod' => 'applications/macro/conduit/MacroQueryConduitAPIMethod.php',
|
||||
'ManiphestAssignEmailCommand' => 'applications/maniphest/command/ManiphestAssignEmailCommand.php',
|
||||
|
@ -6479,6 +6480,7 @@ phutil_register_library_map(array(
|
|||
'LiskRawMigrationIterator' => 'PhutilBufferedIterator',
|
||||
'MacroConduitAPIMethod' => 'ConduitAPIMethod',
|
||||
'MacroCreateMemeConduitAPIMethod' => 'MacroConduitAPIMethod',
|
||||
'MacroEditConduitAPIMethod' => 'PhabricatorEditEngineAPIMethod',
|
||||
'MacroEmojiExample' => 'PhabricatorUIExample',
|
||||
'MacroQueryConduitAPIMethod' => 'MacroConduitAPIMethod',
|
||||
'ManiphestAssignEmailCommand' => 'ManiphestEmailCommand',
|
||||
|
|
19
src/applications/macro/conduit/MacroEditConduitAPIMethod.php
Normal file
19
src/applications/macro/conduit/MacroEditConduitAPIMethod.php
Normal file
|
@ -0,0 +1,19 @@
|
|||
<?php
|
||||
|
||||
final class MacroEditConduitAPIMethod
|
||||
extends PhabricatorEditEngineAPIMethod {
|
||||
|
||||
public function getAPIMethodName() {
|
||||
return 'macro.edit';
|
||||
}
|
||||
|
||||
public function newEditEngine() {
|
||||
return new PhabricatorMacroEditEngine();
|
||||
}
|
||||
|
||||
public function getMethodSummary() {
|
||||
return pht(
|
||||
'Apply transactions to create a new macro or edit an existing one.');
|
||||
}
|
||||
|
||||
}
|
|
@ -87,7 +87,7 @@ final class PhabricatorMacroEditEngine
|
|||
->setKey('name')
|
||||
->setLabel(pht('Name'))
|
||||
->setDescription(pht('Macro name.'))
|
||||
->setConduitDescription(pht('Rename the macro.'))
|
||||
->setConduitDescription(pht('Name of the macro.'))
|
||||
->setConduitTypeDescription(pht('New macro name.'))
|
||||
->setTransactionType(PhabricatorMacroNameTransaction::TRANSACTIONTYPE)
|
||||
->setIsRequired(true)
|
||||
|
|
Loading…
Reference in a new issue