mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-24 02:58:43 +02:00
Allow filtering the Delta output...
SVN:trunk[2794]
This commit is contained in:
@@ -1220,13 +1220,21 @@ EOF
|
||||
/**
|
||||
* Get the text/XML version of the delta
|
||||
*/
|
||||
public function GetDelta()
|
||||
public function GetDelta($aNodesToIgnore = array())
|
||||
{
|
||||
$oDelta = new MFDocument();
|
||||
foreach($this->ListChanges() as $oAlteredNode)
|
||||
{
|
||||
$this->ImportNodeAndPathDelta($oDelta, $oAlteredNode);
|
||||
}
|
||||
foreach($aNodesToIgnore as $sXPath)
|
||||
{
|
||||
$oNodesToRemove = $oDelta->GetNodes($sXPath);
|
||||
foreach($oNodesToRemove as $oNode)
|
||||
{
|
||||
$oNode->parentNode->removeChild($oNode);
|
||||
}
|
||||
}
|
||||
return $oDelta->saveXML();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user