migrate to gtea from bistbucket
This commit is contained in:
22
public/restaurant/app/Interfaces/CrudInterface.php
Normal file
22
public/restaurant/app/Interfaces/CrudInterface.php
Normal file
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
|
||||
namespace App\Interfaces;
|
||||
|
||||
use Illuminate\Contracts\Pagination\Paginator;
|
||||
|
||||
interface CrudInterface
|
||||
{
|
||||
public function getAll(array $filterData): Paginator;
|
||||
|
||||
public function getCount(): int;
|
||||
|
||||
public function getByColumn(string $columnName, $columnValue, array $selects = ['*']): ?object;
|
||||
|
||||
public function getById(int $id): ?object;
|
||||
|
||||
public function create(array $data);
|
||||
|
||||
public function update(int $id, array $data): ?object;
|
||||
|
||||
public function delete(int $id): ?object;
|
||||
}
|
||||
8
public/restaurant/app/Interfaces/DBPrepareInterface.php
Normal file
8
public/restaurant/app/Interfaces/DBPrepareInterface.php
Normal file
@@ -0,0 +1,8 @@
|
||||
<?php
|
||||
|
||||
namespace App\Interfaces;
|
||||
|
||||
interface DBPrepareInterface
|
||||
{
|
||||
public function prepareForDB(array $data): array;
|
||||
}
|
||||
14
public/restaurant/app/Interfaces/DropdownInterface.php
Normal file
14
public/restaurant/app/Interfaces/DropdownInterface.php
Normal file
@@ -0,0 +1,14 @@
|
||||
<?php
|
||||
|
||||
namespace App\Interfaces;
|
||||
|
||||
interface DropdownInterface
|
||||
{
|
||||
public function setTableName(string $tableName): self;
|
||||
|
||||
public function setPrimaryColumn(string $primaryColumn): self;
|
||||
|
||||
public function setSelectedColumns(array $selectedColumns): self;
|
||||
|
||||
public function getDropdowns(): array;
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
<?php
|
||||
|
||||
namespace App\Interfaces\Onboarding;
|
||||
|
||||
interface OnboardingInterface
|
||||
{
|
||||
public function index($request, int $per_page = 50);
|
||||
|
||||
public function getAll($request);
|
||||
|
||||
public function getById(int $id);
|
||||
|
||||
public function create(array $data);
|
||||
|
||||
public function update(int $id, array $data);
|
||||
|
||||
public function delete(int $id);
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
<?php
|
||||
|
||||
namespace App\Interfaces\Package;
|
||||
|
||||
interface PackageInterface
|
||||
{
|
||||
public function index($request, int $per_page = 50);
|
||||
|
||||
public function getAll($request);
|
||||
|
||||
public function getById(int $id);
|
||||
|
||||
public function create(array $data);
|
||||
|
||||
public function update(int $id, array $data);
|
||||
|
||||
public function delete(int $id);
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
<?php
|
||||
|
||||
namespace App\Interfaces\Restaurant;
|
||||
|
||||
interface RestaurantInterface
|
||||
{
|
||||
public function index($request, int $per_page = 50);
|
||||
|
||||
public function getAll($request);
|
||||
|
||||
public function getById(int $id);
|
||||
|
||||
public function create(array $data);
|
||||
|
||||
public function update(int $id, array $data);
|
||||
|
||||
public function delete(int $id);
|
||||
}
|
||||
Reference in New Issue
Block a user