Code Duplication    Length = 14-17 lines in 2 locations

src/DataGrid.php 2 locations

@@ 1666-1682 (lines=17) @@
1663
	 * @param  int $parent
1664
	 * @return void
1665
	 */
1666
	public function handleGetChildren($parent)
1667
	{
1668
		$this->setDataSource(
1669
			call_user_func($this->tree_view_children_callback, $parent)
1670
		);
1671
1672
		if ($this->getPresenter()->isAjax()) {
1673
			$this->getPresenter()->payload->_datagrid_url = $this->refresh_url;
1674
			$this->getPresenter()->payload->_datagrid_tree = $parent;
1675
1676
			$this->redrawControl('items');
1677
1678
			$this->onRedraw();
1679
		} else {
1680
			$this->getPresenter()->redirect('this');
1681
		}
1682
	}
1683
1684
1685
	/**
@@ 1690-1703 (lines=14) @@
1687
	 * @param  mixed $id
1688
	 * @return void
1689
	 */
1690
	public function handleGetItemDetail($id)
1691
	{
1692
		$this->template->add('toggle_detail', $id);
1693
		$this->redraw_item = [$this->items_detail->getPrimaryWhereColumn() => $id];
1694
1695
		if ($this->getPresenter()->isAjax()) {
1696
			$this->getPresenter()->payload->_datagrid_toggle_detail = $id;
1697
			$this->redrawControl('items');
1698
1699
			$this->onRedraw();
1700
		} else {
1701
			$this->getPresenter()->redirect('this');
1702
		}
1703
	}
1704
1705
1706
	/**