Esempio n. 1
0
header_nocache();
if (!isset($_POST["id"])) {
    exit;
}
if (!isset($_REQUEST['glpi_tab'])) {
    exit;
}
if (!isset($_POST["withtemplate"])) {
    $_POST["withtemplate"] = "";
}
$budget = new Budget();
if ($_POST['id'] > 0 && $budget->can($_POST['id'], 'r')) {
    switch ($_REQUEST['glpi_tab']) {
        case -1:
            $budget->showValuesByEntity();
            $budget->showItems();
            Document::showAssociated($budget);
            Link::showForItem('Budget', $_POST["id"]);
            Plugin::displayAction($budget, $_REQUEST['glpi_tab'], $_POST["withtemplate"]);
            break;
        case 2:
            $budget->showItems();
            break;
        case 5:
            Document::showAssociated($budget);
            break;
        case 7:
            Link::showForItem('Budget', $_POST["id"]);
            break;
        case 10:
            showNotesForm($_POST['target'], 'Budget', $_POST["id"]);