. */ declare(strict_types=1); namespace FireflyIII\Http\Requests; /** * Class BudgetIncomeRequest. * * @codeCoverageIgnore */ class BudgetIncomeRequest extends Request { /** * Verify the request. * * @return bool */ public function authorize(): bool { // Only allow logged in users return auth()->check(); } /** * Rules for this request. * * @return array */ public function rules(): array { // fixed return [ 'amount' => 'numeric|required|min:0|max:1000000000', 'start' => 'required|date|before:end', 'end' => 'required|date|after:start', ]; } }