2022-11-17 21:47:45 +01:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace App\Contribution\Documents;
|
|
|
|
|
|
|
|
use Zoomyboy\Tex\Document;
|
|
|
|
|
|
|
|
abstract class ContributionDocument extends Document
|
|
|
|
{
|
|
|
|
abstract public static function getName(): string;
|
2023-03-14 22:29:39 +01:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @return array<string, mixed>
|
|
|
|
*/
|
|
|
|
abstract public static function rules(): array;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @return array<string, mixed>
|
|
|
|
*/
|
|
|
|
public static function globalRules(): array
|
|
|
|
{
|
|
|
|
return [
|
|
|
|
'members' => 'present|array|min:1',
|
|
|
|
'members.*' => 'integer|exists:members,id',
|
|
|
|
];
|
|
|
|
}
|
2022-11-17 21:47:45 +01:00
|
|
|
}
|