interface ReportTypeInterface in Commerce Reporting 8
Defines the interface for order report types.
Hierarchy
- interface \Drupal\Component\Plugin\PluginInspectionInterface
- interface \Drupal\entity\BundlePlugin\BundlePluginInterface
- interface \Drupal\commerce_reports\Plugin\Commerce\ReportType\ReportTypeInterface
- interface \Drupal\entity\BundlePlugin\BundlePluginInterface
Expanded class hierarchy of ReportTypeInterface
All classes that implement ReportTypeInterface
1 file declares its use of ReportTypeInterface
File
- src/
Plugin/ Commerce/ ReportType/ ReportTypeInterface.php, line 12
Namespace
Drupal\commerce_reports\Plugin\Commerce\ReportTypeView source
interface ReportTypeInterface extends BundlePluginInterface {
/**
* Gets the order report type label.
*
* @return string
* The order report type label.
*/
public function getLabel();
/**
* Gets the order report type description.
*
* @return string
* The order report type description.
*/
public function getDescription();
/**
* Builds the aggregate query.
*
* Report type plugins should add their field columns, aggregates, and
* groupBy statements here.
*
* @param \Drupal\Core\Entity\Query\QueryAggregateInterface $query
* The aggregate query.
*/
public function buildQuery(QueryAggregateInterface $query);
/**
* Build a report table from query results.
*
* @param array $results
* The report query results.
*
* @return array
* The render array.
*/
public function buildReportTable(array $results);
/**
* Generates order reports for an order.
*
* @param \Drupal\commerce_order\Entity\OrderInterface $order
* The order.
*/
public function generateReports(OrderInterface $order);
/**
* Creates a new order report using the given order and values.
*
* @param \Drupal\commerce_order\Entity\OrderInterface $order
* The order.
* @param array $values
* (optional) An array of values to set, keyed by property name.
*/
public function createFromOrder(OrderInterface $order, array $values = []);
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
BundlePluginInterface:: |
public | function | Builds the field definitions for entities of this bundle. | 2 |
PluginInspectionInterface:: |
public | function | Gets the definition of the plugin implementation. | 4 |
PluginInspectionInterface:: |
public | function | Gets the plugin_id of the plugin instance. | 2 |
ReportTypeInterface:: |
public | function | Builds the aggregate query. | 4 |
ReportTypeInterface:: |
public | function | Build a report table from query results. | 1 |
ReportTypeInterface:: |
public | function | Creates a new order report using the given order and values. | 1 |
ReportTypeInterface:: |
public | function | Generates order reports for an order. | 4 |
ReportTypeInterface:: |
public | function | Gets the order report type description. | 1 |
ReportTypeInterface:: |
public | function | Gets the order report type label. | 1 |