'.$contactstatic->getNomUrl(1);
if ($obj->type == 'email')
{
if (isValidEmail($obj->email))
@@ -425,6 +424,16 @@ if ($result > 0)
$sql.= " AND n.fk_soc = ".$object->id;
$sql.= $db->order($sortfield, $sortorder);
+ // Count total nb of records
+ $nbtotalofrecords = '';
+ if (empty($conf->global->MAIN_DISABLE_FULL_SCANLIST))
+ {
+ $result = $db->query($sql);
+ $nbtotalofrecords = $db->num_rows($result);
+ }
+
+ $sql.= $db->plimit($limit+1, $offset);
+
$resql=$db->query($sql);
if ($resql)
{
@@ -435,9 +444,20 @@ if ($result > 0)
dol_print_error($db);
}
- // List of notifications done
- print load_fiche_titre($langs->trans("ListOfNotificationsDone").' ('.$num.')','','');
- $var=true;
+ $param='&socid='.$object->id;
+ if (! empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) $param.='&contextpage='.$contextpage;
+ if ($limit > 0 && $limit != $conf->liste_limit) $param.='&limit='.$limit;
+
+ print '';
}
else dol_print_error('','RecordNotFound');
diff --git a/htdocs/user/card.php b/htdocs/user/card.php
index 37a0042c137..e213578b860 100644
--- a/htdocs/user/card.php
+++ b/htdocs/user/card.php
@@ -723,11 +723,10 @@ if (($action == 'create') || ($action == 'adduserldap'))
print dol_set_focus('#lastname');
- print '';
-
- print '';
+ print '';
// Lastname
+ print '';
print '| '.$langs->trans("Lastname").' | ';
print '';
if (! empty($ldap_lastname))
@@ -1257,7 +1256,6 @@ else
dol_banner_tab($object,'id',$linkback,$user->rights->user->user->lire || $user->admin);
-
print '';
print ' ';
diff --git a/htdocs/user/notify/card.php b/htdocs/user/notify/card.php
index 305bb3d226b..f18197dccc8 100644
--- a/htdocs/user/notify/card.php
+++ b/htdocs/user/notify/card.php
@@ -44,15 +44,16 @@ $actionid=GETPOST('actionid');
if ($user->societe_id) $id=$user->societe_id;
$result = restrictedArea($user, 'societe','','');
-$sortfield = GETPOST("sortfield",'alpha');
-$sortorder = GETPOST("sortorder",'alpha');
-$page = GETPOST("page",'int');
-if ($page == -1) { $page = 0; }
-$offset = $conf->liste_limit * $page;
-$pageprev = $page - 1;
-$pagenext = $page + 1;
+$limit = GETPOST("limit")?GETPOST("limit","int"):$conf->liste_limit;
+$sortfield=GETPOST("sortfield",'alpha');
+$sortorder=GETPOST("sortorder",'alpha');
+$page=GETPOST("page",'int');
if (! $sortorder) $sortorder="DESC";
if (! $sortfield) $sortfield="n.daten";
+if (empty($page) || $page == -1) { $page = 0; }
+$offset = $limit * $page;
+$pageprev = $page - 1;
+$pagenext = $page + 1;
$now=dol_now();
@@ -135,12 +136,45 @@ if ($result > 0)
$head = user_prepare_head($object);
- dol_fiche_head($head, 'notify', $langs->trans("User"), 0, 'user');
+ dol_fiche_head($head, 'notify', $langs->trans("User"), -1, 'user');
$linkback = ' '.$langs->trans("BackToList").'';
- dol_banner_tab($object, 'id', $linkback, $user->rights->user->user->lire || $user->admin, 'rowid', 'ref', '', '', 0, '', '', 1, '');
+ dol_banner_tab($object, 'id', $linkback, $user->rights->user->user->lire || $user->admin, 'rowid', 'ref', '', '', 0, '', '', 0, '');
+ print ' ';
+
+ print ' ';
+ print ' ';
+
+ // Login
+ print '| '.$langs->trans("Login").' | ';
+ if (! empty($object->ldap_sid) && $object->statut==0)
+ {
+ print ''.$langs->trans("LoginAccountDisableInDolibarr").' | ';
+ }
+ else
+ {
+ print ''.$object->login.' | ';
+ }
+ print ' '."\n";
+
+ /*print '| '.$langs->trans("NbOfActiveNotifications").' | '; // Notification for this thirdparty
+ print '';
+ $nbofrecipientemails=0;
+ $notify=new Notify($db);
+ $tmparray = $notify->getNotificationsArray('', 0, null, $object->id, array('user'));
+ foreach($tmparray as $tmpkey => $tmpval)
+ {
+ $nbofrecipientemails++;
+ }
+ print $nbofrecipientemails;
+ print ' | ';*/
+
+ print ' ';
+
+ print ' ';
+
dol_fiche_end();
print "\n";
@@ -345,13 +379,13 @@ if ($result > 0)
print ' '.$langs->trans("SeeModuleSetup", $langs->transnoentitiesnoconv("Module600Name")).' | ';
print ' | ';
}*/
- if ($user->admin)
+ /*if ($user->admin)
{
$var = ! $var;
print '| ';
print '+ '.$langs->trans("SeeModuleSetup", $langs->transnoentitiesnoconv("Module600Name")).'';
print ' | ';
- }
+ }*/
print ' ';
@@ -364,12 +398,22 @@ if ($result > 0)
$sql.= " c.rowid as id, c.lastname, c.firstname, c.email as contactemail,";
$sql.= " a.code, a.label";
$sql.= " FROM ".MAIN_DB_PREFIX."c_action_trigger as a,";
- $sql.= " ".MAIN_DB_PREFIX."notify as n ";
+ $sql.= " ".MAIN_DB_PREFIX."notify as n";
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."user as c ON n.fk_user = c.rowid";
$sql.= " WHERE a.rowid = n.fk_action";
$sql.= " AND n.fk_user = ".$object->id;
$sql.= $db->order($sortfield, $sortorder);
+ // Count total nb of records
+ $nbtotalofrecords = '';
+ if (empty($conf->global->MAIN_DISABLE_FULL_SCANLIST))
+ {
+ $result = $db->query($sql);
+ $nbtotalofrecords = $db->num_rows($result);
+ }
+
+ $sql.= $db->plimit($limit+1, $offset);
+
$resql=$db->query($sql);
if ($resql)
{
@@ -380,10 +424,21 @@ if ($result > 0)
dol_print_error($db);
}
+ $param='&id='.$object->id;
+ if (! empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) $param.='&contextpage='.$contextpage;
+ if ($limit > 0 && $limit != $conf->liste_limit) $param.='&limit='.$limit;
+
+ print '';
}
else dol_print_error('','RecordNotFound');
|