From 22f7b3bb752d8cd1fe0670e9aa83386054cf8472 Mon Sep 17 00:00:00 2001 From: hickert Date: Mon, 11 Oct 2010 07:17:21 +0000 Subject: [PATCH] Added folder test class git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@19959 594d385d-05f5-0310-b6e9-bd551577e9d8 --- .../personal/groupware/class_folderTest.inc | 72 +++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 gosa-plugins/groupware/personal/groupware/class_folderTest.inc diff --git a/gosa-plugins/groupware/personal/groupware/class_folderTest.inc b/gosa-plugins/groupware/personal/groupware/class_folderTest.inc new file mode 100644 index 000000000..eb998211b --- /dev/null +++ b/gosa-plugins/groupware/personal/groupware/class_folderTest.inc @@ -0,0 +1,72 @@ +folderList = $this->getFolderList(); + } + + + function execute() + { + + if(isset($_POST['FolderWidget_cancel'])) $this->FolderWidget = NULL; + if(isset($_POST['FolderWidget_ok'])){ + $this->FolderWidget->save_object(); + $msgs = $this->FolderWidget->check(); + if(count($msgs)){ + msg_dialog::displayChecks($msgs); + }else{ + $this->folderList = $this->FolderWidget->save(); + $this->FolderWidget = NULL; + } + } + if(isset($_POST['configureFolder'])){ + $this->FolderWidget = new FolderWidget($this->config,$this->folderList, ""); + $this->FolderWidget->acl_base = $this->acl_base; + $this->FolderWidget->acl_category = $this->acl_category; + } + $this->dialog = FALSE; + if($this->FolderWidget instanceOf FolderWidget){ + $this->FolderWidget->save_object(); + $this->dialog = TRUE; + return($this->FolderWidget->execute()); + } + + return("") ; + } + + + function getFolderList() + { + + $ret['user/wiwu/Inbox/Aufgaben']['name'] = "Aufgaben"; + $ret['user/wiwu/Inbox/Aufgaben']['status'] = ''; + $ret['user/wiwu/Inbox/Aufgaben']['type'] = 'user'; + $ret['user/wiwu/Inbox/Aufgaben']['acls'] = array(); + + $ret['user/wiwu/Inbox/Gesendet']['name'] = "Gesendet"; + $ret['user/wiwu/Inbox/Gesendet']['status'] = ''; + $ret['user/wiwu/Inbox/Gesendet']['type'] = 'user'; + $ret['user/wiwu/Inbox/Gesendet']['acls'] = array(); + + $ret['user/wiwu/Inbox/Gesendet/2009']['name'] = "2009"; + $ret['user/wiwu/Inbox/Gesendet/2009']['status'] = ''; + $ret['user/wiwu/Inbox/Gesendet/2009']['type'] = 'user'; + $ret['user/wiwu/Inbox/Gesendet/2009']['acls'] = array(); + + $ret['user/wiwu/Inbox/Gesendet/2010']['name'] = "2010"; + $ret['user/wiwu/Inbox/Gesendet/2010']['status'] = ''; + $ret['user/wiwu/Inbox/Gesendet/2010']['type'] = 'user'; + $ret['user/wiwu/Inbox/Gesendet/2010']['acls'] = array(); + + return($ret); + } +} + +?> -- 2.30.2