-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' of github.com:Tivix/laravel-tools into feature/ru…
…les-messages
- Loading branch information
Showing
8 changed files
with
78 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<?php | ||
|
||
namespace Kellton\Tools\Models; | ||
|
||
use Illuminate\Database\Eloquent\Model as EloquentModel; | ||
use Illuminate\Database\Query\Builder as QueryBuilder; | ||
use Kellton\Tools\Builders\Builder; | ||
use Kellton\Tools\Models\Traits\HasTableName; | ||
|
||
/** | ||
* ModelInterface handles the model interface. | ||
*/ | ||
interface ModelInterface | ||
{ | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
<?php | ||
|
||
namespace Kellton\Tools\Models; | ||
|
||
use Illuminate\Database\Eloquent\Relations\Pivot as EloquentPivot; | ||
use Illuminate\Database\Query\Builder as QueryBuilder; | ||
use Kellton\Tools\Builders\Builder; | ||
use Kellton\Tools\Models\Traits\HasTableName; | ||
|
||
/** | ||
* Class Pivot handles the base pivot model. | ||
*/ | ||
abstract class Pivot extends EloquentPivot implements ModelInterface | ||
{ | ||
use HasTableName; | ||
|
||
/** | ||
* Create a new Eloquent query builder for the model. | ||
* | ||
* @param QueryBuilder $query | ||
* | ||
* @return Builder | ||
*/ | ||
public function newEloquentBuilder($query): Builder | ||
{ | ||
return new Builder($query); | ||
} | ||
} |