You are here

function uc_taxes_delete_submit in Ubercart 5

Submit handler for uc_taxes_delete().

File

uc_taxes/uc_taxes.module, line 321

Code

function uc_taxes_delete_submit($form_id, $form_values) {
  if ($form_values['confirm']) {
    db_query("DELETE FROM {uc_taxes} WHERE id = %d", $form_values['id']);
    db_query("DELETE FROM {workflow_ng_cfgs} WHERE name = '%s'", 'uc_taxes_' . $form_values['id']);
    workflow_ng_clear_cache();
  }
  drupal_set_message(t('Tax rule deleted.'));
  return 'admin/store/settings/taxes';
}