PaymentController.php 555 B

1234567891011121314151617181920212223242526
  1. <?php
  2. namespace App\Http\Controllers\Client;
  3. use App\Http\Controllers\Controller;
  4. use App\Services\Client\PaymentService;
  5. use Illuminate\Http\Request;
  6. class PaymentController extends Controller
  7. {
  8. protected PaymentService $service;
  9. public function __construct(PaymentService $service)
  10. {
  11. $this->service = $service;
  12. }
  13. /**
  14. * 获取支付配置
  15. */
  16. public function getConfig(Request $request)
  17. {
  18. $orderId = $request->input('order_id');
  19. return $this->service->getPaymentConfig($orderId);
  20. }
  21. }