You are here

function uc_termsofservice_uc_cart_pane in Ubercart Terms of Service 7

Implements hook_uc_cart_pane().

File

./uc_termsofservice.module, line 63
Ubercart Terms of Service.

Code

function uc_termsofservice_uc_cart_pane($items) {
  $node = uc_termsofservice_get_node('cart');
  $title = t('Terms of Service');
  if (isset($node->title)) {
    $title = $node->title;
  }
  $panes[] = array(
    'id' => 'uc_termsofservice_agreement_cart',
    'title' => t('@title', array(
      '@title' => $title,
    )),
    'desc' => t("Please confirm if you agree with our terms and conditions that apply on all our purchases."),
    'weight' => 6,
    'body' => !is_null($items) ? drupal_get_form('uc_termsofservice_agreement_cart_callback', $items) : '',
  );
  return $panes;
}