Skip to content

Commit

Permalink
Merge pull request #992 from teklakct/master
Browse files Browse the repository at this point in the history
Typo fix in prepareColumnValues typings
  • Loading branch information
DonCallisto authored Jan 22, 2018
2 parents 62c78d9 + 155f696 commit b8e6902
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 8 deletions.
7 changes: 7 additions & 0 deletions Grid/Exception/PropertyAccessDeniedException.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?php

namespace APY\DataGridBundle\Grid\Exception;

class PropertyAccessDeniedException extends \RuntimeException
{
}
16 changes: 8 additions & 8 deletions Grid/Source/Source.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@
namespace APY\DataGridBundle\Grid\Source;

use APY\DataGridBundle\Grid\Column\Column;
use APY\DataGridBundle\Grid\Exception\PropertyAccessDeniedException;
use APY\DataGridBundle\Grid\Helper\ColumnsIterator;
use APY\DataGridBundle\Grid\Mapping\Driver\DriverInterface;
use APY\DataGridBundle\Grid\Row;
use APY\DataGridBundle\Grid\Rows;
use Symfony\Component\Form\Exception\PropertyAccessDeniedException;

abstract class Source implements DriverInterface
{
Expand Down Expand Up @@ -217,7 +217,7 @@ protected function getItemsFromData($columns)
|| is_callable([$itemEntity, $fullFunctionName = 'is' . $functionName])) {
$fieldValue = call_user_func([$itemEntity, $fullFunctionName]);
} else {
throw new PropertyAccessDeniedExceptio(sprintf('Property "%s" is not public or has no accessor.', $fieldName));
throw new PropertyAccessDeniedException(sprintf('Property "%s" is not public or has no accessor.', $fieldName));
}
} elseif (isset($item[$fieldName])) {
$fieldValue = $item[$fieldName];
Expand All @@ -233,10 +233,10 @@ protected function getItemsFromData($columns)
/**
* Find data from array|object.
*
* @param \APY\DataGridBundle\Grid\Column\Column[] $columns
* @param int $page
* @param int $limit
* @param int $maxResults
* @param Column[] $columns
* @param int $page
* @param int $limit
* @param int $maxResults
*
* @return Rows
*/
Expand Down Expand Up @@ -471,7 +471,7 @@ public function executeFromData($columns, $page = 0, $limit = 0, $maxResults = n

public function populateSelectFiltersFromData($columns, $loop = false)
{
/* @var $column Column\Column */
/* @var $column Column */
foreach ($columns as $column) {
$selectFrom = $column->getSelectFrom();

Expand Down Expand Up @@ -582,7 +582,7 @@ private function removeAccents($str)
return preg_replace('#&([A-za-z]{2})(?:lig);#', '\1', $noaccentStr);
}

protected function prepareColumnValues(Column\Column $column, $values)
protected function prepareColumnValues(Column $column, $values)
{
$existingValues = $column->getValues();
if (!empty($existingValues)) {
Expand Down

0 comments on commit b8e6902

Please sign in to comment.