Subversion-Projekte lars-tiefland.inventar

Revision

Revision 7 | Revision 20 | Zur aktuellen Revision | Blame | Vergleich mit vorheriger | Letzte Änderung | Log anzeigen | RSS feed

<?php

        //$Id: index.php 14 2008-05-15 18:19:36Z lars $
        
        /**
         * @package     Inventar Datenbank
         * @author Lars Tiefland <ltiefland@gmail.com>
         * @copyright 2008
         **/

        require_once("include/common.php");
        
        switch($_POST["mode"])
        {
                case "details";
                        $tpl_f="details.tpl";
                        $s=new comp($_POST["id"]);
                        $comp=$s->toArray();
                        $smarty->assign("comp",$comp);
                break;
                case "edit":
                        $tpl_f="edit.tpl";
                break;
                case "del":
                        $tpl_f="del.tpl";
                break;
                default:
                        $tpl_f="index.tpl";
                        $comp=comp::get_computers();
                        $smarty->assign("list",$comp);
                break;
        }
        
        $smarty->display($tpl_f);

?>