<?php
/*
* @package LabCMS
* @copyright (c) 2006 Alexander Levin aka Loki (loki_angel@mail.ru)
* @support http://labcms.ru
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*/

	switch (true)
	{
		case ($_GET['action']=="add" && access('admin')):
			$mode="add";
			addBreadcrumb('Добавление правила');
			include dirname(__FILE__)."/edit.php";
		break;
		case ($_GET['action']=="edit" && access('admin')):
			$mode="edit";
			addBreadcrumb('Изменение правила');
			include dirname(__FILE__)."/edit.php";
		break;
		case ($_GET['action']=="delete" && access('admin')):
			$mode="delete";
			include dirname(__FILE__)."/edit.php";
		break;
		case ($_GET['action']=="toggle" && access('admin')):
			$mode="toggle";
			include dirname(__FILE__)."/edit.php";
		break;
		case ($_GET['action']=="up" && access('admin')):
			$mode="up";
			include dirname(__FILE__)."/edit.php";
		break;
		case ($_GET['action']=="down" && access('admin')):
			$mode="down";
			include dirname(__FILE__)."/edit.php";
		break;
		case (access('admin')):
			include dirname(__FILE__)."/list.php";
		break;
		default:
			LabCMS::i()->error403();
	}

