<?php

namespace App\Command;
use App\Entity\Account;
use App\Service\FutTransferService;
use App\Service\NavisionDataImportService;
use App\Service\PriceService;
use Symfony\Component\Console\Attribute\AsCommand;
use Symfony\Component\Console\Command\Command;
use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Output\OutputInterface;
use Doctrine\ORM\EntityManagerInterface;

#[AsCommand(name: 'app:import-navision-data')]
class ImportNavisionDataCommand extends Command
{

    protected OutputInterface $output;

    public function __construct(
        private NavisionDataImportService $dataImportService
    ) {
        parent::__construct();
    }

    protected function configure(): void
    {
        $this
            ->setDescription('Import navision data.')
        ;
    }

    protected function initialize(InputInterface $input, OutputInterface $output): void
    {
    }

    protected function execute(InputInterface $input, OutputInterface $output): int
    {
        $this->dataImportService->importCustomers();
        $this->dataImportService->importSuppliers();
        $this->dataImportService->importProducts();


        return Command::SUCCESS;
    }

}