diff --git a/htdocs/comm/action/index.php b/htdocs/comm/action/index.php
index 95306a9d611..070c3e7f60a 100644
--- a/htdocs/comm/action/index.php
+++ b/htdocs/comm/action/index.php
@@ -346,8 +346,8 @@ if ($resourceid > 0) $param .= "&search_resourceid=".urlencode($resourceid);
if ($status || GETPOSTISSET('status')) $param .= "&search_status=".urlencode($status);
if ($filter) $param .= "&search_filter=".urlencode($filter);
if ($filtert) $param .= "&search_filtert=".urlencode($filtert);
-if ($usergroup) $param .= "&search_usergroup=".urlencode($usergroup);
-if ($socid) $param .= "&search_socid=".urlencode($socid);
+if ($usergroup > 0) $param .= "&search_usergroup=".urlencode($usergroup);
+if ($socid > 0) $param .= "&search_socid=".urlencode($socid);
if ($showbirthday) $param .= "&search_showbirthday=1";
if ($pid) $param .= "&search_projectid=".urlencode($pid);
if ($type) $param .= "&search_type=".urlencode($type);
@@ -357,32 +357,32 @@ $param .= "&maxprint=".urlencode($maxprint);
// Show navigation bar
if (empty($action) || $action == 'show_month')
{
- $nav = " \n";
+ $nav = " \n";
$nav .= " ".dol_print_date(dol_mktime(0, 0, 0, $month, 1, $year), "%b %Y");
$nav .= " \n";
- $nav .= " \n";
+ $nav .= " \n";
if (empty($conf->dol_optimize_smallscreen)) {
- $nav .= " ".$langs->trans("Today")." ";
+ $nav .= " ".$langs->trans("Today")." ";
}
$picto = 'calendar';
}
if ($action == 'show_week')
{
- $nav = "trans("Previous"))."\"> \n";
+ $nav = "trans("Previous"))."\"> \n";
$nav .= " ".dol_print_date(dol_mktime(0, 0, 0, $first_month, $first_day, $first_year), "%Y").", ".$langs->trans("Week")." ".$week;
$nav .= " \n";
- $nav .= " trans("Next"))."\">\n";
+ $nav .= " trans("Next"))."\">\n";
if (empty($conf->dol_optimize_smallscreen)) {
- $nav .= " ".$langs->trans("Today")." ";
+ $nav .= " ".$langs->trans("Today")." ";
}
$picto = 'calendarweek';
}
if ($action == 'show_day')
{
- $nav = " \n";
+ $nav = " \n";
$nav .= " ".dol_print_date(dol_mktime(0, 0, 0, $month, $day, $year), "daytextshort");
$nav .= " \n";
- $nav .= " \n";
+ $nav .= " \n";
if (empty($conf->dol_optimize_smallscreen)) {
$nav .= " ".$langs->trans("Today")." ";
}
@@ -394,6 +394,7 @@ $nav .= $form->selectDate($dateselect, 'dateselect', 0, 0, 1, '', 1, 0);
$nav .= '';
// Must be after the nav definition
+$paramnodate = $param;
$param .= '&year='.$year.'&month='.$month.($day ? '&day='.$day : '');
//print 'x'.$param;
@@ -410,6 +411,7 @@ if ($action == 'show_pertype') $tabactive = 'cardpertype';
*/
$paramnoaction = preg_replace('/action=[a-z_]+/', '', $param);
+$paramnoactionodate = preg_replace('/action=[a-z_]+/', '', $paramnodate);
$head = calendars_prepare_head($paramnoaction);
@@ -422,31 +424,31 @@ print '';
//print dol_get_fiche_end();
$viewmode = '';
-$viewmode .= '';
+$viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("List"), 'object_list-alt', 'class="pictoactionview block"');
//$viewmode .= '';
$viewmode .= ''.$langs->trans("ViewList").'';
-$viewmode .= '';
+$viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("ViewCal"), 'object_calendar', 'class="pictoactionview block"');
//$viewmode .= '';
$viewmode .= ''.$langs->trans("ViewCal").'';
-$viewmode .= '';
+$viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("ViewWeek"), 'object_calendarweek', 'class="pictoactionview block"');
//$viewmode .= '';
$viewmode .= ''.$langs->trans("ViewWeek").'';
-$viewmode .= '';
+$viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("ViewDay"), 'object_calendarday', 'class="pictoactionview block"');
//$viewmode .= '';
$viewmode .= ''.$langs->trans("ViewDay").'';
-$viewmode .= '';
+$viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("ViewPerUser"), 'object_calendarperuser', 'class="pictoactionview block"');
//$viewmode .= '';
diff --git a/htdocs/comm/action/list.php b/htdocs/comm/action/list.php
index 782b9169c42..68925c57bfa 100644
--- a/htdocs/comm/action/list.php
+++ b/htdocs/comm/action/list.php
@@ -269,11 +269,11 @@ if ($resourceid > 0) $param .= "&search_resourceid=".urlencode($resourceid);
if ($search_status != '' && $search_status > -1) $param .= "&search_status=".urlencode($search_status);
if ($filter) $param .= "&search_filter=".urlencode($filter);
if ($filtert) $param .= "&search_filtert=".urlencode($filtert);
-if ($socid) $param .= "&search_socid=".urlencode($socid);
+if ($usergroup > 0) $param .= "&search_usergroup=".urlencode($usergroup);
+if ($socid > 0) $param .= "&search_socid=".urlencode($socid);
if ($showbirthday) $param .= "&search_showbirthday=1";
if ($pid) $param .= "&search_projectid=".urlencode($pid);
if ($type) $param .= "&search_type=".urlencode($type);
-if ($usergroup) $param .= "&search_usergroup=".urlencode($usergroup);
if ($search_id != '') $param .= '&search_title='.urlencode($search_id);
if ($search_title != '') $param .= '&search_title='.urlencode($search_title);
if ($search_note != '') $param .= '&search_note='.$search_note;
@@ -287,6 +287,8 @@ if ($optioncss != '') $param .= '&optioncss='.urlencode($optioncss);
// Add $param from extra fields
include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_search_param.tpl.php';
+$paramnoactionodate = $param;
+
// List of mass actions available
$arrayofmassactions = array(
'set_all_events_to_todo' => $langs->trans("SetAllEventsToTodo"),
@@ -481,31 +483,31 @@ if ($resql)
}
$viewmode = '';
- $viewmode .= '';
+ $viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("List"), 'object_list-alt', 'class="pictoactionview block"');
//$viewmode .= '';
$viewmode .= ''.$langs->trans("ViewList").'';
- $viewmode .= '';
+ $viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("ViewCal"), 'object_calendar', 'class="pictoactionview block"');
//$viewmode .= '';
$viewmode .= ''.$langs->trans("ViewCal").'';
- $viewmode .= '';
+ $viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("ViewWeek"), 'object_calendarweek', 'class="pictoactionview block"');
//$viewmode .= '';
$viewmode .= ''.$langs->trans("ViewWeek").'';
- $viewmode .= '';
+ $viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("ViewDay"), 'object_calendarday', 'class="pictoactionview block"');
//$viewmode .= '';
$viewmode .= ''.$langs->trans("ViewDay").'';
- $viewmode .= '';
+ $viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("ViewPerUser"), 'object_calendarperuser', 'class="pictoactionview block"');
//$viewmode .= '';
diff --git a/htdocs/comm/action/pertype.php b/htdocs/comm/action/pertype.php
index b1ce13eb17f..613ffee7be7 100644
--- a/htdocs/comm/action/pertype.php
+++ b/htdocs/comm/action/pertype.php
@@ -236,8 +236,8 @@ if ($resourceid > 0) $param .= "&search_resourceid=".urlencode($resourceid);
if ($status || GETPOSTISSET('status')) $param .= "&search_status=".urlencode($status);
if ($filter) $param .= "&search_filter=".urlencode($filter);
if ($filtert) $param .= "&search_filtert=".urlencode($filtert);
-if ($usergroup) $param .= "&search_usergroup=".urlencode($usergroup);
-if ($socid) $param .= "&search_socid=".urlencode($socid);
+if ($usergroup > 0) $param .= "&search_usergroup=".urlencode($usergroup);
+if ($socid > 0) $param .= "&search_socid=".urlencode($socid);
if ($showbirthday) $param .= "&search_showbirthday=1";
if ($pid) $param .= "&search_projectid=".urlencode($pid);
if ($type) $param .= "&search_type=".urlencode($type);
@@ -248,6 +248,8 @@ if ($begin_d != '') $param .= '&begin_d='.urlencode($begin_d);
if ($end_d != '') $param .= '&end_d='.urlencode($end_d);
$param .= "&maxprint=".urlencode($maxprint);
+$paramnoactionodate = $param;
+
$prev = dol_get_first_day($year, 1);
$prev_year = $year - 1;
$prev_month = $month;
@@ -352,31 +354,31 @@ if ($conf->use_javascript_ajax)
$massactionbutton = '';
$viewmode = '';
-$viewmode .= '';
+$viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("List"), 'object_list-alt', 'class="pictoactionview block"');
//$viewmode .= '';
$viewmode .= ''.$langs->trans("ViewList").'';
-$viewmode .= '';
+$viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("ViewCal"), 'object_calendar', 'class="pictoactionview block"');
//$viewmode .= '';
$viewmode .= ''.$langs->trans("ViewCal").'';
-$viewmode .= '';
+$viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("ViewWeek"), 'object_calendarweek', 'class="pictoactionview block"');
//$viewmode .= '';
$viewmode .= ''.$langs->trans("ViewWeek").'';
-$viewmode .= '';
+$viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("ViewDay"), 'object_calendarday', 'class="pictoactionview block"');
//$viewmode .= '';
$viewmode .= ''.$langs->trans("ViewDay").'';
-$viewmode .= '';
+$viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("ViewPerUser"), 'object_calendarperuser', 'class="pictoactionview block"');
//$viewmode .= '';
diff --git a/htdocs/comm/action/peruser.php b/htdocs/comm/action/peruser.php
index 19b4cca2fc6..34a4cc232b6 100644
--- a/htdocs/comm/action/peruser.php
+++ b/htdocs/comm/action/peruser.php
@@ -236,8 +236,8 @@ if ($resourceid > 0) $param .= "&search_resourceid=".urlencode($resourceid);
if ($status || GETPOSTISSET('status')) $param .= "&search_status=".urlencode($status);
if ($filter) $param .= "&search_filter=".urlencode($filter);
if ($filtert) $param .= "&search_filtert=".urlencode($filtert);
-if ($usergroup) $param .= "&search_usergroup=".urlencode($usergroup);
-if ($socid) $param .= "&search_socid=".urlencode($socid);
+if ($usergroup > 0) $param .= "&search_usergroup=".urlencode($usergroup);
+if ($socid > 0) $param .= "&search_socid=".urlencode($socid);
if ($showbirthday) $param .= "&search_showbirthday=1";
if ($pid) $param .= "&search_projectid=".urlencode($pid);
if ($type) $param .= "&search_type=".urlencode($type);
@@ -248,6 +248,7 @@ if ($begin_d != '') $param .= '&begin_d='.urlencode($begin_d);
if ($end_d != '') $param .= '&end_d='.urlencode($end_d);
$param .= "&maxprint=".urlencode($maxprint);
+$paramnoactionodate = $param;
$prev = dol_get_first_day_week($day, $month, $year);
//print "day=".$day." month=".$month." year=".$year;
@@ -357,31 +358,31 @@ if ($conf->use_javascript_ajax)
$massactionbutton = '';
$viewmode = '';
-$viewmode .= '';
+$viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("List"), 'object_list-alt', 'class="pictoactionview block"');
//$viewmode .= '';
$viewmode .= ''.$langs->trans("ViewList").'';
-$viewmode .= '';
+$viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("ViewCal"), 'object_calendar', 'class="pictoactionview block"');
//$viewmode .= '';
$viewmode .= ''.$langs->trans("ViewCal").'';
-$viewmode .= '';
+$viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("ViewWeek"), 'object_calendarweek', 'class="pictoactionview block"');
//$viewmode .= '';
$viewmode .= ''.$langs->trans("ViewWeek").'';
-$viewmode .= '';
+$viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("ViewDay"), 'object_calendarday', 'class="pictoactionview block"');
//$viewmode .= '';
$viewmode .= ''.$langs->trans("ViewDay").'';
-$viewmode .= '';
+$viewmode .= '';
//$viewmode .= '';
$viewmode .= img_picto($langs->trans("ViewPerUser"), 'object_calendarperuser', 'class="pictoactionview block"');
//$viewmode .= '';