This is the documentation for
v1.5 but the latest version is
v1.6
.
You can switch versions in the menu on the left/at the top.
Check your current version with the following command:
composer show mateusjunges/trackable-jobs-for-laravel
If, for some reason, you need to use your own custom model to the TrackedJob table, you can just create a new model
and extend the existing Junges\TrackableJobs\Models\TrackedJob::class
.
Then, you need to bind the Junges\TrackableJobs\Contracts\TrackableJobContract
to the new model, within your AppServiceProvider
:
<?php
namespace App\Providers;
use App\Models\YourCustomModel;
use Illuminate\Support\ServiceProvider;
use Junges\TrackableJobs\Contracts\TrackableJobContract;
class AppServiceProvider extends ServiceProvider
{
/**
* Register any application services.
*
* @return void
*/
public function register()
{
$this->app->bind(TrackableJobContract::class, YourCustomModel::class);
}
/**
* Bootstrap any application services.
*
* @return void
*/
public function boot()
{
//
}
}