我目前正在使用Silex(最新稳定版)建立一个我需要实施支付系统的网站。所以我试图安装Payum(最稳定的),一切正常,直到我打电话给准备页面,重定向到Payum捕获页面(/ payment / capture / hash of the request
),我得到了这个错误:
Request Capture{model: Identity} is not supported.
对于安装,我已按照官方指南:http://payum.org/doc/1.0/PayumSilexProvider/get-it-started
我还尝试过所有其他版本的Payum,但没有成功。
以下是错误的痕迹:
in RequestNotSupportedException.php line 29
at RequestNotSupportedException::create(object(Capture)) in Gateway.php line 99
at Gateway->execute(object(Capture)) in ExecuteSameRequestWithModelDetailsAction.php line 32
at ExecuteSameRequestWithModelDetailsAction->execute(object(Capture)) in Gateway.php line 107
at Gateway->execute(object(Capture)) in CaptureController.php line 20
at CaptureController->doAction(object(Request))
at call_user_func_array(array(object(CaptureController), 'doAction'), array(object(Request))) in HttpKernel.php line 147
at HttpKernel->handleRaw(object(Request), '1') in HttpKernel.php line 68
at HttpKernel->handle(object(Request), '1', true) in Application.php line 586
at Application->handle(object(Request)) in Application.php line 563
at Application->run() in app_dev.php line 12
如果有人可以帮助我,那将是我的一天! :)
提前致谢
答案 0 :(得分:2)
好的,我已经找到了答案,感谢github和Payum Silex创作者@makasim :) https://github.com/Payum/Payum/issues/423#issuecomment-150948591
只需添加:
<?php
$gateways['paypal_ec']->addExtension(new StorageExtension(
new FilesystemStorage(__DIR__.'/cache/payum', 'Payum\Core\Model\Payment')
));
在网关注册!