summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: ddf84c3)
raw | patch | inline | side by side (parent: ddf84c3)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 22 Aug 2007 07:00:30 +0000 (07:00 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 22 Aug 2007 07:00:30 +0000 (07:00 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@7093 594d385d-05f5-0310-b6e9-bd551577e9d8
plugins/addons/gotomasses/class_goto_task.inc | patch | blob | history | |
plugins/addons/gotomasses/class_gotomasses.inc | patch | blob | history |
diff --git a/plugins/addons/gotomasses/class_goto_task.inc b/plugins/addons/gotomasses/class_goto_task.inc
index f67fd7f115a6a6b7e4a23d47dfbc5d1252218d2a..60a7765398b1d3a478f545f2723b454f8bf31e61 100644 (file)
foreach($_POST as $name => $value){
if(preg_match("/^remove_/",$name)){
$value = preg_replace("/^remove_([0-9]*)_(x|y)$/i","\\1",$name);
- if(isset($this->Target[$value])){
+ if(isset($this->Target[$value]) && $this->Action != "initial_install"){
unset($this->Target[$value]);
+ }elseif(isset($this->Initial_Target[$value]) && $this->Action == "initial_install"){
+ unset($this->Initial_Target[$value]);
}
}
}
diff --git a/plugins/addons/gotomasses/class_gotomasses.inc b/plugins/addons/gotomasses/class_gotomasses.inc
index b908533926bf6e65569bec8ce3eba8b7b10771ac..dc2bb580ed7f0e843595837c1fd5797729f52536 100644 (file)
/* Include config object */
$this->config= $config;
-
$this->load_gotomasses_data();
}
-
function execute()
{
$smarty = get_smarty();
foreach($this->tasks as $task){
$str .= "\n#".trim($task['Comment']);
$str .= "\n";
- $str .= str_pad($task['Minute'] ,5," ")." ";
- $str .= str_pad($task['Hour'] ,5," ")." ";
- $str .= str_pad($task['Day'] ,5," ")." ";
- $str .= str_pad($task['Month'] ,5," ")." ";
- $str .= str_pad($task['Weekday'],5," ")." ";
+ if($task['Action'] == "initial_install"){
+ $str .= "* * * * * ";
+ }else{
+ $str .= str_pad($task['Minute'] ,5," ")." ";
+ $str .= str_pad($task['Hour'] ,5," ")." ";
+ $str .= str_pad($task['Day'] ,5," ")." ";
+ $str .= str_pad($task['Month'] ,5," ")." ";
+ $str .= str_pad($task['Weekday'],5," ")." ";
+ }
$str .= str_pad($task['Action'] ,5," ")." ";
$str .= str_pad($task['OGroup'] ,5," ")." ";
if($task['Action'] == "initial_install"){
"update" => _("Update"),
"reinstall" => _("(Re)Install"),
"rescan" => _("Rescan"),
+ "wake" => _("Wake"),
"memcheck" => _("Memory check"));
return($actions);
}