Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

toNestpayPaymentObject not found in the model #3

Open
bojmaliev opened this issue Feb 2, 2021 · 8 comments
Open

toNestpayPaymentObject not found in the model #3

bojmaliev opened this issue Feb 2, 2021 · 8 comments

Comments

@bojmaliev
Copy link

Here I faced an Exception because the method doesnt exists.

I simply passed the whole $unprocessedPaymentModel and is worked fine.

$merchantService->paymentProcessOverNestpayApi($unprocessedPaymentModel->toNestpayPaymentObject());

@donchoborisov
Copy link

Hi Bojan,
Did you managed to implement this with Laravel ?

@aleksandar-dimic
Copy link
Member

Hello Doncho,

The command and service provider need to be reorganized a bit, we are planning an upgrade to support Laravel 9 wich is LTS version, really soon. And going to fix all reported issues.

@aleksandar-dimic
Copy link
Member

As for the quick fix, just pass your model without calling ->toNestpayPaymentObject() method as Martin suggested earlier in the comments.

@donchoborisov
Copy link

Hi Aleksandar ,

Thank you very much for your response.

It will be nice also to show up some example with the controllers and etc.. looking forward for the update.

@aleksandar-dimic
Copy link
Member

Hello Doncho, there are stubs for controllers inside the package, you could publish them over command:
php artisan vendor:publish --provider="Cubes\Nestpay\Laravel\NestpayServiceProvider"

In the README.md there is a section "Laravel resources (config, controllers, views , etc)" and quick manual on how you could use published stubs.

@bojmaliev
Copy link
Author

Hi @donchoborisov,

No I didn't. But using this package logic I managed to write my own NestPayService class.

If you don't come up with a solution, mention me here I will share my code with you. (The working code is laravel version 8.12)

@donchoborisov
Copy link

Hi @bojmaliev thank you very much for your response. I did manage to get the code working but some small errors :) But yeah I would like to see your class if you are happy to share of course.

Thank you very much in advance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants