示例#1
0
 protected function getGatewayClass()
 {
     $alias = post('gateway_alias', $this->gatewayAlias);
     if ($this->gatewayClass !== null) {
         return $this->gatewayClass;
     }
     if (!($gateway = GatewayManager::instance()->findByAlias($alias))) {
         throw new Exception('Unable to find gateway with alias ' . $alias);
     }
     return $this->gatewayClass = $gateway->class;
 }
示例#2
0
<?php

Route::group(['prefix' => 'api_responsiv_pay'], function () {
    Route::any('{code}/{slug}', function ($code, $uri) {
        return \Responsiv\Pay\Classes\GatewayManager::runAccessPoint($code, $uri);
    })->where('slug', '(.*)?');
});