From: cajus Date: Tue, 19 Jan 2010 14:44:45 +0000 (+0000) Subject: Add element adder X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=3fda1cb6960bd2d091dd76770bf16c7b34a0b2b0;p=gosa.git Add element adder git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@15206 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-core/include/class_sortableListing.inc b/gosa-core/include/class_sortableListing.inc index c81faeb5b..24aa956b0 100644 --- a/gosa-core/include/class_sortableListing.inc +++ b/gosa-core/include/class_sortableListing.inc @@ -408,4 +408,19 @@ class sortableListing { } } + + public function addEntry($entry, $displayEntry= null) + { + // Prefill with default value if not specified + if (!$displayEntry) { + $displayEntry= array($entry); + } + + // Append to data and mapping + $this->data[]= $entry; + $this->displayData[]= $displayData; + $this->mapping[]= count($this->mapping); + } + + }