skip to Main Content

Laravel – Resource Controller in edit not having data

my link to edit <a href="/dashboard/rejected/{{ $reject->id }}/edit" class="badge bg-danger">{{ $reject->status }}</a> my route Route::resource('/dashboard/rejected', RejectController::class); my controller public function edit(Reject $reject) { dd($reject); return view('dashboard.reject.edit',[ 'tittle' => 'Reject Stock', 'reject' => $reject ]); } $reject on my controller is…

VIEW QUESTION

Laravel Service Container Binding Primitives Not Working For Mailchimp

We have the following binding Primitives use NZTimMailchimpMailchimp; use ReCaptchaReCaptcha; class AppServiceProvider extends ServiceProvider { /** * Register any application services. */ public function register(): void { app()->when(Mailchimp::class) ->needs('$apikey') ->give(config('services.mailchimp.apikey')); app()->when(ReCaptcha::class) ->needs('$secret') ->give(config('services.recaptcha.secret')); } } Recaptcha is working. But with…

VIEW QUESTION

Laravel Eloquent add a WHERE xy IS NULL condition

I use Laravel 10. I try to fetch some data from my mariaDB with the following condition. $contentList = $this->get(); foreach($contentList as $content){ $this->product()->where('id', '=', $content->content_product_id)->ddRawSql(); } But the query I get is: select * from `radio_content_products` where `radio_content_products`.`id` is…

VIEW QUESTION

Is there a good way to remove the "next" and "prev" links from Laravel Paginate API, other than removing it in the frontend?

My response looks like this: "links": { "first": "http://localhost:8000/api/tasks?page=1", "last": "http://localhost:8000/api/tasks?page=200", "prev": null, "next": "http://localhost:8000/api/tasks?page=2" }, "meta": { "current_page": 1, "from": 1, "last_page": 200, "links": [ { "url": null, "label": "&laquo; Previous", "active": false }, { "url": "http://localhost:8000/api/tasks?page=1", "label": "1",…

VIEW QUESTION
Back To Top
Search