categoryType = Shop::CATEGORY_SALE_ITEMS; } elseif ($_GET['otdel'] === 'market') { Shop::id(Shop::GENERAL_SHOP)->categoryType = Shop::BARTER_SHOP; } else { Shop::id(Shop::GENERAL_SHOP)->categoryType = $_GET['otdel']; } } if (!empty($_POST['sellshop'])) { ShopItem::sellItem($_POST['itemId'], 1); } if (!empty($_POST['buyshop'])) { ShopItem::buyItem($_POST['itemId']); } if (!empty($_POST['buymarket'])) { ShopItem::$status = 'попытка купить с рук предмет id: ' . $_POST['itemId']; } require_once 'views/shop.php';