public function StockServiceManager::listServiceIds in Commerce Stock 8
Returns an array of the IDs of all registered stock services.
Return value
array Array of the IDs of all registered stock services. Format is: array('service key' => 'service name')
Overrides StockServiceManagerInterface::listServiceIds
File
- src/
StockServiceManager.php, line 103
Class
- StockServiceManager
- The stock service manager.
Namespace
Drupal\commerce_stockCode
public function listServiceIds() {
$ids = [];
foreach ($this->stockServices as $service) {
$ids[$service
->getId()] = $service
->getName();
}
return $ids;
}