* email: manage acl table; show acl table for selected folder for first folder selected when clicking on ACL tab as first action; remove trailing whitespaced

This commit is contained in:
Klaus Leithoff 2012-07-03 11:18:57 +00:00
parent 36f334dcff
commit a66e6803e2
2 changed files with 23 additions and 6 deletions

View File

@ -15,7 +15,7 @@
/**
* a class containing / implementing the xajax actions triggered by javascript
*/
class ajaxfelamimail
class ajaxfelamimail
{
// which profile to use(currently only 0 is supported)
var $imapServerID=0;
@ -167,6 +167,23 @@ class ajaxfelamimail
return $this->generateMessageList($this->sessionData['mailbox']);
}
/**
* initiateACLTable
* creates the ACL table
*
* @param string $_folder folder to initiate the acl table for
*
* @return string html output for ACL table
*/
function initiateACLTable($_folder)
{
$response = new xajaxResponse();
if ($folderACL = $this->bofelamimail->getIMAPACL($_folder)) {
$response->addAssign("aclTable", "innerHTML", $this->createACLTable($folderACL));
}
return $response->getXML();
}
/**
* createACLTable
* creates the ACL table
@ -499,7 +516,7 @@ class ajaxfelamimail
if($quota = $this->bofelamimail->getQuotaRoot()) {
if (isset($quota['usage']) && $quota['limit'] != 'NOT SET')
{
{
$quotaDisplay = $this->uiwidgets->quotaDisplay($quota['usage'], $quota['limit']);
$response->addAssign('quotaDisplay', 'innerHTML', $quotaDisplay);
}
@ -684,12 +701,12 @@ class ajaxfelamimail
if(is_array($_selectedMessages) && count($_selectedMessages['msg']) > 0) $messageCount = count($_selectedMessages['msg']);
$folderName = $this->_decodeEntityFolderName($_folderName);
if ($_selectedMessages == 'all' || !empty( $_selectedMessages['msg']) && !empty($folderName)) {
if ($this->sessionData['mailbox'] != $folderName)
if ($this->sessionData['mailbox'] != $folderName)
{
$deleteAfterMove = false;
$this->bofelamimail->moveMessages($folderName, ($_selectedMessages == 'all'? null:$_selectedMessages['msg']),$deleteAfterMove);
}
else
}
else
{
if($this->_debug) error_log("ajaxfelamimail::copyMessages-> same folder than current selected");
}

View File

@ -20,7 +20,7 @@
<table width="100%" border="0" cellspacing="0" cellpading="0" bgcolor="white">
<tr>
<th id="tab1" class="activetab" onclick="javascript:tab.display(1);" style="width:50%;"><a href="#" tabindex="0" accesskey="1" onfocus="tab.display(1);" onclick="tab.display(1); return(false);" style="font-size:10px;">{lang_Overview}</a></th>
<th id="tab2" class="activetab" onclick="javascript:tab.display(2);" style="width:50%;"><a href="#" tabindex="0" accesskey="2" onfocus="tab.display(2);" onclick="tab.display(2); return(false);" style="font-size:10px;">{lang_ACL}</a></th>
<th id="tab2" class="activetab" onclick="javascript:tab.display(2);xajax_doXMLHTTP('felamimail.ajaxfelamimail.initiateACLTable',tree.getSelectedItemId());" style="width:50%;"><a href="#" tabindex="0" accesskey="2" onfocus="tab.display(2);" onclick="tab.display(2); return(false);" style="font-size:10px;">{lang_ACL}</a></th>
</tr>
</table>
{settings_view}