summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: ca1a723)
raw | patch | inline | side by side (parent: ca1a723)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 6 Oct 2005 12:48:16 +0000 (12:48 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 6 Oct 2005 12:48:16 +0000 (12:48 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@1512 594d385d-05f5-0310-b6e9-bd551577e9d8
plugins/admin/fai/class_faiPackage.inc | patch | blob | history | |
plugins/admin/fai/class_faiPackageEntry.inc | patch | blob | history | |
plugins/admin/fai/faiPackage.tpl | patch | blob | history |
index df89c0749eba9ab42ab26a9d335b39f6319c9ff9..2e44d8c33d8d0b8cacccd5e2a356d0dd104eaa0c 100644 (file)
var $ignore_account = TRUE;
/* Attributes for this Object */
- var $attributes = array("cn","description","FAIpackage","FAIdebianSection","FAIdebianRelease","FAIdebianMirror");
+ var $attributes = array("cn","description","FAIpackage","FAIdebianRelease","FAIdebianSection","FAIdebianMirror");
/* ObjectClasses for this Object*/
var $objectclasses = array("top","FAIclass","FAIpackageList","FAIrepository");
var $dialog = NULL; // a dialog, e.g. new disk dialog
var $SubObjects = array(); // All leafobjects of this object
- var $FAIdebianSection = ""; // The selected section
- var $FAIdebianRelease = ""; // selected release
+ var $FAIdebianRelease = ""; // The selected release
+ var $FAIdebianSection = ""; // selected section
var $FAIdebianMirror = ""; // selected mirror
var $servers = array(); // All available servers
- var $sections = array(); // All possible sections
- var $releases = array(); // All release types
+ var $releases = array(); // All possible releases
+ var $sections = array(); // All section types
var $disableRepository = false;
- var $mirrors = array(); // The combination of server/section/release
+ var $mirrors = array(); // The combination of server/release/section
var $confDir = "";
var $usedPackages = array();
$this->dn =$dn;
}
- if(isset($this->attrs['FAIdebianRelease'])){
+ if(isset($this->attrs['FAIdebianSection'])){
$this->disableRepository=true;
}
$availableServer = array();
foreach($this->mirrors as $mir){
- if(($mir['section'] == $this->FAIdebianSection)&&($mir['release']==$this->FAIdebianRelease)){
+ if(($mir['release'] == $this->FAIdebianRelease)&&($mir['section']==$this->FAIdebianSection)){
$availableServer[$mir['mirror']]=$mir['mirror'];
}
}
if(isset($_POST['Addpkg'])){
- $this->dialog = new faiPackageEntry($this->config, $this->dn,$this->confDir.$this->FAIdebianMirror."/".$this->FAIdebianSection."/".$this->FAIdebianRelease,$this->usedPackages);
+ $this->dialog = new faiPackageEntry($this->config, $this->dn,$this->confDir.$this->FAIdebianMirror."/".$this->FAIdebianRelease."/".$this->FAIdebianSection,$this->usedPackages);
$this->is_dialog =true;
}
if($this->disableRepository == true){
$smarty->assign("mirrorACL" ," disabled ");
- $smarty->assign("sectionACL" ," disabled ");
$smarty->assign("releaseACL" ," disabled ");
+ $smarty->assign("sectionACL" ," disabled ");
}else{
$smarty->assign("mirrorACL" ,"");
- $smarty->assign("sectionACL" ,"");
$smarty->assign("releaseACL" ,"");
+ $smarty->assign("sectionACL" ,"");
}
$smarty->assign("mirrors" ,$availableServer);
$smarty->assign("mirror" ,$this->FAIdebianMirror);
- $smarty->assign("sections",$this->sections);
- $smarty->assign("section" ,$this->FAIdebianSection);
$smarty->assign("releases",$this->releases);
$smarty->assign("release" ,$this->FAIdebianRelease);
+ $smarty->assign("sections",$this->sections);
+ $smarty->assign("section" ,$this->FAIdebianSection);
$smarty->assign("usedPackages",$this->printUsedPackages());
$display.= $smarty->fetch(get_template_path('faiPackage.tpl', TRUE));
return($display);
$mirrorDir = $confDir.$mirror."/";
$fe = opendir($mirrorDir);
- while($section = readdir($fe)){
- if((is_dir($mirrorDir.$section))&&(($section != "." )&&($section!=".."))){
+ while($release = readdir($fe)){
+ if((is_dir($mirrorDir.$release))&&(($release != "." )&&($release!=".."))){
- $sectionDir = $mirrorDir.$section."/";
+ $releaseDir = $mirrorDir.$release."/";
- $ff = opendir($sectionDir);
- while($release = readdir($ff)){
- if((is_file($sectionDir.$release))&&(($release != "." )&&($release!="..")&&(!preg_match("/.*\.in$/",$release)))){
+ $ff = opendir($releaseDir);
+ while($section = readdir($ff)){
+ if((is_file($releaseDir.$section))&&(($section != "." )&&($section!="..")&&(!preg_match("/.*\.in$/",$section)))){
$this->servers[$mirror]=$mirror;
- $this->sections[$section]=$section;
$this->releases[$release]=$release;
+ $this->sections[$section]=$section;
if(empty($this->FAIdebianMirror)){
$this->FAIdebianMirror= $mirror;
}
- if(empty($this->FAIdebianSection)){
- $this->FAIdebianSection = $section;
- }
if(empty($this->FAIdebianRelease)){
$this->FAIdebianRelease = $release;
+ }
+ if(empty($this->FAIdebianSection)){
+ $this->FAIdebianSection = $section;
}
$arr=array();
$arr['mirror'] = $mirror;
- $arr['section']= $section;
- $arr['release']= $release;
+ $arr['release']= $release;
+ $arr['section']= $section;
$this->mirrors[] = $arr ;
}
$message[]=_("Please select a least one Package.");
}
- if((empty($this->FAIdebianSection))||(empty($this->FAIdebianRelease))||(empty($this->FAIdebianMirror))){
+ if((empty($this->FAIdebianRelease))||(empty($this->FAIdebianSection))||(empty($this->FAIdebianMirror))){
$message[]=_("Please choose a valid combination for your repository setup.");
}
diff --git a/plugins/admin/fai/class_faiPackageEntry.inc b/plugins/admin/fai/class_faiPackageEntry.inc
index 006462389081a5935c7f277ba3a3634ba32a1e48..2693af1a7f74a09a62e626d2c793a6dbe799bb4f 100644 (file)
}
- $CHKS = "<table><tr><td><input type='hidden' value='chkchange' name='chkchange'>";
+ $CHKS = "<table><tr><input type='hidden' value='chkchange' name='chkchange'>";
+ $i = 0;
foreach($this->categories as $cat => $selected){
+ if($i == 3){
+ $CHKS .="</tr><tr>";
+ $i = 0;
+ }
+ $i ++ ;
if($selected){
- $CHKS .="<input type='checkbox' value='1' name='CAT".$cat."' checked onclick='document.mainform.submit()'> ".$cat." ";
+ $CHKS .="<td><input type='checkbox' value='1' name='CAT".$cat."' checked onclick='document.mainform.submit()'> ".$cat." </td>";
}else{
- $CHKS .="<input type='checkbox' value='1' name='CAT".$cat."' onclick='document.mainform.submit()'> ".$cat." ";
+ $CHKS .="<td><input type='checkbox' value='1' name='CAT".$cat."' onclick='document.mainform.submit()'> ".$cat." </td>";
}
}
$CHKS .= "<br><input type='submit' name='refresh0' value='"._("refresh")."'> </td></tr></table>";
index 66f38f0adf64368a7c76bc454c00325aa13449d2..6ad8acb450df5d45033cabe36698ac1182b09591 100644 (file)
<select name="FAIdebianSection" title="{t}section{/t}" {$sectionACL}>
{html_options options=$sections selected=$section}
</select>
- <input type="submit" value="{t}refresh{/t}" name="refresh1">
+ <input type="submit" value="{t}refresh{/t}" name="refresh2">
</td>
</tr>
<tr>
<select name="FAIdebianRelease" title="{t}release{/t}" {$releaseACL}>
{html_options options=$releases selected=$release}
</select>
- <input type="submit" value="{t}refresh{/t}" name="refresh2">
+ <input type="submit" value="{t}refresh{/t}" name="refresh1">
</td>
</tr>
<tr>