TestCommand.php 1000 B

12345678910111213141516171819202122232425262728293031323334353637
  1. <?php
  2. namespace app\command;
  3. use app\model\Member;
  4. use app\model\MemberAccount;
  5. use app\model\Order;
  6. use app\model\PayDetail;
  7. use support\Db;
  8. use Symfony\Component\Console\Command\Command;
  9. use Symfony\Component\Console\Input\InputArgument;
  10. use Symfony\Component\Console\Input\InputInterface;
  11. use Symfony\Component\Console\Output\OutputInterface;
  12. use Webman\Event\Event;
  13. class TestCommand extends Command
  14. {
  15. protected static $defaultName = 'TestCommand';
  16. protected static $defaultDescription = 'TestCommand Desc';
  17. /**
  18. * @return void
  19. */
  20. protected function configure()
  21. {
  22. // $this->addArgument('name', InputArgument::OPTIONAL, '余额账户转福利账户');
  23. $this->addArgument('name', InputArgument::OPTIONAL, '福利账户余额清空');
  24. }
  25. protected function execute(InputInterface $input, OutputInterface $output): int
  26. {
  27. Event::dispatch('order_pay.member_level.up','MR20240624091039F5HSLY');
  28. return self::SUCCESS;
  29. }
  30. }