mirror of
https://github.com/Combodo/iTop.git
synced 2026-02-12 23:14:18 +01:00
#439 Record and display changes in the link sets (ex: Members of a team)
#439 Make sure that changes made by a plugin get recorded + simplified the change tracking for the plugins. Simply call DBObject::DBInsert (resp. Update and Delete) and the change will be recorded for the current page. This is compatible with the old (not mandatory anymore) way that was requiring DBInsertTracked APIs (resp. Update, Delete). SVN:trunk[2236]
This commit is contained in:
@@ -429,12 +429,9 @@ class CheckStopWatchThresholds implements iBackgroundProcess
|
||||
|
||||
if($oObj->IsModified())
|
||||
{
|
||||
// Todo - factorize so that only one single change will be instantiated
|
||||
$oMyChange = new CMDBChange();
|
||||
$oMyChange->Set("date", time());
|
||||
$oMyChange->Set("userinfo", "Automatic - threshold triggered");
|
||||
$iChangeId = $oMyChange->DBInsertNoReload();
|
||||
|
||||
CMDBObject::SetTrackInfo("Automatic - threshold triggered");
|
||||
|
||||
$oMyChange = CMDBObject::GetCurrentChange();
|
||||
$oObj->DBUpdateTracked($oMyChange, true /*skip security*/);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user