mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-02-23 05:41:02 +01:00
* email: improve the handling of addresses in edit of vacationnotice (SIEVE)
This commit is contained in:
parent
9b5bb433f6
commit
5a08e4d8a1
@ -190,8 +190,15 @@ function createScript()
|
|||||||
<!-- END filterrow -->
|
<!-- END filterrow -->
|
||||||
|
|
||||||
<!-- BEGIN vacation -->
|
<!-- BEGIN vacation -->
|
||||||
|
<script LANGUAGE="JavaScript" TYPE="text/javascript">
|
||||||
<form ACTION="{vacation_action_url}" METHOD="post" NAME="editVacation">
|
function submitIt()
|
||||||
|
{
|
||||||
|
selectAllOptions();
|
||||||
|
//document.editVacation.submit();
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
<form ACTION="{vacation_action_url}" METHOD="post" NAME="editVacation" onsubmit="return submitIt()">
|
||||||
<p style="color: red; font-style: italic; text-align: center;">{validation_errors}</p>
|
<p style="color: red; font-style: italic; text-align: center;">{validation_errors}</p>
|
||||||
<table WIDTH="100%" CELLPADDING="2" CELLSPACING="1" style="border: 1px solid silver;">
|
<table WIDTH="100%" CELLPADDING="2" CELLSPACING="1" style="border: 1px solid silver;">
|
||||||
<tr CLASS="th">
|
<tr CLASS="th">
|
||||||
|
@ -46,24 +46,29 @@
|
|||||||
{
|
{
|
||||||
idSelectedValues = document.getElementById("htmlclass_selected_values");
|
idSelectedValues = document.getElementById("htmlclass_selected_values");
|
||||||
idPredefinedValues = document.getElementById("htmlclass_predefined_values");
|
idPredefinedValues = document.getElementById("htmlclass_predefined_values");
|
||||||
|
while(idSelectedValues.selectedIndex != -1)
|
||||||
if(idSelectedValues.selectedIndex != -1)
|
|
||||||
{
|
{
|
||||||
|
// if we want to allow removing only one by one, we need this and section idselectioncontrol
|
||||||
|
// AND need to disable the selectAllOptions at the end of the function
|
||||||
|
//for(i=0;i<idSelectedValues.length;++i)
|
||||||
|
//{
|
||||||
|
// if (idSelectedValues[i].selected) break;
|
||||||
|
//}
|
||||||
NewOption = new Option(idSelectedValues.options[idSelectedValues.selectedIndex].text,
|
NewOption = new Option(idSelectedValues.options[idSelectedValues.selectedIndex].text,
|
||||||
idSelectedValues.options[idSelectedValues.selectedIndex].value,false,true);
|
idSelectedValues.options[idSelectedValues.selectedIndex].value,false,true);
|
||||||
idPredefinedValues.options[idPredefinedValues.length] = NewOption;
|
idPredefinedValues.options[idPredefinedValues.length] = NewOption;
|
||||||
|
|
||||||
idSelectedValues.options[idSelectedValues.selectedIndex] = null;
|
idSelectedValues.options[idSelectedValues.selectedIndex] = null;
|
||||||
|
// section idselectioncontrol
|
||||||
|
//if (i>idSelectedValues.length-1) i=idSelectedValues.length-1;
|
||||||
|
//if (idSelectedValues.length!=0)idSelectedValues.options[i].selected = true;
|
||||||
|
|
||||||
for(i=0;i<idSelectedValues.length;++i)
|
|
||||||
{
|
|
||||||
idSelectedValues.options[i].selected = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
sortSelect(idPredefinedValues);
|
|
||||||
}
|
}
|
||||||
|
sortSelect(idPredefinedValues);
|
||||||
|
selectAllOptions();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function selectAllOptions()
|
function selectAllOptions()
|
||||||
{
|
{
|
||||||
idSelectedValues = document.getElementById("htmlclass_selected_values");
|
idSelectedValues = document.getElementById("htmlclass_selected_values");
|
||||||
@ -110,8 +115,8 @@
|
|||||||
<tr>
|
<tr>
|
||||||
<td width="50%" align="right" rowspan="2" valign="top">
|
<td width="50%" align="right" rowspan="2" valign="top">
|
||||||
<select name="{multiSelectBox_valueName}[]" id="htmlclass_selected_values" size=8
|
<select name="{multiSelectBox_valueName}[]" id="htmlclass_selected_values" size=8
|
||||||
style="width : 250px;" multiple="multiple" ondblclick="removeValue()"
|
style="width : 250px;" multiple="multiple" ondblclick="removeValue()">
|
||||||
onblur="selectAllOptions()">
|
<!-- onblur="selectAllOptions()" on blur was removed here and substituded with the call of selectAllOptions on submit -->
|
||||||
{multiSelectBox_selected_options}
|
{multiSelectBox_selected_options}
|
||||||
</select>
|
</select>
|
||||||
</td>
|
</td>
|
||||||
|
Loading…
Reference in New Issue
Block a user