update
This commit is contained in:
25
app/Repositories/CommentsRepository.php
Normal file
25
app/Repositories/CommentsRepository.php
Normal file
@ -0,0 +1,25 @@
|
||||
<?php
|
||||
|
||||
namespace App\Repositories;
|
||||
|
||||
use App\Models\Comments;
|
||||
use App\Repositories\CommentsInterface;
|
||||
|
||||
class CommentsRepository implements CommentsInterface
|
||||
{
|
||||
public function create(array $Details)
|
||||
{
|
||||
// dd($Details);
|
||||
return Comments::create($Details);
|
||||
}
|
||||
|
||||
public function update($commentId, array $Details)
|
||||
{
|
||||
return Comments::where('id', $commentId)->update($Details);
|
||||
}
|
||||
|
||||
public function delete($commentId)
|
||||
{
|
||||
return Comments::where('id', $commentId)->delete();
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user