function payment_commerce_pids_load in Payment for Drupal Commerce 7.2
Same name and namespace in other branches
- 7 payment_commerce.module \payment_commerce_pids_load()
Load the PIDs for all payments belonging to a Commerce order.
Parameters
integer $order_id:
Return value
array
6 calls to payment_commerce_pids_load()
- PaymentCommerceCheckoutWebTestCase::assertCheckout in tests/
PaymentCommerceCheckoutWebTestCase.test - Executes the checkout process.
- PaymentCommerceCheckoutWebTestCase::assertPaymentExists in tests/
PaymentCommerceCheckoutWebTestCase.test - Tests that a payment exists.
- payment_commerce_commerce_order_delete in ./
payment_commerce.module - Implements hook_ENTITY_TYPE_ACTION().
- payment_commerce_commerce_order_update in ./
payment_commerce.module - Implements hook_ENTITY_TYPE_ACTION().
- payment_commerce_redirect_form in ./
payment_commerce.module - Implements CALLBACK_commerce_payment_method_redirect_form().
File
- ./
payment_commerce.module, line 203 - Hook implementations and shared functions.
Code
function payment_commerce_pids_load($order_id) {
return db_query("SELECT pid FROM {payment_commerce} pc LEFT JOIN {commerce_payment_transaction} cpt ON pc.transaction_id = cpt.transaction_id WHERE order_id = :order_id ORDER BY pid DESC", array(
':order_id' => $order_id,
))
->fetchCol();
}