Example #1
0
 public static function execute(ApplicationAbstract $application)
 {
     if (TaxClasses::deleteEntry($_GET['rID'])) {
         Registry::get('MessageStack')->add(null, OSCOM::getDef('ms_success_action_performed'), 'success');
     } else {
         Registry::get('MessageStack')->add(null, OSCOM::getDef('ms_error_action_not_performed'), 'error');
     }
     osc_redirect_admin(OSCOM::getLink(null, null, 'id=' . $_GET['id']));
 }
Example #2
0
 public static function execute(ApplicationAbstract $application)
 {
     $error = false;
     foreach ($_POST['batch'] as $id) {
         if (!TaxClasses::deleteEntry($id)) {
             $error = true;
             break;
         }
     }
     if ($error === false) {
         Registry::get('MessageStack')->add(null, OSCOM::getDef('ms_success_action_performed'), 'success');
     } else {
         Registry::get('MessageStack')->add(null, OSCOM::getDef('ms_error_action_not_performed'), 'error');
     }
     OSCOM::redirect(OSCOM::getLink(null, null, 'id=' . $_GET['id']));
 }