| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889 |
- <?php
- require_once("util.php");
- require_once("NTK/NTK.php");
- require_once("../DataBase/Product.php");
- require_once("../DataBase/Group.php");
- require_once("../DataBase/Priceset.php");
- require_once("../DataBase/Price.php");
- require_once("../DataBase/Category.php");
- require_once("../DataBase/Tax.php");
- require_once("../DataBase/Assistant.php");
- require_once("DataBase/Bill.php");
- require_once("DataBase/Bill_Product.php");
- $group = new Group();
- $priceset = new Priceset();
- $category = new Category();
- $product = new Product();
- $price = new Price();
- $tax = new Tax();
- $assistant = new Assistant();
- $bill = new Bill();
- if(var_post("print", "") == "print_re")
- {
- $search = "";
- if(var_post("product_id", ""))
- {
- if($search)
- $search .= " AND (product_id >=".var_post("product_id", "").") ";
- else
- $search .= "(product_id >=".var_post("product_id", "").") ";
- }
- if(var_post("date_from", ""))
- {
- if($search)
- $search .= " AND (date >='".var_post("date_from", "")."') ";
- else
- $search .= "(date >='".var_post("date_from", "")."') ";
- }
- if(var_post("date_to", ""))
- {
- if($search)
- $search .= " AND (date <='".var_post("date_to", "")."') ";
- else
- $search .= "(date <='".var_post("date_to", "")."') ";
- }
- $bill_data = $bill->get("", array("bill_id"), $search);
- $bill_product = new Bill_Product();
- $tour_data[1] = "( Alle Touren )";
- $product = new Product();
- $product_data = $product->get();
- include("Druckvorlagen/tour.php");
- }
- else
- {
- $toolbar_box = new NTKVBox("toolbar_box", 0, 0, False);
- $main_box = new NTKTable("main_box", 5, 4, False);
- $main_box->setStyle("background-color: #dfe7f3;");
- $main_box->add(new NTKLabel("", "<b>Rechnungszusammenfassung nach Datum</b>"), 0, 0);
- $main_box->add(new NTKLabel("", "Von:"), 2, 0);
- $main_box->add(new NTKEntry("date_from", ""), 2, 1);
- $main_box->add(new NTKLabel("", "Bis:"), 2, 2);
- $main_box->add(new NTKEntry("date_to", ""), 2, 3);
- $main_box->add(new NTKButton("submit", "Druckvorschau", "document.forms['print_re'].submit();"), 4, 3);
- $form = new NTKForm("print_re", "stat_bill_merge.php", $main_box);
- $form->addAttribute("print", "print_re");
- $toolbar_box->add($form, 0, 0);
- echo getHead();
- echo $toolbar_box->getHtml();
- }
- ?>
- </body>
- </html>
|