Ejemplo n.º 1
0
        exit;
    }
} elseif ($action == 'delbookkeepingyearconfirm') {
    $delyear = GETPOST('delyear', 'int');
    if (!empty($delyear)) {
        $result = $object->deleteByYear($delyear);
        if ($result < 0) {
            setEventMessages($object->error, $object->errors, 'errors');
        }
        Header("Location: list.php");
        exit;
    }
} elseif ($action == 'delmouvconfirm') {
    $mvt_num = GETPOST('mvt_num', 'int');
    if (!empty($mvt_num)) {
        $result = $object->deleteMvtNum($mvt_num);
        if ($result < 0) {
            setEventMessages($object->error, $object->errors, 'errors');
        }
        // if (!empty($options)) {
        // Header("Location: list.php?".urldecode($options));
        // } else {
        Header("Location: list.php");
        // }
        exit;
    }
} elseif ($action == 'export_csv') {
    $sep = $conf->global->ACCOUNTING_EXPORT_SEPARATORCSV;
    $journal = 'bookkepping';
    include DOL_DOCUMENT_ROOT . '/accountancy/tpl/export_journal.tpl.php';
    $result = $object->fetchAll($sortorder, $sortfield, 0, 0, $filter);