src/Controller/BotController.php line 21

Open in your IDE?
  1. <?php
  2. namespace App\Controller;
  3. use App\Repository\ItemRepository;
  4. use App\Service\BinanceApi;
  5. use App\Service\SlackSendingMessage;
  6. use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
  7. use Symfony\Component\HttpFoundation\Response;
  8. use Symfony\Component\Routing\Annotation\Route;
  9. class BotController extends AbstractController
  10. {
  11.     #[Route('/bot'name'app_bot')]
  12.     public function index(ItemRepository $itemRepositorySlackSendingMessage $sendingMessageBinanceApi $binanceApi): Response
  13.     {
  14.         $items $itemRepository->findAllItems();
  15.         $binance $binanceApi->binanceApiInfo($items$sendingMessage);
  16.         return $this->render('bot/index.html.twig', [
  17.             'text' => $binance,
  18.         ]);
  19.     }
  20. }