summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 0e024de)
raw | patch | inline | side by side (parent: 0e024de)
author | hzerres <hzerres@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 25 Oct 2010 11:47:46 +0000 (11:47 +0000) | ||
committer | hzerres <hzerres@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 25 Oct 2010 11:47:46 +0000 (11:47 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@20139 594d385d-05f5-0310-b6e9-bd551577e9d8
gosa-plugins/groupware/personal/groupware/class_Groupware.inc | patch | blob | history | |
gosa-plugins/groupware/personal/groupware/generic.tpl | patch | blob | history |
diff --git a/gosa-plugins/groupware/personal/groupware/class_Groupware.inc b/gosa-plugins/groupware/personal/groupware/class_Groupware.inc
index 1445b4b98c7816603fda5fdbb49ca011444f1db7..01141cd9c6d5caed0019566e38ecf6a4dc65e697 100644 (file)
*/
function execute()
{
+ echo "execute <pre>";
+ print_r($_POST);
+ echo "</pre>";
// Register plugin execution
$display = plugin::execute();
$this->dialog = TRUE;
return($this->filterManager->execute());
}
- /****************
- MailLimits
- ****************/
-
-
-
/****************
Folder editor
*/
function save_object()
{
+ echo "save Object";
if(isset($_POST['groupwarePluginPosted'])){
// We ran into a communication error with the backend.
//checks for feature "mailLimit"
if($this->isFeatureEnabled("mailLimit") && $this->hasFeaturebeenChanged("mailLimit")){
- $this->groupwareDao->save("mailLimit", $this->uid, array("receive"=>$this->mailLimitReceiveValue, "send"=>$this->mailLimitSendValue,));
+ if(!$this->mailLimitReceiveEnabled){
+ $this->mailLimitReceiveValue = 0;
+ }
+ if(!$this->mailLimitSendEnabled){
+ $this->mailLimitSendValue = 0;
+ }
+ $this->groupwareDao->save("mailLimit", $this->uid, array( "send"=>$this->mailLimitSendValue, "receive"=>$this->mailLimitReceiveValue));
}
if($this->isFeatureEnabled("vacationMessage")&& $this->hasFeaturebeenChanged("vacationMessage")){
if($this->vacationEnabled){
}
-?>
\ No newline at end of file
+?>
diff --git a/gosa-plugins/groupware/personal/groupware/generic.tpl b/gosa-plugins/groupware/personal/groupware/generic.tpl
index 150763d0f8e9828c948e499b00643c10c04d3dfa..fa074232b4202164ef31d884cdb54490839dda4c 100644 (file)
<tr>
<td>
{render acl=$mailBoxWarnLimitACL}
- <input id='mailBoxWarnLimitEnabled' value='1' name="mailBoxWarnLimitEnabled" value="1"
+ <input id='mailBoxWarnLimitEnabled' value='1' name="mailBoxWarnLimitEnabled" onclick="changeState('mailBoxWarnLimitValue');" value="1"
{if $mailBoxWarnLimitEnabled} checked {/if} class="center" type='checkbox'>
{/render}
<label for="mailBoxWarnLimitValue">{t}Warn user about a full mailbox when it reaches{/t}</label>
{render acl=$mailBoxWarnLimitACL}
<input id="mailBoxWarnLimitValue" name="mailBoxWarnLimitValue"
- size="6" align="middle" type='text' value="{$mailBoxWarnLimitValue}" class="center"> {t}MB{/t}
+ size="6" align="middle" type='text' value="{$mailBoxWarnLimitValue}" {if !$mailBoxWarnLimitEnabled} disabled {/if} class="center"> {t}MB{/t}
{/render}
</td>
</tr>
<tr>
<td>
{render acl=$mailBoxSendSizelimitACL}
- <input id='mailBoxSendSizelimitEnabled' value='1' name="mailBoxSendSizelimitEnabled" value="1"
+ <input id='mailBoxSendSizelimitEnabled' value='1' name="mailBoxSendSizelimitEnabled" onclick="changeState('mailBoxSendSizelimitValue');" value="1"
{if $mailBoxSendSizelimitEnabled} checked {/if} class="center" type='checkbox'>
{/render}
<label for="mailBoxSendSizelimitValue">{t}Refuse incoming mails when mailbox size reaches{/t}</label>
{render acl=$mailBoxSendSizelimitACL}
<input id="mailBoxSendSizelimitValue" name="mailBoxSendSizelimitValue"
- size="6" align="middle" type='text' value="{$mailBoxSendSizelimitValue}" class="center"> {t}MB{/t}
+ size="6" align="middle" type='text' value="{$mailBoxSendSizelimitValue}" {if !$mailBoxSendSizelimitEnabled} disabled {/if} class="center"> {t}MB{/t}
{/render}
</td>
</tr>
<tr>
<td>
{render acl=$mailBoxHardSizelimitACL}
- <input id='mailBoxHardSizelimitEnabled' value='1' name="mailBoxHardSizelimitEnabled" value="1"
+ <input id='mailBoxHardSizelimitEnabled' value='1' name="mailBoxHardSizelimitEnabled" onclick="changeState('mailBoxHardSizelimitValue');" value="1"
{if $mailBoxHardSizelimitEnabled} checked {/if} class="center" type='checkbox'>
{/render}
<label for="mailBoxHardSizelimitValue">{t}Refuse to send and receive mails when mailbox size reaches{/t}</label>
{render acl=$mailBoxHardSizelimitACL}
<input id="mailBoxHardSizelimitValue" name="mailBoxHardSizelimitValue"
- size="6" align="middle" type='text' value="{$mailBoxHardSizelimitValue}" class="center"> {t}MB{/t}
+ size="6" align="middle" type='text' value="{$mailBoxHardSizelimitValue}" {if !$mailBoxHardSizelimitEnabled} disabled {/if} class="center"> {t}MB{/t}
{/render}
</td>
</tr>
<tr>
<td>
{render acl=$mailBoxAutomaticRemovalACL}
- <input id='mailBoxAutomaticRemovalEnabled' value='1' name="mailBoxAutomaticRemovalEnabled" value="1"
+ <input id='mailBoxAutomaticRemovalEnabled' value='1' name="mailBoxAutomaticRemovalEnabled" onclick="changeState('mailBoxAutomaticRemovalValue');" value="1"
{if $mailBoxAutomaticRemovalEnabled} checked {/if} class="center" type='checkbox'>
{/render}
<label for="mailBoxAutomaticRemovalValue">{t}Remove mails older than {/t}</label>
{render acl=$mailBoxAutomaticRemovalACL}
<input id="mailBoxAutomaticRemovalValue" name="mailBoxAutomaticRemovalValue"
- size="6" align="middle" type='text' value="{$mailBoxAutomaticRemovalValue}" class="center"> {t}days{/t}
+ size="6" align="middle" type='text' value="{$mailBoxAutomaticRemovalValue}" {if !$mailBoxAutomaticRemovalEnabled} disabled {/if} class="center"> {t}days{/t}
{/render}
</td>
</tr>
{if $mailLimit_isActive}
<tr>
<td>
- <input id='mailLimitReceiveEnabled' value='1' name="mailLimitReceiveEnabled" value="1"
+ <input id='mailLimitReceiveEnabled' value='1' name="mailLimitReceiveEnabled" value="1" onclick="changeState('mailLimitReceiveValue');"
{if $mailLimitReceiveEnabled} checked {/if} class="center" type='checkbox'>
<label for="mailLimit">{t}Mailbox size limits receiving mails{/t}</label>
<input id="mailLimitReceiveValue" name="mailLimitReceiveValue"
- size="6" align="middle" type='text' value="{$mailLimitReceiveValue}" class="center"> {t}kbyte{/t}
+ size="6" align="middle" type='text' value="{$mailLimitReceiveValue}" {if !$mailLimitReceiveEnabled} disabled {/if} class="center"> {t}kbyte{/t}
</td>
</tr>
<tr>
<td>
- <input id='mailLimitSendEnabled' value='1' name="mailLimitSendEnabled" value="1"
+ <input id='mailLimitSendEnabled' value='1' name="mailLimitSendEnabled" value="1" onclick="changeState('mailLimitSendValue');"
{if $mailLimitSendEnabled} checked {/if} class="center" type='checkbox'>
<label for="mailLimit">{t}Mailbox size limits sending mails{/t}</label>
<input id="mailLimitSendValue" name="mailLimitSendValue"
- size="6" align="middle" type='text' value="{$mailLimitSendValue}" class="center"> {t}kbyte{/t}
+ size="6" align="middle" type='text' value="{$mailLimitSendValue}" {if !$mailLimitSendEnabled} disabled {/if} class="center"> {t}kbyte{/t}
</td>
</tr>
{/if}