Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
| Total | n/a |
0 / 0 |
n/a |
0 / 0 |
CRAP | n/a |
0 / 0 |
|||
| 1 | <?php |
| 2 | |
| 3 | namespace App\Http\Repositories\interfaces; |
| 4 | |
| 5 | use App\Http\Models\CompanyRolePlayScorecard; |
| 6 | use Illuminate\Support\Collection; |
| 7 | |
| 8 | /** |
| 9 | * Interface for company-level RolePlay scorecard data access. |
| 10 | */ |
| 11 | interface ICompanyRolePlayScorecardRepository |
| 12 | { |
| 13 | /** |
| 14 | * Get all scorecard configurations for a company, sorted by call_type. |
| 15 | * |
| 16 | * @return Collection<int, CompanyRolePlayScorecard> |
| 17 | */ |
| 18 | public function listForCompany(string $companyId): Collection; |
| 19 | |
| 20 | /** |
| 21 | * Find the scorecard configuration for a given company + call type. |
| 22 | */ |
| 23 | public function findForCompanyAndCallType(string $companyId, string $callType): ?CompanyRolePlayScorecard; |
| 24 | |
| 25 | /** |
| 26 | * Insert or update the scorecard for a given company + call type. |
| 27 | * |
| 28 | * @param array<string, mixed> $attributes |
| 29 | */ |
| 30 | public function upsertForCompanyAndCallType(string $companyId, string $callType, array $attributes): CompanyRolePlayScorecard; |
| 31 | |
| 32 | /** |
| 33 | * Delete the scorecard configuration for a given company + call type. |
| 34 | * Returns true if a record was deleted, false if none existed. |
| 35 | */ |
| 36 | public function deleteForCompanyAndCallType(string $companyId, string $callType): bool; |
| 37 | } |