public function Payment::getState in Commerce Core 8.2
Gets the payment state.
Return value
\Drupal\state_machine\Plugin\Field\FieldType\StateItemInterface The payment state.
Overrides PaymentInterface::getState
File
- modules/
payment/ src/ Entity/ Payment.php, line 245
Class
- Payment
- Defines the payment entity class.
Namespace
Drupal\commerce_payment\EntityCode
public function getState() {
return $this
->get('state')
->first();
}