Example #1
0
<?php

include_once "modules/cashmgr/class_accounting.php";
$account = new accounting($auth['userid']);
$account->getAccounting();
?>
	
Example #2
0
 $totprice = 0;
 foreach ($_POST["action"] as $item => $val) {
     if ($_GET["status"] == 6 | $_GET["status"] == 7) {
         $db->qry("UPDATE %prefix%food_ordering SET status = %string%, lastchange = %string%, supplytime = %string%  WHERE id = %string%", $_GET["status"], $time, $time, $item);
         //sitzplan popup einbinden
         //change by jan für sitzplatz popup $item = id in food_ordering table
         //unit food_option (größe)
         $abfrage = $db->qry_first("SELECT %prefix%food_ordering.userid AS userid,%prefix%food_ordering.pice AS pice,unit, %prefix%food_product.caption AS caption, username, name, firstname\n\t\t\t\tFROM %prefix%food_ordering,%prefix%food_option, %prefix%food_product, %prefix%user\n\t\t\t\tWHERE %prefix%food_ordering.id = " . $item . " \n\t\t\t\tAND lastchange=" . $time . " \n\t\t\t\tAND supplytime=" . $time . " \n\t\t\t\tAND %prefix%food_product.id = %prefix%food_option.parentid \n\t\t\t\tAND %prefix%food_ordering.productid = %prefix%food_product.id\n\t\t\t\tAND %prefix%user.userid = %prefix%food_ordering.userid");
         //$dsp->AddDoubleRow('Ergebnis', $seat2->SeatOfUser($abfrage['userid'], 0, 2));
         $dsp->AddDoubleRow('Was -> Wohin', $abfrage['pice'] . ' x ' . $abfrage['caption'] . ' (' . $abfrage['unit'] . ') -> ' . $abfrage['username'] . ' (' . $abfrage['firstname'] . ' ' . $abfrage['name'] . ') ' . $seat2->SeatOfUser($abfrage['userid'], 0, 2));
         //change ende
     } elseif ($_GET["status"] == 8) {
         $totprice = 0;
         $prodrow = $db->qry_first("SELECT * FROM %prefix%food_ordering WHERE id = %string%", $item);
         unset($account);
         $account = new accounting($prodrow['userid']);
         $price = 0;
         $tempdesc = "";
         if (stristr($prodrow['opts'], "/")) {
             $values = explode("/", $prodrow['opts']);
             foreach ($values as $number) {
                 if (is_numeric($number)) {
                     $optrow = $db->qry_first("SELECT price, caption FROM %prefix%food_option WHERE id = %int%", $number);
                     $price += $optrow['price'];
                     $tempdesc .= $optrow['caption'];
                 }
             }
         } else {
             $optrow = $db->qry_first("SELECT price, caption FROM %prefix%food_option WHERE id = %int%", $prodrow['opts']);
             $price += $optrow['price'];
             $tempdesc .= $optrow['caption'];
Example #3
0
        default:
            $func->information("ACCESS_DENIED");
            break;
        case 1:
        case 2:
            $_GET['action'] = "myaccounting";
            break;
        case 3:
            $dia_quest[] .= t('Party Kalkulation');
            $dia_quest[] .= t('Fremder Kontoauszug');
            $dia_quest[] .= t('Eigener Kontoauszug');
            $dia_link[] .= "index.php?mod=cashmgr&action=show&step=1";
            $dia_link[] .= "index.php?mod=cashmgr&action=myaccounting&act=him";
            $dia_link[] .= "index.php?mod=cashmgr&action=myaccounting";
            $func->multiquestion($dia_quest, $dia_link, "");
            break;
    }
}
switch ($_GET['step']) {
    case 1:
        if ($auth['type'] < 3) {
            $func->information("ACCESS_DENIED");
        } else {
            $dsp->NewContent(t('Kalkulation'), t('Zur aktuellen Lanparty zum derzeitigen Stand'));
            $account = new accounting($party->party_id);
            $account->showCalculation();
        }
        break;
}
//$dsp->AddDoubleRow("Barausgaben insgesamt", $account->getCashTotalBudget());
//$dsp->AddDoubleRow("Guthaben insgesamt", $account->getOnlineTotalBudget());
Example #4
0
<?php

include_once "modules/cashmgr/class_accounting.php";
$dsp->NewContent(t('Kalkulation'), t('Zur aktuellen Lanparty zum derzeitigen Stand'));
$account = new accounting($party->party_id);
$account->booking(3, testbooking1, 3);
//$dsp->AddDoubleRow("Barausgaben insgesamt", $account->getCashTotalBudget());
//$dsp->AddDoubleRow("Guthaben insgesamt", $account->getOnlineTotalBudget());
Example #5
0
            case "2":
                $dsp->NewContent(t('Zahlungen'));
                $dsp->SetForm("index.php?mod=foodcenter&action=account&act=payment&step=3&userid=" . $_GET['userid']);
                $dsp->AddTextFieldRow("amount", t('Betrag'), $_POST['amount'], $error['amount']);
                $dsp->AddTextFieldRow("comment", t('Kommentar (Dein Name wird in Klammer angefügt)'), $_POST['comment'], $error['comment']);
                $dsp->AddFormSubmitRow(t('Abschicken'));
                $dsp->AddContent();
                $account = new accounting($_GET['userid']);
                $account->list_balance();
                break;
            case "3":
                $account = new accounting($_GET['userid']);
                $account->change($_POST['amount'], $_POST['comment'] . " (" . $auth['username'] . ")", $_GET['userid']);
                $account->list_balance();
                break;
        }
        break;
    case "himbalance":
        switch ($step) {
            default:
                $current_url = 'index.php?mod=foodcenter&action=account&act=himbalance';
                $target_url = 'index.php?mod=foodcenter&action=account&act=himbalance&step=2&userid=';
                include_once 'modules/usrmgr/search_basic_userselect.inc.php';
                break;
            case "2":
                $account = new accounting($_GET['userid']);
                $account->list_balance();
                break;
        }
        break;
}