summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 55332ed)
raw | patch | inline | side by side (parent: 55332ed)
author | hzerres <hzerres@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 13 Sep 2010 13:00:53 +0000 (13:00 +0000) | ||
committer | hzerres <hzerres@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 13 Sep 2010 13:00:53 +0000 (13:00 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@19622 594d385d-05f5-0310-b6e9-bd551577e9d8
gosa-plugins/groupware/personal/groupware/class_groupware.inc | patch | blob | history |
diff --git a/gosa-plugins/groupware/personal/groupware/class_groupware.inc b/gosa-plugins/groupware/personal/groupware/class_groupware.inc
index 220a2a0dc208f973b63a22621d08d35e40ddeace..9f3424437ba331ea7e390c4139c91438b5b257a1 100644 (file)
var $rpcError = FALSE;
var $rpcErrorMessage = "";
+ /*
var $attributes = array(
"mailAddress",
"mailLocation",
"localDeliveryOnly",
"dropOwnMails"
);
+ */
var $enabledFeatures = array();
$this->groupwareDao = new groupware_dao($this);
$features = array();
+ $featureReq = array(
+ "primaryMail" => array(
+ 'acctGetPrimaryMailAddress'),
+ "quotaUsage" => array(
+ 'acctGetQuota'),
+ "quotaSize" => array(
+ 'acctSetQuota','acctGetQuota'),
+ "mailFilter" => array(
+ 'acctDelFilter','acctGetFilters','acctSetFilters','acctSetFilters'),
+ "alternateAddresses" => array(
+ 'acctDelAlternateMailAddress','acctSetAlternateMailAddresses',
+ 'acctAddAlternateMailAddress','acctGetAlternateMailAddresses'),
+ "forwardingAddresses" => array(
+ 'acctAddMailForwardAddress','acctDelMailForwardAddress',
+ 'acctGetMailForwardAddresses','acctSetMailForwardAddresses'),
+ "vacationMessage" => array(
+ 'acctDelFilter','acctGetFilters','acctSetFilters','acctSetFilters'),
+ "mailBoxWarnLimit" => array(
+ 'acctSetQuota','acctGetQuota'),
+ "mailBoxSendSizelimit" => array(
+ 'acctSetQuota','acctGetQuota'),
+ "mailBoxHardSizelimit" => array(
+ 'acctSetQuota','acctGetQuota'),
+ "mailBoxAutomaticRemoval" => array(
+ 'acctSetQuota','acctGetQuota'),
+ "localDeliveryOnly" => array(
+ 'acctDelFilter','acctGetFilters','acctSetFilters','acctSetFilters'),
+ "dropOwnMails" => array(
+ 'acctDelFilter','acctGetFilters','acctSetFilters','acctSetFilters')
+ );
+
+ /*
$featureReq = array(
"primaryMail" => array(
'acctGetPrimaryMailAddress'),
'acctDelFilter','acctGetFilters','acctSetFilters','acctSetFilters'),
"dropOwnMails" => array(
'acctDelFilter','acctGetFilters','acctSetFilters','acctSetFilters'));
-
+ */
// Check if all required methods cann be called!
foreach($featureReq as $name => $requires){
$active = TRUE;
}
/*
- * Trying to save the primary Email Address.
+ *save the primary Email Address.
*/
if(!empty($this->mailAddress)){
- $this->groupwareDao->save("primaryMail", array($this->uid, $this->mailAddress));
+ $this->groupwareDao->save("primaryMail", $this->uid, $this->mailAddress);
+ }
+
+ /*
+ *
+ */
+ if(isset($this->forwardingAddresses) && is_array($this->forwardingAddresses)){
+ $this->groupwareDao->save("alternateAddresses", $this->uid, $this->alternateAddresses);
+ }
+ if(isset($this->forwardingAddresses) && is_array($this->forwardingAddresses)){
+ $this->groupwareDao->save("forwardingAddresses", $this->uid, $this->forwardingAddresses);
}
}
}
- public function save($feature, $valueArray)
+ public function save($feature, $uid, $valueArray)
{
/*
* TODO:
* save and return the result.
*/
$function = groupware_dao::$gwFeatures[$feature]["save"];
+
if(is_array($valueArray)){
- $valueArray = array_merge(array($function), $valueArray);
+ $valueArray = array_merge(array($function, $uid), $valueArray);
}
else{
- $valueArray = array($function, $valueArray);
+ $valueArray = array($function, $uid, $valueArray);
}
$this->debug("SAVING (feature, value)", $valueArray);
$result = call_user_func_array(array($this->groupwarePluginRef, 'rpcExec'), $valueArray);