first commit
This commit is contained in:
@ -0,0 +1,35 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Office\Repositories;
|
||||
|
||||
use Modules\Office\Models\GeneratorLogBook;
|
||||
|
||||
|
||||
class GeneratorLogBookRepository implements GeneratorLogBookInterface
|
||||
{
|
||||
public function findAll()
|
||||
{
|
||||
return GeneratorLogBook::get();
|
||||
}
|
||||
|
||||
public function getGeneratorLogBookById($generatorLogBookId)
|
||||
{
|
||||
return GeneratorLogBook::findOrFail($generatorLogBookId);
|
||||
}
|
||||
|
||||
public function delete($generatorLogBookId)
|
||||
{
|
||||
GeneratorLogBook::destroy($generatorLogBookId);
|
||||
}
|
||||
|
||||
public function create(array $generatorLogBookDetails)
|
||||
{
|
||||
return GeneratorLogBook::create($generatorLogBookDetails);
|
||||
}
|
||||
|
||||
public function update($generatorLogBookId, array $newDetails)
|
||||
{
|
||||
return GeneratorLogBook::where('id', $generatorLogBookId)->update($newDetails);
|
||||
}
|
||||
|
||||
}
|
Reference in New Issue
Block a user