for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php namespace Arcanedev\LaravelTracker\Models;
use Arcanedev\Support\Bases\Model as BaseModel;
/**
* Class Model
*
* @package Arcanedev\LaravelTracker\Models
* @author ARCANEDEV <[email protected]>
*/
abstract class Model extends BaseModel
{
/* ------------------------------------------------------------------------------------------------
| Constructor
| ------------------------------------------------------------------------------------------------
* Create a new Eloquent model instance.
* @param array $attributes
public function __construct(array $attributes = [])
$this->setConnection($this->getConfig('database.connection', null))
->setPrefix($this->getConfig('database.prefix', 'tracker_'));
parent::__construct($attributes);
}
| Other Functions
* Get the tracker config.
* @param string $key
* @param mixed|null $default
* @return mixed
protected function getConfig($key, $default = null)
return config("laravel-tracker.$key", $default);