Code Duplication    Length = 14-17 lines in 2 locations

src/DataGrid.php 2 locations

@@ 1822-1838 (lines=17) @@
1819
	 * @param  int $parent
1820
	 * @return void
1821
	 */
1822
	public function handleGetChildren($parent)
1823
	{
1824
		$this->setDataSource(
1825
			call_user_func($this->tree_view_children_callback, $parent)
1826
		);
1827
1828
		if ($this->getPresenter()->isAjax()) {
1829
			$this->getPresenter()->payload->_datagrid_url = $this->refresh_url;
1830
			$this->getPresenter()->payload->_datagrid_tree = $parent;
1831
1832
			$this->redrawControl('items');
1833
1834
			$this->onRedraw();
1835
		} else {
1836
			$this->getPresenter()->redirect('this');
1837
		}
1838
	}
1839
1840
1841
	/**
@@ 1846-1859 (lines=14) @@
1843
	 * @param  mixed $id
1844
	 * @return void
1845
	 */
1846
	public function handleGetItemDetail($id)
1847
	{
1848
		$this->template->add('toggle_detail', $id);
1849
		$this->redraw_item = [$this->items_detail->getPrimaryWhereColumn() => $id];
1850
1851
		if ($this->getPresenter()->isAjax()) {
1852
			$this->getPresenter()->payload->_datagrid_toggle_detail = $id;
1853
			$this->redrawControl('items');
1854
1855
			$this->onRedraw();
1856
		} else {
1857
			$this->getPresenter()->redirect('this');
1858
		}
1859
	}
1860
1861
1862
	/**