Open andrekutianski opened 2 years ago
I believe that I found the problem.
User's model miss the method paymentAccounts
:
public function paymentAccounts(): MorphOne
{
return $this->morphOne(PaymentAccount::class, 'accountable');
}
After add this to User
model file all looks good after create a new payment account.
{
"message": "Stripe account created successfully.",
"stripe_account_id": 1,
"_profiler": {
"__meta": {
"id": "Xa55be6ab35ca259aab0e04d50368256c",
"datetime": "2022-01-03 15:32:28",
"utime": 1641223948.320733,
"method": "POST",
"uri": "/v1/user/payments/accounts/stripe",
"ip": "192.168.0.1"
},
"messages": {
"count": 0,
"messages": []
},
}
I believe that I found the problem.
User's model miss the method
paymentAccounts
:public function paymentAccounts(): MorphOne { return $this->morphOne(PaymentAccount::class, 'accountable'); }
After add this to
User
model file all looks good after create a new payment account.{ "message": "Stripe account created successfully.", "stripe_account_id": 1, "_profiler": { "__meta": { "id": "Xa55be6ab35ca259aab0e04d50368256c", "datetime": "2022-01-03 15:32:28", "utime": 1641223948.320733, "method": "POST", "uri": "/v1/user/payments/accounts/stripe", "ip": "192.168.0.1" }, "messages": { "count": 0, "messages": [] }, }
This partially solve the problem, but I found more methods missing. I have a conclusion that the payment container is not fully operational.
This container is a very old container of apiato and we expect many functionalities not work properly or things missing! PRs are welcome for maintaining this useful container.
This container is a very old container of apiato and we expect many functionalities not work properly or things missing! PRs are welcome for maintaining this useful container.
on Apiato v11 the release notes say that the support to payment was drop off https://github.com/apiato/apiato/releases/tag/v11.0.0
Description:
I'm trying to create a stripe account but when the task try to execute the
AssignPaymentAccountToUserTask
class return error and not create payment account.Expected Behavior:
An associated payment account for stripe account submitted.
Versions:
Steps To Reproduce:
Make a
POST
to/user/payments/accounts/stripe
:Additional Context:
See https://github.com/apiato/payment-container/issues/1
The returned log message:
Request debugger info:
Laravel Log: