mirror of
https://github.com/netzmacht/contao-leaflet-maps.git
synced 2026-10-14 14:46:12 +02:00
Refactor the mappers to use the filters.
This commit is contained in:
1 parent
05d3acf21d
commit
37b10c14fe
26 files changed
+121
-133
No files matched your search
@@ -11,13 +11,13 @@
|
||||
|
||||
namespace Netzmacht\Contao\Leaflet\Mapper\UI;
|
||||
|
||||
use Netzmacht\Contao\Leaflet\Filter\Filter;
|
||||
use Netzmacht\Contao\Leaflet\Mapper\AbstractMapper;
|
||||
use Netzmacht\Contao\Leaflet\Mapper\DefinitionMapper;
|
||||
use Netzmacht\Contao\Leaflet\Model\IconModel;
|
||||
use Netzmacht\Contao\Leaflet\ServiceContainerTrait;
|
||||
use Netzmacht\LeafletPHP\Definition;
|
||||
use Netzmacht\LeafletPHP\Definition\Type\ImageIcon;
|
||||
use Netzmacht\LeafletPHP\Definition\Type\LatLngBounds;
|
||||
use Netzmacht\LeafletPHP\Definition\UI\Marker;
|
||||
|
||||
/**
|
||||
@@ -49,10 +49,10 @@ class MarkerMapper extends AbstractMapper
|
||||
protected function buildConstructArguments(
|
||||
\Model $model,
|
||||
DefinitionMapper $mapper,
|
||||
LatLngBounds $bounds = null,
|
||||
Filter $filter = null,
|
||||
$elementId = null
|
||||
) {
|
||||
$arguments = parent::buildConstructArguments($model, $mapper, $bounds, $elementId);
|
||||
$arguments = parent::buildConstructArguments($model, $mapper, $filter, $elementId);
|
||||
$arguments[] = $model->coordinates ?: null;
|
||||
|
||||
return $arguments;
|
||||
@@ -77,7 +77,7 @@ class MarkerMapper extends AbstractMapper
|
||||
Definition $definition,
|
||||
\Model $model,
|
||||
DefinitionMapper $mapper,
|
||||
LatLngBounds $bounds = null,
|
||||
Filter $filter = null,
|
||||
Definition $parent = null
|
||||
) {
|
||||
if ($definition instanceof Marker) {
|
||||
|
||||
Reference in new issue
Block a user