Sync.php 929 B

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. <?php
  2. namespace App\Http\Controllers\admin;
  3. use App\Http\Controllers\Controller;
  4. use App\Models\Collect;
  5. use App\Services\CollectService;
  6. use App\Services\RechargeService;
  7. use App\Services\RoomService;
  8. use App\Services\IssueService;
  9. class Sync extends Controller
  10. {
  11. public function collect()
  12. {
  13. CollectService::syncCollectStay();
  14. return $this->success();
  15. }
  16. public function recharge()
  17. {
  18. RechargeService::syncRechargeStay();
  19. return $this->success();
  20. }
  21. public function settle()
  22. {
  23. RoomService::noticeSettle();
  24. return $this->success();
  25. }
  26. public function five()
  27. {
  28. IssueService::syncCloseIssue(); // 同步停止
  29. // Log::error('✅ 获取到最新期号: ' . ($latestIssue ?? '无'));
  30. // 你的业务逻辑
  31. IssueService::getLatestIssue(); // 获取最新的期号
  32. return $this->success();
  33. }
  34. }