Archived
feat: request quotes
This commit is contained in:
1 parent
1833146158
commit
fb679c3042
3 files changed
+42
-2
No files matched your search
@@ -9,6 +9,11 @@ class Quote extends Model
|
||||
{
|
||||
use SoftDeletes;
|
||||
|
||||
public function request()
|
||||
{
|
||||
// Send the notification
|
||||
// If success, add it to the transactions
|
||||
}
|
||||
protected $fillable = [
|
||||
'quote',
|
||||
];
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
<?php
|
||||
|
||||
namespace App\Policies;
|
||||
|
||||
use App\Models\Quote;
|
||||
use App\Models\User;
|
||||
use Illuminate\Auth\Access\HandlesAuthorization;
|
||||
|
||||
class QuotePolicy
|
||||
{
|
||||
use HandlesAuthorization;
|
||||
|
||||
public function request(): bool
|
||||
{
|
||||
return !empty(auth()->user());
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user