Standardize GUI

This commit is contained in:
Laurent Destailleur 2024-04-12 02:00:13 +02:00
parent 93507620ca
commit 0f1369a192
3 changed files with 8 additions and 5 deletions

View file

@ -55,7 +55,7 @@ if (!$sortorder) {
$sortorder = "DESC";
}
if (!$sortfield) {
$sortfield = "d.date_create";
$sortfield = "d.tms";
}
$limit = GETPOSTINT('limit') ? GETPOSTINT('limit') : $conf->liste_limit;

View file

@ -281,7 +281,7 @@ if (isModEnabled('holiday') && $user->hasRight('holiday', 'read')) {
// Latest modified expense report
if (isModEnabled('expensereport') && $user->hasRight('expensereport', 'read')) {
$sql = "SELECT u.rowid as uid, u.lastname, u.firstname, u.login, u.email, u.statut as user_status, u.photo,";
$sql .= " x.rowid, x.ref, x.date_debut as date, x.tms as dm, x.total_ttc, x.fk_statut as status";
$sql .= " x.rowid, x.ref, x.date_debut as date, x.tms as dm, x.total_ht, x.total_ttc, x.fk_statut as status";
$sql .= " FROM ".MAIN_DB_PREFIX."expensereport as x, ".MAIN_DB_PREFIX."user as u";
//if (empty($user->rights->societe->client->voir) && !$user->socid) $sql.= ", ".MAIN_DB_PREFIX."societe as s, ".MAIN_DB_PREFIX."societe_commerciaux as sc";
$sql .= " WHERE u.rowid = x.fk_user_author";
@ -304,6 +304,7 @@ if (isModEnabled('expensereport') && $user->hasRight('expensereport', 'read')) {
print '<table class="noborder centpercent">';
print '<tr class="liste_titre">';
print '<th colspan="2">'.$langs->trans("BoxTitleLastModifiedExpenses", min($max, $num)).'</th>';
print '<th class="right">'.$langs->trans("AmountHT").'</th>';
print '<th class="right">'.$langs->trans("TotalTTC").'</th>';
print '<th></th>';
print '<th class="right"><a href="'.DOL_URL_ROOT.'/expensereport/list.php?sortfield=d.tms&sortorder=DESC">';
@ -333,6 +334,7 @@ if (isModEnabled('expensereport') && $user->hasRight('expensereport', 'read')) {
print '<tr class="oddeven">';
print '<td class="tdoverflowmax200">'.$expensereportstatic->getNomUrl(1).'</td>';
print '<td class="tdoverflowmax150">'.$userstatic->getNomUrl(-1).'</td>';
print '<td class="right amount">'.price($obj->total_ht).'</td>';
print '<td class="right amount">'.price($obj->total_ttc).'</td>';
print '<td class="right">'.dol_print_date($db->jdate($obj->dm), 'day').'</td>';
print '<td class="right nowraponall" width="16">'.$expensereportstatic->LibStatut($obj->status, 3).'</td>';

View file

@ -87,12 +87,13 @@ if ($user->hasRight('projet', 'all', 'lire') && !$socid) {
$morehtml = '';
$morehtml .= '<form name="projectform">';
$morehtml .= '<SELECT name="mode">';
$morehtml .= '<form name="projectform" method="POST">';
$morehtml .= '<SELECT name="mode" id="search_project_user">';
$morehtml .= '<option name="all" value="all"'.($mine ? '' : ' selected').'>'.$titleall.'</option>';
$morehtml .= '<option name="mine" value="'.$user->id.'"'.(($search_project_user == $user->id) ? ' selected' : '').'>'.$langs->trans("ProjectsImContactFor").'</option>';
$morehtml .= '</SELECT>';
$morehtml .= '<input type="submit" class="button" name="refresh" value="'.$langs->trans("Refresh").'">';
$morehtml .= ajax_combobox("search_project_user", array(), 0, 0, 'resolve', '-1', 'small');
$morehtml .= '<input type="submit" class="button smallpaddingimp" name="refresh" value="'.$langs->trans("Refresh").'">';
if ($mine) {
$tooltiphelp = $langs->trans("MyTasksDesc");