Beispiel #1
0
    $theperiod = $request->GetVar('frm_period', 'post');
} else {
    $actPeriod = $article->getactPeriod();
    $theperiod = $actPeriod['periodid'];
}
if ($request->GetVar('frm_action', 'post') == 'edit') {
    $smarty->assign('tpl_editid', $request->GetVar('frm_articleid', 'post'));
} elseif ($request->GetVar('frm_action', 'post') == 'addnew') {
    $smarty->assign('tpl_addnew', 'true');
} elseif ($request->GetVar('frm_action', 'post') == 'del') {
    $article->del($request->GetVar('frm_articleid', 'post'));
} elseif ($request->GetVar('frm_action', 'post') == 'new') {
    $check = $article->saveupdate();
} elseif ($request->GetVar('frm_action', 'post') == 'changeperiod') {
} elseif ($request->GetVar('frm_action', 'post') == 'saveupdatePeriod') {
    $theperiod = $article->saveupdatePeriod();
} elseif ($request->GetVar('frm_action', 'post') == 'newPeriod') {
    $theperiod = -1;
    $newperiod = 'true';
}
if ($request->GetVar('frm_thecat', 'post') !== $request->undefined) {
    $thecat = $request->GetVar('frm_thecat', 'post');
} else {
    $thecat = -1;
}
$smarty->assign('tpl_thecat', $thecat);
$smarty->assign('tpl_cat', $articlecat->getAll());
$smarty->assign('tpl_article', $article->getall(false, $theperiod, $thecat));
$smarty->assign('tpl_period', $article->getPeriod());
$smarty->assign('tpl_newPeriod', $newperiod);
$smarty->assign('tpl_theperiod', $theperiod);