Index: sandbox/2.4.3-expresso-rest/expressoAdmin1_2/js/jscode/groups.js
===================================================================
--- sandbox/2.4.3-expresso-rest/expressoAdmin1_2/js/jscode/groups.js	(revision 5133)
+++ sandbox/2.4.3-expresso-rest/expressoAdmin1_2/js/jscode/groups.js	(revision 7330)
@@ -118,5 +118,5 @@
 }
 
-function sinc_combos_org()
+function sinc_combos_org(context)
 {
 	combo_org_groups = document.getElementById('ea_combo_org_groups');
Index: sandbox/2.4.3-expresso-rest/expressoAdmin1_2/templates/default/groups_form.tpl
===================================================================
--- sandbox/2.4.3-expresso-rest/expressoAdmin1_2/templates/default/groups_form.tpl	(revision 6158)
+++ sandbox/2.4.3-expresso-rest/expressoAdmin1_2/templates/default/groups_form.tpl	(revision 7330)
@@ -25,8 +25,8 @@
 						<td width="40%" bgcolor="#DDDDDD">
 							{lang_search_organization}:<br>
-							<input type="text" id="organization_search" autocomplete="off" size=20 onKeyUp="javascript:search_organization(this.value, 'ea_combo_org_info');" onBlur="javascript:sinc_combos_org(context.value, ea_check_allUsers.checked); get_available_sambadomains(context.value, '{type}')">
+							<input type="text" id="organization_search" autocomplete="off" size=20 onKeyUp="javascript:search_organization(this.value, 'ea_combo_org_info');" onBlur="javascript:sinc_combos_org(context.value); get_available_sambadomains(context.value, '{type}')">
 							<br>
 							{lang_group_organization}:<br>
-							<select id="ea_combo_org_info" name="context" onchange="javascript:sinc_combos_org(this.value, ea_check_allUsers.checked); get_available_sambadomains(this.value, '{type}')">{combo_manager_org}</select><br>
+							<select id="ea_combo_org_info" name="context" onchange="javascript:sinc_combos_org(this.value); get_available_sambadomains(this.value, '{type}')">{combo_manager_org}</select><br>
 							{lang_group_name}: <font color="blue">Ex: grupo-celepar-rh</font><br>
 							<!--<input name="cn" size="35" value="{cn}" autocomplete="off" onKeyUp="javascript:groupEmailSuggestion('{concatenateDomain}','{type}')"><br>-->
@@ -70,9 +70,9 @@
 						<td width="40%" valign="bottom" bgcolor="#DDDDDD">
 							{lang_search_organization}:<br>
-							<input type="text" id="organization_search" autocomplete="off" size=20 onKeyUp="javascript:search_organization(this.value, 'ea_combo_org_groups');" onBlur="javascript:get_available_users(org_context.value, ea_check_allUsers.checked);">
+							<input type="text" id="organization_search" autocomplete="off" size=20 onKeyUp="javascript:search_organization(this.value, 'ea_combo_org_groups');" onBlur="javascript:get_available_users(org_context.value);">
 							<br>						
 						
 							{lang_organizations}:<br>
-							<select name="org_context" id="ea_combo_org_groups" onchange="javascript:get_available_users(this.value, ea_check_allUsers.checked);">{combo_all_orgs}</select>
+							<select name="org_context" id="ea_combo_org_groups" onchange="javascript:get_available_users(this.value);">{combo_all_orgs}</select>
 							
 							<br>
Index: sandbox/2.4.3-expresso-rest/expressoMail1_2/js/main.js
===================================================================
--- sandbox/2.4.3-expresso-rest/expressoMail1_2/js/main.js	(revision 7304)
+++ sandbox/2.4.3-expresso-rest/expressoMail1_2/js/main.js	(revision 7330)
@@ -709,5 +709,8 @@
 			//table_element.appendChild(Element("colgroup_main_"+numBox));
 			
-			$(table_element).append(Element("colgroup_main_"+numBox));
+			
+			if (!$("#colgroup_main_0").size()){
+				$(table_element).append(Element("colgroup_main_"+numBox));
+			}
 
 			if (data.msgs_to_delete.length > 0){
@@ -3851,5 +3854,16 @@
 	if(currentTab == 0)
 		msgs_number = get_selected_messages();
-
+	if (typeof currentTab == "string" && currentTab.indexOf("search_") != "-1"){
+		msgs_number = "";
+		var checked = $("#divScrollMain_"+currentTab.substr(currentTab.indexOf('_')+1,255)).find("tr input:checked");
+		$.each(checked,function(index,value){
+			if (value){
+				if (index == 0)
+					msgs_number = $(value).parents("tr").attr("id");
+				else
+					msgs_number += "," + $(value).parents("tr").attr("id");
+			}
+		});
+	}
 	if (parseInt(msgs_number) > 0 || msgs_number.length > 0)
 		cExecute ("$this.imap_functions.spam&folder="+folder+"&spam=false"+"&msgs_number="+msgs_number+"&border_ID="+border_ID+"&sort_box_type="+sort_box_type+"&sort_box_reverse="+sort_box_reverse+"&reuse_border="+border_ID+"&new_folder="+new_folder+"&new_folder_name="+new_folder_name+"&get_previous_msg="+0+"&cyrus_delimiter="+cyrus_delimiter, handler_move_msgs);
Index: sandbox/2.4.3-expresso-rest/expressoMail1_2/js/draw_api.js
===================================================================
--- sandbox/2.4.3-expresso-rest/expressoMail1_2/js/draw_api.js	(revision 7304)
+++ sandbox/2.4.3-expresso-rest/expressoMail1_2/js/draw_api.js	(revision 7330)
@@ -1165,5 +1165,5 @@
         });
 	}
-	else if (total_pages > 1){
+	else if (totalFolderMsgs > parseInt(preferences.max_email_per_page)){
 		div.html('<span class="none-selected">Nenhuma mensagem foi selecionada.</span>');
 	}
