Skip to content

Commit

Permalink
validation scope filter
Browse files Browse the repository at this point in the history
  • Loading branch information
Ivorius committed Dec 21, 2021
1 parent aaf6afd commit 15a9e71
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/DataGrid.php
Original file line number Diff line number Diff line change
Expand Up @@ -1400,7 +1400,7 @@ public function createComponentFilter(): Form
}

if (!$this->hasAutoSubmit()) {
$filterContainer['submit'] = $this->getFilterSubmitButton();
$filterContainer['submit'] = $this->getFilterSubmitButton()->setValidationScope([$filterContainer]);
}

/**
Expand Down
4 changes: 2 additions & 2 deletions src/Filter/SubmitButton.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

namespace Ublaboo\DataGrid\Filter;

use Nette\Forms\Controls\Button;
use Nette\Forms\Controls\SubmitButton as NetteSubmitButton;
use Nette\Utils\Html;
use Ublaboo\DataGrid\DataGrid;
use Ublaboo\DataGrid\Traits\TButtonClass;
Expand All @@ -13,7 +13,7 @@
use Ublaboo\DataGrid\Traits\TButtonTitle;
use Ublaboo\DataGrid\Traits\TButtonTryAddIcon;

class SubmitButton extends Button
class SubmitButton extends NetteSubmitButton
{

use TButtonTryAddIcon;
Expand Down

0 comments on commit 15a9e71

Please sign in to comment.