Look and feel v12

This commit is contained in:
Laurent Destailleur 2020-04-02 15:11:46 +02:00
parent 386b27a14c
commit b8c2dd6025
7 changed files with 39 additions and 37 deletions

View File

@ -507,7 +507,7 @@ class AccountingAccount extends CommonObject
}
$label_link = length_accountg($this->account_number);
if ($withlabel) $label_link .= ' - ' . $labeltoshow;
if ($withlabel) $label_link .= ' - ' . ($nourl ? '<span class="opacitymedium">' : '').$labeltoshow.($nourl ? '</span>' : '');
if ($withpicto) $result.=($linkstart.img_object(($notooltip?'':$label), $picto, ($notooltip?'':'class="classfortooltip"'), 0, 0, $notooltip?0:1).$linkend);
if ($withpicto && $withpicto != 2) $result .= ' ';

View File

@ -266,7 +266,7 @@ class AccountingJournal extends CommonObject
}
$label_link = $this->code;
if ($withlabel) $label_link .= ' - '.$langs->transnoentities($this->label);
if ($withlabel) $label_link .= ' - '.($nourl ? '<span class="opacitymedium">' : '').$langs->transnoentities($this->label).($nourl ? '</span>' : '');
$result .= $linkstart;
if ($withpicto) $result .= img_object(($notooltip ? '' : $label), ($this->picto ? $this->picto : 'generic'), ($notooltip ? (($withpicto != 2) ? 'class="paddingright"' : '') : 'class="'.(($withpicto != 2) ? 'paddingright ' : '').'classfortooltip"'), 0, 0, $notooltip ? 0 : 1);

View File

@ -1,6 +1,6 @@
<?php
/* Copyright (C) 2005 Matthieu Valleton <mv@seeschloss.org>
* Copyright (C) 2006-2015 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2006-2020 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2007 Patrick Raguin <patrick.raguin@gmail.com>
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@inodbox.com>
* Copyright (C) 2015 Raphaël Doursenaud <rdoursenaud@gpcsolutions.fr>
@ -678,7 +678,7 @@ if ($type == Categorie::TYPE_MEMBER)
print '<br>';
$param = '&limit='.$limit.'&id='.$id.'&type='.$type; $num = count($prods); $nbtotalofrecords = ''; $newcardbutton = '';
print_barre_liste($langs->trans("Member"), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 'adherents', 0, $newcardbutton, '', $limit);
print_barre_liste($langs->trans("Member"), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 'members', 0, $newcardbutton, '', $limit);
print "<table class='noborder' width='100%'>\n";
print '<tr class="liste_titre"><td colspan="4">'.$langs->trans("Name").'</td></tr>'."\n";
@ -807,7 +807,7 @@ if ($type == Categorie::TYPE_ACCOUNT)
print '<br>';
$param = '&limit='.$limit.'&id='.$id.'&type='.$type; $num = count($accounts); $nbtotalofrecords = ''; $newcardbutton = '';
print_barre_liste($langs->trans("Account"), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 'account', 0, $newcardbutton, '', $limit);
print_barre_liste($langs->trans("Account"), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 'bank', 0, $newcardbutton, '', $limit);
print "<table class='noborder' width='100%'>\n";
print '<tr class="liste_titre"><td colspan="4">'.$langs->trans("Ref").'</td></tr>'."\n";
@ -872,7 +872,7 @@ if ($type == Categorie::TYPE_PROJECT)
print '<br>';
$param = '&limit='.$limit.'&id='.$id.'&type='.$type; $num = count($objects); $nbtotalofrecords = ''; $newcardbutton = '';
print_barre_liste($langs->trans("Project"), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 'projects', 0, $newcardbutton, '', $limit);
print_barre_liste($langs->trans("Project"), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 'project', 0, $newcardbutton, '', $limit);
print "<table class='noborder' width='100%'>\n";
print '<tr class="liste_titre"><td colspan="4">'.$langs->trans("Ref").'</td></tr>'."\n";

View File

@ -806,7 +806,7 @@ if ($resql)
$morehtml = '<div class="inline-block '.(($buttonreconcile || $newcardbutton) ? 'marginrightonly' : '').'">';
$morehtml .= '<label for="pageplusone">'.$langs->trans("Page")."</label> "; // ' Page ';
$morehtml .= '<input type="text" name="pageplusone" id="pageplusone" class="flat right width25" value="'.($page + 1).'">';
$morehtml .= '<input type="text" name="pageplusone" id="pageplusone" class="flat right width25 pageplusone" value="'.($page + 1).'">';
$morehtml .= '/'.$nbtotalofpages.' ';
$morehtml .= '</div>';
@ -1374,7 +1374,7 @@ if ($resql)
// Third party
if (!empty($arrayfields['bu.label']['checked']))
{
print "<td>";
print '<td class="tdoverflowmax150">';
if ($objp->url_id)
{
$companystatic->id = $objp->url_id;
@ -1520,13 +1520,13 @@ if ($resql)
{
if ($user->rights->banque->modifier || $user->rights->banque->consolidate)
{
print '<a href="'.DOL_URL_ROOT.'/compta/bank/line.php?save_lastsearch_values=1&amp;rowid='.$objp->rowid.'&amp;account='.$objp->bankid.'&amp;page='.$page.'">';
print '<a class="editfielda" href="'.DOL_URL_ROOT.'/compta/bank/line.php?save_lastsearch_values=1&amp;rowid='.$objp->rowid.'&amp;account='.$objp->bankid.'&amp;page='.$page.'">';
print img_edit();
print '</a>';
}
else
{
print '<a href="'.DOL_URL_ROOT.'/compta/bank/line.php?save_lastsearch_values=1&amp;rowid='.$objp->rowid.'&amp;account='.$objp->bankid.'&amp;page='.$page.'">';
print '<a class="editfielda" href="'.DOL_URL_ROOT.'/compta/bank/line.php?save_lastsearch_values=1&amp;rowid='.$objp->rowid.'&amp;account='.$objp->bankid.'&amp;page='.$page.'">';
print img_view();
print '</a>';
}
@ -1574,7 +1574,7 @@ if ($resql)
if ($i == 1)
{
if ($num < $limit && empty($offset)) print '<td class="left">'.$langs->trans("Total").'</td>';
else print '<td class="left">'.$langs->trans("Totalforthispage").'</td>';
else print '<td class="left tdoverflowmax50" title="'.$langs->trans("Totalforthispage").'">'.$langs->trans("Totalforthispage").'</td>';
}
elseif ($totalarray['totaldebfield'] == $i) print '<td class="right">'.price(-1 * $totalarray['totaldeb']).'</td>';
elseif ($totalarray['totalcredfield'] == $i) print '<td class="right">'.price($totalarray['totalcred']).'</td>';

View File

@ -138,7 +138,7 @@ if ($result)
{
print "<td >".$objp->label."</td>";
print '<td style="text-align: center;">';
print '<a href="'.$_SERVER["PHP_SELF"].'?categid='.$objp->rowid.'&amp;action=edit">'.img_edit().'</a>&nbsp;&nbsp;';
print '<a class="editfielda reposition" href="'.$_SERVER["PHP_SELF"].'?categid='.$objp->rowid.'&amp;action=edit">'.img_edit().'</a>&nbsp;&nbsp;';
print '<a href="'.$_SERVER["PHP_SELF"].'?categid='.$objp->rowid.'&amp;action=delete">'.img_delete().'</a>';
print '</td>';
}

View File

@ -304,14 +304,14 @@ if ($result)
print '<input type="hidden" name="orig_account" value="'.$orig_account.'">';
print '<input type="hidden" name="id" value="'.$acct->id.'">';
dol_fiche_head($tabs, 0, $langs->trans('LineRecord'), -1, 'account', 0);
dol_fiche_head($tabs, 0, $langs->trans('LineRecord'), 0, 'account', 0);
$linkback = '<a href="'.DOL_URL_ROOT.'/compta/bank/bankentries_list.php?restore_lastsearch_values=1">'.$langs->trans("BackToList").'</a>';
dol_banner_tab($bankline, 'rowid', $linkback);
print '<div class="fichecenter">';
print '<div class="fichecenter2">';
print '<div class="underbanner clearboth"></div>';
print '<table class="border centpercent">';

View File

@ -313,14 +313,14 @@ print '<tr class="liste_titre_filter">';
if (!empty($arrayfields['b.ref']['checked']))
{
print '<td class="liste_titre">';
print '<input class="flat" size="6" type="text" name="search_ref" value="'.$search_ref.'">';
print '<input class="flat" size="6" type="text" name="search_ref" value="'.dol_escape_htmltag($search_ref).'">';
print '</td>';
}
// Label
if (!empty($arrayfields['b.label']['checked']))
{
print '<td class="liste_titre">';
print '<input class="flat" size="6" type="text" name="search_label" value="'.$search_label.'">';
print '<input class="flat" size="6" type="text" name="search_label" value="'.dol_escape_htmltag($search_label).'">';
print '</td>';
}
// Account type
@ -333,7 +333,7 @@ if (!empty($arrayfields['accountype']['checked']))
if (!empty($arrayfields['b.number']['checked']))
{
print '<td class="liste_titre">';
print '<input class="flat" size="6" type="text" name="search_number" value="'.$search_number.'">';
print '<input class="flat" size="6" type="text" name="search_number" value="'.dol_escape_htmltag($search_number).'">';
print '</td>';
}
// Account number
@ -527,26 +527,28 @@ foreach ($accounts as $key=>$type)
// Transactions to reconcile
if (!empty($arrayfields['toreconcile']['checked']))
{
print '<td class="center">';
if ($objecttmp->rappro)
{
$result = $objecttmp->load_board($user, $objecttmp->id);
if ($result < 0) {
setEventMessages($objecttmp->error, $objecttmp->errors, 'errors');
} else {
print '<span class="badge badge-info classfortooltip" title="'.dol_htmlentities($langs->trans("TransactionsToConciliate")).'">'.$result->nbtodo.'</span>';
if ($result->nbtodolate) {
print '<span title="'.dol_htmlentities($langs->trans("Late")).'" class="classfortooltip badge badge-danger marginleftonlyshort">';
print '<i class="fa fa-exclamation-triangle"></i> '.$result->nbtodolate;
print '</span>';
}
}
}
else
{
print '<span class="opacitymedium">'.$langs->trans("FeatureDisabled").'</span>';
}
print '</td>';
print '<td class="center">';
$conciliate = $objecttmp->canBeConciliated();
if ($conciliate == -2) print '<span class="opacitymedium">'.$langs->trans("CashAccount").'</span>';
elseif ($conciliate == -3) print '<span class="opacitymedium">'.$langs->trans("Closed").'</span>';
elseif (empty($objecttmp->rappro)) {
print '<span class="opacitymedium">'.$langs->trans("ConciliationDisabled").'</span>';
} else {
$result = $objecttmp->load_board($user, $objecttmp->id);
if ($result < 0) {
setEventMessages($objecttmp->error, $objecttmp->errors, 'errors');
} else {
print '<span class="badge badge-info classfortooltip" title="'.dol_htmlentities($langs->trans("TransactionsToConciliate")).'">'.$result->nbtodo.'</span>';
if ($result->nbtodolate) {
print '<span title="'.dol_htmlentities($langs->trans("Late")).'" class="classfortooltip badge badge-danger marginleftonlyshort">';
print '<i class="fa fa-exclamation-triangle"></i> '.$result->nbtodolate;
print '</span>';
}
}
}
print '</td>';
if (!$i) $totalarray['nbfield']++;
}