Ask, reply and learn. Join the community of Akaunting.
I was able to update. In the folder app/http/requests/common/company (I think that with the others models, is the same change), change:
//use Illuminate\Foundation\Http\FormRequest;
use Dingo\Api\Http\FormRequest;
However, I think that it will be a problem, because I change core files, so, not should be considerate a complete solution, with the next update, that file could be replaced. The problem still there.
Hi Jerry, did you find the solution for this? Do let me know, if you have. Thank you.
Hi Kalpesh, I did not fix it.
So if anyone has, please let me know too!
Same issue here. Looks like the create returns a view instead of a JSON string. Looking at the code I see:
public function store(Request $request)
{
$invoice = $this->dispatch(new CreateInvoice($request));
return $this->response->created(route('api.invoices.show', $invoice->id));
}
I changed the return to the same as the show function
return $this->response->item($invoice, new Transformer());
and then it works
Showing 11 to 14 of 14 discussions