Add more controls.

This commit is contained in:
David Molineus committed 2015-01-05 14:58:37 +01:00
1 parent be9060795d
commit c00d08c872
8 files changed
+173 -5

No files matched your search

@@ -12,6 +12,8 @@
namespace Netzmacht\Contao\Leaflet\Dca;
use Netzmacht\Contao\Leaflet\Model\LayerModel;
class Control
{
public function generateRow($row)
@@ -22,4 +24,18 @@ class Control
$row['type']
);
}
public function getLayers()
{
$options = array();
$collection = LayerModel::findBy('pid', '0', array('order' => 'title'));
if ($collection) {
foreach ($collection as $model) {
$options[$model->id] = $model->title;
}
}
return $options;
}
}