From 2d40bfa82812405d741672be8eed4f3c2443b011 Mon Sep 17 00:00:00 2001 From: hickert Date: Tue, 3 Jun 2008 07:53:02 +0000 Subject: [PATCH] updatedimport git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@11162 594d385d-05f5-0310-b6e9-bd551577e9d8 --- .../goto/addons/goto/class_goto_import_file.inc | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/gosa-plugins/goto/addons/goto/class_goto_import_file.inc b/gosa-plugins/goto/addons/goto/class_goto_import_file.inc index 3eedfc0ff..4b549d88e 100644 --- a/gosa-plugins/goto/addons/goto/class_goto_import_file.inc +++ b/gosa-plugins/goto/addons/goto/class_goto_import_file.inc @@ -10,7 +10,7 @@ class goto_import_file extends plugin { plugin::plugin($config,NULL); $this->parent = $parent; - $this->daemon_events = DaemonEvent::get_event_types( SYSTEM_EVENT); + $this->daemon_events = DaemonEvent::get_event_types( SYSTEM_EVENT | HIDDEN_EVENT); $this->csv_fields = array( "0"=>"TIMESTAMP","1" => "MAC", "2" => "HEADER", "3" => "OGROUP", @@ -99,10 +99,18 @@ class goto_import_file extends plugin $fail ++; continue; } + + /* Create event + */ $class= $this->daemon_events['QUEUED'][$event['HEADER']]; + $o_data = $this->daemon_events['BY_CLASS'][$class]; $object = new $class($this->config); - $object->set_type(TRIGGERED_EVENT); $object->add_targets(array($event['MAC'])); + if($o_data['s_Schedule_Action'] == $event['HEADER']){ + $object->set_type(SCHEDULED_EVENT); + }else{ + $object->set_type(TRIGGERED_EVENT); + } /* Update values like fqdn a.s.o */ -- 2.30.2