You are here

function uc_cart_block_configure in Ubercart 7.3

Implements hook_block_configure().

Builds the settings form used by the shopping cart block.

File

uc_cart/uc_cart.module, line 393

Code

function uc_cart_block_configure($delta = '') {
  if ($delta == 'cart') {
    $form['uc_cart_block_empty_hide'] = array(
      '#type' => 'checkbox',
      '#title' => t('Hide block if cart is empty.'),
      '#default_value' => variable_get('uc_cart_block_empty_hide', FALSE),
    );
    $form['uc_cart_block_image'] = array(
      '#type' => 'checkbox',
      '#title' => t('Display the shopping cart icon in the block title.'),
      '#default_value' => variable_get('uc_cart_block_image', TRUE),
    );
    $form['uc_cart_block_collapsible'] = array(
      '#type' => 'checkbox',
      '#title' => t('Make the shopping cart block collapsible by clicking the name or arrow.'),
      '#default_value' => variable_get('uc_cart_block_collapsible', TRUE),
    );
    $form['uc_cart_block_collapsed'] = array(
      '#type' => 'checkbox',
      '#title' => t('Display the shopping cart block collapsed by default.'),
      '#default_value' => variable_get('uc_cart_block_collapsed', TRUE),
    );
    $form['uc_cart_show_help_text'] = array(
      '#type' => 'checkbox',
      '#title' => t('Display small help text in the shopping cart block.'),
      '#default_value' => variable_get('uc_cart_show_help_text', FALSE),
    );
    return $form;
  }
}