summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 396965c)
raw | patch | inline | side by side (parent: 396965c)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 26 Jun 2006 11:55:02 +0000 (11:55 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 26 Jun 2006 11:55:02 +0000 (11:55 +0000) |
Application only, other dialog will follow
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@3908 594d385d-05f5-0310-b6e9-bd551577e9d8
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@3908 594d385d-05f5-0310-b6e9-bd551577e9d8
diff --git a/html/images/restore_grey.png b/html/images/restore_grey.png
new file mode 100755 (executable)
index 0000000..b9aa02d
Binary files /dev/null and b/html/images/restore_grey.png differ
index 0000000..b9aa02d
Binary files /dev/null and b/html/images/restore_grey.png differ
index 59aa9eb22419221c4a7cb1e217bd294fdcc42ead..82aac59eee198e016f7bdae4c8acf11ecfb2b04b 100644 (file)
}
}
}
-
}
- function GetSnapShotActions($dn)
+ /* Create header snapshot value */
+ function get_snapshot_header()
{
$str = "";
+ if($this->parent->snapshotEnabled()){
+ $ok = false;
+ foreach($this->parent->get_used_snapshot_bases() as $base){
+ $ok |= count($this->parent->getAllDeletedSnapshots($base)) >= 1 ;
+ }
+ if($ok){
+ $str = "<input class='center' type='image' align='middle' src='images/restore.png'
+ title='"._("Restore snapshopts of already deleted objects")."'
+ alt='"._("Restore")."' name='RestoreDeletedSnapShot'> ";
+ }else{
+ $str = "<img class='center' src='images/restore_grey.png'> ";
+ }
+
+ $str .= "<img class='center' src='images/list_seperator.png' align='middle' alt='' height='16' width='1'> ";
+ }
+ return($str);
+ }
+
+ function GetSnapShotActions($dn)
+ {
+ $str = "";
if($this->parent->snapshotEnabled()){
$str .="<input class='center' type='image' src='images/snapshot.png'
diff --git a/plugins/admin/applications/class_applicationManagement.inc b/plugins/admin/applications/class_applicationManagement.inc
index 5a3cecedea1eb7e1cd27033fe9a2762531217ff1..4cb3ccd04b8c9c39f39132ede58b5342fc3bce90 100644 (file)
Dialog display
****************/
- $useBase = $this->DivListApplication->selectedRelease;
/* Check if there is a snapshot dialog open */
- if($str = $this->showSnapshotDialog($this->DivListApplication->selectedBase,$useBase)){
+ $base = $this->DivListApplication->selectedBase;
+ if($str = $this->showSnapshotDialog($base,$this->get_used_snapshot_bases($base))){
return($str);
}
}
+ /* Return departments, that will be included within snapshot detection */
+ function get_used_snapshot_bases(){
+ if($this->DivListApplication->selectedRelease == "main"){
+ return(array($this->DivListApplication->selectedBase));
+ }else{
+ return(array($this->DivListApplication->selectedRelease));
+ }
+ }
+
+
function reload()
{
$this->applications= array();
diff --git a/plugins/admin/applications/class_divListApplication.inc b/plugins/admin/applications/class_divListApplication.inc
index 52c69425ec35b5f294be7e13a3d3ab0e27a457eb..86f1aa235fa5f1f2ff04bd043298ecc19b9fe30b 100755 (executable)
" <input class='center' type='image' src='images/list_reload.png' align='middle' ".
"title='"._("Reload list")."' name='submit_department' alt='"._("Submit")."'> ".
" <img class='center' src='images/list_seperator.png' align='middle' alt='' height='16' width='1'> ";
-
- if($this->parent->snapshotEnabled()){
- $listhead .= " <input class='center' type='image' align='middle' src='images/restore.png'
- title='"._("Restore snapshopts of already deleted objects")."' alt='"._("Restore")."' name='RestoreDeletedSnapShot'>".
- " <img class='center' src='images/list_seperator.png' align='middle' alt='' height='16' width='1'> ";
- }
-
+ $listhead .= $this->get_snapshot_header($this->selectedBase);
$listhead .= " <input class='center' type='image' align='middle' src='images/list_new_app.png' alt='"._("new").
"' title='"._("Create new application")."' name='appl_new'> ".
$Copy_Paste.