You are here

function commerce_gc_coupon_properties in Commerce GC 7

File

./commerce_gc.module, line 1148
Provides Giftcard coupon bundle, Giftcard Transaction entity and basic user interface elements.

Code

function commerce_gc_coupon_properties($coupon, $options, $name) {
  switch ($name) {
    case 'giftcard_balance':
      $amount = commerce_gc_giftcard_balance($coupon->coupon_id);
      return array(
        'amount' => $amount,
        'currency_code' => commerce_default_currency(),
        'data' => array(),
      );
  }
}