示例#1
0
<?php

require_once "core.php";
if (array_key_exists('step', $_GET)) {
    $step = $_GET['step'];
} else {
    $step = "One";
    $_SESSION['dp'] = new dp();
}
$activeMenu = "active";
switch ($step) {
    case "One":
        $dpSituations = Dp::getAllSituations();
        $dpActors = Dp::getAllActors();
        $dpCategories = Dp::getAllCategories();
        $dpSystems = Dp::getAllSystems();
        $smarty->assign('dpName', $_SESSION['dp']->getName());
        $smarty->assign('dpAbstract', $_SESSION['dp']->getAbstract());
        $smarty->assign('dpDesc', $_SESSION['dp']->getDescription());
        $smarty->assign('situations', $dpSituations);
        $smarty->assign('actors', $dpActors);
        $smarty->assign('categories', $dpCategories);
        $smarty->assign('systems', $dpSystems);
        $smarty->assign('one', $activeMenu);
        break;
    case "Two":
        $trackingFocus = Dp::getAllTrackingFocus();
        $smarty->assign('dpProblem', $_SESSION['dp']->getProblem());
        $smarty->assign('dpAnalysis', $_SESSION['dp']->getAnalysis());
        $smarty->assign('trackingFocus', $trackingFocus);
        $smarty->assign('two', $activeMenu);