public function SalesforceCommands::interactReadObject in Salesforce Suite 8.4
Same name and namespace in other branches
- 8.3 src/Commands/SalesforceCommands.php \Drupal\salesforce\Commands\SalesforceCommands::interactReadObject()
- 5.0.x src/Commands/SalesforceCommands.php \Drupal\salesforce\Commands\SalesforceCommands::interactReadObject()
Read a Salesforce ID interactively.
@hook interact salesforce:read-object
File
- src/
Commands/ SalesforceCommands.php, line 462
Class
- SalesforceCommands
- A Drush commandfile.
Namespace
Drupal\salesforce\CommandsCode
public function interactReadObject(Input $input, Output $output) {
if (!$input
->getArgument('id')) {
if (!($answer = $this
->io()
->ask('Enter the Salesforce id to fetch'))) {
throw new UserAbortException();
}
$input
->setArgument('id', $answer);
}
}