mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-02-20 13:46:52 +01:00
prepare new dashboard
This commit is contained in:
parent
9e92b73d4a
commit
9b84987cc1
|
|
@ -2315,6 +2315,7 @@ class Adherent extends CommonObject
|
|||
$response = new WorkboardResponse();
|
||||
$response->warning_delay=$conf->adherent->subscription->warning_delay/60/60/24;
|
||||
$response->label=$langs->trans("MembersWithSubscriptionToReceive");
|
||||
$response->labelShort=$langs->trans("MembersWithSubscriptionToReceiveShort");
|
||||
$response->url=DOL_URL_ROOT.'/adherents/list.php?mainmenu=members&statut=1&filter=outofdate';
|
||||
$response->img=img_object('', "user");
|
||||
|
||||
|
|
|
|||
|
|
@ -1103,6 +1103,7 @@ class ActionComm extends CommonObject
|
|||
$response = new WorkboardResponse();
|
||||
$response->warning_delay = $conf->agenda->warning_delay/60/60/24;
|
||||
$response->label = $langs->trans("ActionsToDo");
|
||||
$response->labelShort = $langs->trans("ActionsToDoShort");
|
||||
$response->url = DOL_URL_ROOT.'/comm/action/list.php?actioncode=0&status=todo&mainmenu=agenda';
|
||||
if ($user->rights->agenda->allactions->read) $response->url.='&filtert=-1';
|
||||
$response->img = img_object('', "action", 'class="inline-block valigntextmiddle"');
|
||||
|
|
|
|||
|
|
@ -3277,21 +3277,24 @@ class Propal extends CommonObject
|
|||
|
||||
$delay_warning = 0;
|
||||
$statut = 0;
|
||||
$label = '';
|
||||
$label = $labelShort = '';
|
||||
if ($mode == 'opened') {
|
||||
$delay_warning=$conf->propal->cloture->warning_delay;
|
||||
$statut = self::STATUS_VALIDATED;
|
||||
$label = $langs->trans("PropalsToClose");
|
||||
$labelShort = $langs->trans("ToClose");
|
||||
}
|
||||
if ($mode == 'signed') {
|
||||
$delay_warning=$conf->propal->facturation->warning_delay;
|
||||
$statut = self::STATUS_SIGNED;
|
||||
$label = $langs->trans("PropalsToBill"); // We set here bill but may be billed or ordered
|
||||
$labelShort = $langs->trans("ToBill");
|
||||
}
|
||||
|
||||
$response = new WorkboardResponse();
|
||||
$response->warning_delay = $delay_warning/60/60/24;
|
||||
$response->label = $label;
|
||||
$response->labelShort = $labelShort;
|
||||
$response->url = DOL_URL_ROOT.'/comm/propal/list.php?viewstatut='.$statut.'&mainmenu=commercial&leftmenu=propals';
|
||||
$response->url_late = DOL_URL_ROOT.'/comm/propal/list.php?viewstatut='.$statut.'&mainmenu=commercial&leftmenu=propals&sortfield=p.datep&sortorder=asc';
|
||||
$response->img = img_object('', "propal");
|
||||
|
|
|
|||
|
|
@ -3411,6 +3411,7 @@ class Commande extends CommonOrder
|
|||
$response = new WorkboardResponse();
|
||||
$response->warning_delay=$conf->commande->client->warning_delay/60/60/24;
|
||||
$response->label=$langs->trans("OrdersToProcess");
|
||||
$response->labelShort = $langs->trans("ToProcess");
|
||||
$response->url=DOL_URL_ROOT.'/commande/list.php?viewstatut=-3&mainmenu=commercial&leftmenu=orders';
|
||||
$response->img=img_object('', "order");
|
||||
|
||||
|
|
|
|||
|
|
@ -3889,6 +3889,7 @@ class Facture extends CommonInvoice
|
|||
$response = new WorkboardResponse();
|
||||
$response->warning_delay=$conf->facture->client->warning_delay/60/60/24;
|
||||
$response->label=$langs->trans("CustomerBillsUnpaid");
|
||||
$response->labelShort=$langs->trans("Unpaid");
|
||||
$response->url=DOL_URL_ROOT.'/compta/facture/list.php?search_status=1&mainmenu=billing&leftmenu=customers_bills';
|
||||
$response->img=img_object('', "bill");
|
||||
|
||||
|
|
|
|||
|
|
@ -2186,23 +2186,27 @@ class Contrat extends CommonObject
|
|||
if ($mode == 'inactive') {
|
||||
$warning_delay = $conf->contrat->services->inactifs->warning_delay;
|
||||
$label = $langs->trans("BoardNotActivatedServices");
|
||||
$labelShort = $langs->trans("BoardNotActivatedServicesShort");
|
||||
$url = DOL_URL_ROOT.'/contrat/services_list.php?mainmenu=commercial&leftmenu=contracts&mode=0&sortfield=cd.date_fin_validite&sortorder=asc';
|
||||
}
|
||||
elseif ($mode == 'expired') {
|
||||
$warning_delay = $conf->contrat->services->expires->warning_delay;
|
||||
$url = DOL_URL_ROOT.'/contrat/services_list.php?mainmenu=commercial&leftmenu=contracts&mode=4&filter=expired&sortfield=cd.date_fin_validite&sortorder=asc';
|
||||
$label = $langs->trans("BoardExpiredServices");
|
||||
$labelShort = $langs->trans("BoardExpiredServicesShort");
|
||||
} else {
|
||||
$warning_delay = $conf->contrat->services->expires->warning_delay;
|
||||
$url = DOL_URL_ROOT.'/contrat/services_list.php?mainmenu=commercial&leftmenu=contracts&mode=4&sortfield=cd.date_fin_validite&sortorder=asc';
|
||||
//$url.= '&op2day='.$arraydatetouse['mday'].'&op2month='.$arraydatetouse['mon'].'&op2year='.$arraydatetouse['year'];
|
||||
//if ($warning_delay >= 0) $url.='&filter=expired';
|
||||
$label = $langs->trans("BoardRunningServices");
|
||||
$labelShort = $langs->trans("BoardRunningServicesShort");
|
||||
}
|
||||
|
||||
$response = new WorkboardResponse();
|
||||
$response->warning_delay = $warning_delay/60/60/24;
|
||||
$response->label = $label;
|
||||
$response->labelShort = $labelShort;
|
||||
$response->url = $url;
|
||||
$response->img = img_object('', "contract");
|
||||
|
||||
|
|
|
|||
|
|
@ -37,6 +37,18 @@ class WorkboardResponse
|
|||
*/
|
||||
public $label;
|
||||
|
||||
/**
|
||||
* Short Label of the warning
|
||||
* @var string
|
||||
*/
|
||||
public $labelShort;
|
||||
|
||||
/**
|
||||
* infoKey of the warning
|
||||
* @var string
|
||||
*/
|
||||
public $infoKey = 'todo';
|
||||
|
||||
/**
|
||||
* URL to list to do items
|
||||
* @var string
|
||||
|
|
|
|||
|
|
@ -2333,12 +2333,14 @@ class ExpenseReport extends CommonObject
|
|||
{
|
||||
$response->warning_delay=$conf->expensereport->approve->warning_delay/60/60/24;
|
||||
$response->label=$langs->trans("ExpenseReportsToApprove");
|
||||
$response->labelShort=$langs->trans("ToApprove");
|
||||
$response->url=DOL_URL_ROOT.'/expensereport/list.php?mainmenu=hrm&statut=2';
|
||||
}
|
||||
else
|
||||
{
|
||||
$response->warning_delay=$conf->expensereport->payment->warning_delay/60/60/24;
|
||||
$response->label=$langs->trans("ExpenseReportsToPay");
|
||||
$response->labelShort=$langs->trans("ToPay");
|
||||
$response->url=DOL_URL_ROOT.'/expensereport/list.php?mainmenu=hrm&statut=5';
|
||||
}
|
||||
$response->img=img_object('', "trip");
|
||||
|
|
|
|||
|
|
@ -2835,6 +2835,7 @@ class CommandeFournisseur extends CommonOrder
|
|||
$response = new WorkboardResponse();
|
||||
$response->warning_delay=$conf->commande->fournisseur->warning_delay/60/60/24;
|
||||
$response->label=$langs->trans("SuppliersOrdersToProcess");
|
||||
$response->labelShort=$langs->trans("ToProcess");
|
||||
$response->url=DOL_URL_ROOT.'/fourn/commande/list.php?statut=1,2,3&mainmenu=commercial&leftmenu=orders_suppliers';
|
||||
$response->img=img_object('', "order");
|
||||
|
||||
|
|
|
|||
|
|
@ -2213,6 +2213,7 @@ class FactureFournisseur extends CommonInvoice
|
|||
$response = new WorkboardResponse();
|
||||
$response->warning_delay=$conf->facture->fournisseur->warning_delay/60/60/24;
|
||||
$response->label=$langs->trans("SupplierBillsToPay");
|
||||
$response->labelShort=$langs->trans("ToPay");
|
||||
|
||||
$response->url=DOL_URL_ROOT.'/fourn/facture/list.php?search_status=1&mainmenu=billing&leftmenu=suppliers_bills';
|
||||
$response->img=img_object($langs->trans("Bills"), "bill");
|
||||
|
|
|
|||
|
|
@ -2243,6 +2243,7 @@ class Holiday extends CommonObject
|
|||
$response = new WorkboardResponse();
|
||||
$response->warning_delay=$conf->holiday->approve->warning_delay/60/60/24;
|
||||
$response->label=$langs->trans("HolidaysToApprove");
|
||||
$response->labelShort=$langs->trans("ToApprove");
|
||||
$response->url=DOL_URL_ROOT.'/holiday/list.php?search_statut=2&mainmenu=hrm&leftmenu=holiday';
|
||||
$response->img=img_object('', "holiday");
|
||||
|
||||
|
|
|
|||
223
htdocs/index.php
223
htdocs/index.php
|
|
@ -374,13 +374,15 @@ $dashboardlines=array();
|
|||
// Do not include sections without management permission
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/workboardresponse.class.php';
|
||||
|
||||
|
||||
|
||||
// Number of actions to do (late)
|
||||
if (! empty($conf->agenda->enabled) && $user->rights->agenda->myactions->read)
|
||||
{
|
||||
include_once DOL_DOCUMENT_ROOT.'/comm/action/class/actioncomm.class.php';
|
||||
$board=new ActionComm($db);
|
||||
|
||||
$dashboardlines[] = $board->load_board($user);
|
||||
$workBoard = $board->load_board($user);
|
||||
$dashboardlines[$board->element] = $workBoard; // deprecated
|
||||
}
|
||||
|
||||
// Number of project opened
|
||||
|
|
@ -388,7 +390,8 @@ if (! empty($conf->projet->enabled) && $user->rights->projet->lire)
|
|||
{
|
||||
include_once DOL_DOCUMENT_ROOT.'/projet/class/project.class.php';
|
||||
$board=new Project($db);
|
||||
$dashboardlines[] = $board->load_board($user);
|
||||
$workBoard = $board->load_board($user);
|
||||
$dashboardlines[$board->element] = $workBoard;
|
||||
}
|
||||
|
||||
// Number of tasks to do (late)
|
||||
|
|
@ -396,7 +399,8 @@ if (! empty($conf->projet->enabled) && empty($conf->global->PROJECT_HIDE_TASKS)
|
|||
{
|
||||
include_once DOL_DOCUMENT_ROOT.'/projet/class/task.class.php';
|
||||
$board=new Task($db);
|
||||
$dashboardlines[] = $board->load_board($user);
|
||||
$workBoard = $board->load_board($user);
|
||||
$dashboardlines[$board->element] = $workBoard;
|
||||
}
|
||||
|
||||
// Number of commercial proposals opened (expired)
|
||||
|
|
@ -404,9 +408,13 @@ if (! empty($conf->propal->enabled) && $user->rights->propale->lire)
|
|||
{
|
||||
include_once DOL_DOCUMENT_ROOT.'/comm/propal/class/propal.class.php';
|
||||
$board=new Propal($db);
|
||||
$dashboardlines[] = $board->load_board($user, "opened");
|
||||
// Number of commercial proposals CLOSED signed (billed)
|
||||
$dashboardlines[] = $board->load_board($user, "signed");
|
||||
|
||||
$workBoard = $board->load_board($user, "opened");
|
||||
$dashboardlines[$board->element.'_opened'] = $workBoard;
|
||||
|
||||
$workBoard = $board->load_board($user, "signed");
|
||||
$dashboardlines[$board->element.'_signed'] = $workBoard;
|
||||
|
||||
}
|
||||
|
||||
// Number of commercial proposals opened (expired)
|
||||
|
|
@ -414,9 +422,13 @@ if (! empty($conf->supplier_proposal->enabled) && $user->rights->supplier_propos
|
|||
{
|
||||
include_once DOL_DOCUMENT_ROOT.'/supplier_proposal/class/supplier_proposal.class.php';
|
||||
$board=new SupplierProposal($db);
|
||||
$dashboardlines[] = $board->load_board($user, "opened");
|
||||
|
||||
$workBoard = $board->load_board($user, "opened");
|
||||
$dashboardlines[$board->element.'_opened'] = $workBoard;
|
||||
|
||||
// Number of commercial proposals CLOSED signed (billed)
|
||||
$dashboardlines[] = $board->load_board($user, "signed");
|
||||
$workBoard = $board->load_board($user, "signed");
|
||||
$dashboardlines[$board->element.'_signed'] = $workBoard;
|
||||
}
|
||||
|
||||
// Number of customer orders a deal
|
||||
|
|
@ -424,7 +436,8 @@ if (! empty($conf->commande->enabled) && $user->rights->commande->lire)
|
|||
{
|
||||
include_once DOL_DOCUMENT_ROOT.'/commande/class/commande.class.php';
|
||||
$board=new Commande($db);
|
||||
$dashboardlines[] = $board->load_board($user);
|
||||
$workBoard = $board->load_board($user);
|
||||
$dashboardlines[$board->element] = $workBoard;
|
||||
}
|
||||
|
||||
// Number of suppliers orders a deal
|
||||
|
|
@ -432,7 +445,8 @@ if (! empty($conf->supplier_order->enabled) && $user->rights->fournisseur->comma
|
|||
{
|
||||
include_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.commande.class.php';
|
||||
$board=new CommandeFournisseur($db);
|
||||
$dashboardlines[] = $board->load_board($user);
|
||||
$workBoard = $board->load_board($user);
|
||||
$dashboardlines[$board->element] = $workBoard;
|
||||
}
|
||||
|
||||
// Number of services enabled (delayed)
|
||||
|
|
@ -440,16 +454,20 @@ if (! empty($conf->contrat->enabled) && $user->rights->contrat->lire)
|
|||
{
|
||||
include_once DOL_DOCUMENT_ROOT.'/contrat/class/contrat.class.php';
|
||||
$board=new Contrat($db);
|
||||
$dashboardlines[] = $board->load_board($user, "inactive");
|
||||
$workBoard = $board->load_board($user, "inactive");
|
||||
$dashboardlines[$board->element.'_inactive'] = $workBoard;
|
||||
|
||||
// Number of active services (expired)
|
||||
$dashboardlines[] = $board->load_board($user, "active");
|
||||
$workBoard = $board->load_board($user, "active");
|
||||
$dashboardlines[$board->element.'_active'] = $workBoard;
|
||||
}
|
||||
// Number of invoices customers (has paid)
|
||||
if (! empty($conf->facture->enabled) && $user->rights->facture->lire)
|
||||
{
|
||||
include_once DOL_DOCUMENT_ROOT.'/compta/facture/class/facture.class.php';
|
||||
$board=new Facture($db);
|
||||
$dashboardlines[] = $board->load_board($user);
|
||||
$workBoard = $board->load_board($user);
|
||||
$dashboardlines[$board->element] = $workBoard;
|
||||
}
|
||||
|
||||
// Number of supplier invoices (has paid)
|
||||
|
|
@ -457,7 +475,8 @@ if (! empty($conf->supplier_invoice->enabled) && ! empty($user->rights->fourniss
|
|||
{
|
||||
include_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.facture.class.php';
|
||||
$board=new FactureFournisseur($db);
|
||||
$dashboardlines[] = $board->load_board($user);
|
||||
$workBoard = $board->load_board($user);
|
||||
$dashboardlines[$board->element] = $workBoard;
|
||||
}
|
||||
|
||||
// Number of transactions to conciliate
|
||||
|
|
@ -468,7 +487,8 @@ if (! empty($conf->banque->enabled) && $user->rights->banque->lire && ! $user->s
|
|||
$nb = $board::countAccountToReconcile(); // Get nb of account to reconciliate
|
||||
if ($nb > 0)
|
||||
{
|
||||
$dashboardlines[] = $board->load_board($user);
|
||||
$workBoard = $board->load_board($user);
|
||||
$dashboardlines[$board->element] = $workBoard;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -477,7 +497,7 @@ if (! empty($conf->banque->enabled) && $user->rights->banque->lire && ! $user->s
|
|||
{
|
||||
include_once DOL_DOCUMENT_ROOT.'/compta/paiement/cheque/class/remisecheque.class.php';
|
||||
$board=new RemiseCheque($db);
|
||||
$dashboardlines[] = $board->load_board($user);
|
||||
$dashboardlines['RemiseCheque'] = $board->load_board($user);
|
||||
}
|
||||
|
||||
// Number of foundation members
|
||||
|
|
@ -485,7 +505,7 @@ if (! empty($conf->adherent->enabled) && $user->rights->adherent->lire && ! $use
|
|||
{
|
||||
include_once DOL_DOCUMENT_ROOT.'/adherents/class/adherent.class.php';
|
||||
$board=new Adherent($db);
|
||||
$dashboardlines[] = $board->load_board($user);
|
||||
$dashboardlines['Adherent'] = $board->load_board($user);
|
||||
}
|
||||
|
||||
// Number of expense reports to approve
|
||||
|
|
@ -493,7 +513,7 @@ if (! empty($conf->expensereport->enabled) && $user->rights->expensereport->appr
|
|||
{
|
||||
include_once DOL_DOCUMENT_ROOT.'/expensereport/class/expensereport.class.php';
|
||||
$board=new ExpenseReport($db);
|
||||
$dashboardlines[] = $board->load_board($user, 'toapprove');
|
||||
$dashboardlines['ExpenseReport'] = $board->load_board($user, 'toapprove');
|
||||
}
|
||||
|
||||
// Number of expense reports to pay
|
||||
|
|
@ -501,7 +521,7 @@ if (! empty($conf->expensereport->enabled) && $user->rights->expensereport->to_p
|
|||
{
|
||||
include_once DOL_DOCUMENT_ROOT.'/expensereport/class/expensereport.class.php';
|
||||
$board=new ExpenseReport($db);
|
||||
$dashboardlines[] = $board->load_board($user, 'topay');
|
||||
$dashboardlines['ExpenseReport'] = $board->load_board($user, 'topay');
|
||||
}
|
||||
|
||||
// Number of holidays to approve
|
||||
|
|
@ -509,7 +529,7 @@ if (! empty($conf->holiday->enabled) && $user->rights->holiday->approve)
|
|||
{
|
||||
include_once DOL_DOCUMENT_ROOT.'/holiday/class/holiday.class.php';
|
||||
$board=new Holiday($db);
|
||||
$dashboardlines[] = $board->load_board($user);
|
||||
$dashboardlines['Holiday'] = $board->load_board($user);
|
||||
}
|
||||
|
||||
$object=new stdClass();
|
||||
|
|
@ -520,15 +540,103 @@ if ($reshook == 0) {
|
|||
$dashboardlines = array_merge($dashboardlines, $hookmanager->resArray);
|
||||
}
|
||||
|
||||
/* grouping dashboard stats */
|
||||
$dashboardgroup = array (
|
||||
'action' =>
|
||||
array (
|
||||
'groupName' => 'Agenda',
|
||||
'stats' => array ('action'),
|
||||
),
|
||||
'project' =>
|
||||
array (
|
||||
'groupName' => 'Projects',
|
||||
'stats' => array ('project','project_task'),
|
||||
),
|
||||
'propal' =>
|
||||
array (
|
||||
'groupName' => 'Proposals',
|
||||
'stats' =>
|
||||
array ('propal_opened','propal_signed'),
|
||||
),
|
||||
'supplier_proposal' =>
|
||||
array (
|
||||
'groupName' => 'SupplierProposals',
|
||||
'stats' =>
|
||||
array ('supplier_proposal_opened','supplier_proposal_signed'),
|
||||
),
|
||||
'commande' =>
|
||||
array (
|
||||
'groupName' => 'Orders',
|
||||
'stats' =>
|
||||
array ('commande'),
|
||||
),
|
||||
'order_supplier' =>
|
||||
array (
|
||||
'groupName' => 'SuppliersOrders',
|
||||
'stats' =>
|
||||
array ('order_supplier'),
|
||||
),
|
||||
'contrat' =>
|
||||
array (
|
||||
'groupName' => 'Contracts',
|
||||
'stats' =>
|
||||
array ('contrat_inactive','contrat_active'),
|
||||
),
|
||||
'facture' =>
|
||||
array (
|
||||
'groupName' => 'Invoices',
|
||||
'stats' =>
|
||||
array ('facture'),
|
||||
),
|
||||
'invoice_supplier' =>
|
||||
array (
|
||||
'groupName' => 'SupplierInvoices',
|
||||
'stats' =>
|
||||
array ('invoice_supplier'),
|
||||
),
|
||||
'bank_account' =>
|
||||
array (
|
||||
'groupName' => 'BankAccount',
|
||||
'stats' =>
|
||||
array ('bank_account','RemiseCheque'),
|
||||
),
|
||||
/*'RemiseCheque' =>
|
||||
array (
|
||||
'groupName' => 'BankChecks',
|
||||
'stats' =>
|
||||
array ('RemiseCheque'),
|
||||
),*/
|
||||
'Adherent' =>
|
||||
array (
|
||||
'groupName' => 'Members',
|
||||
'stats' =>
|
||||
array ('Adherent'),
|
||||
),
|
||||
'ExpenseReport' =>
|
||||
array (
|
||||
'groupName' => 'ExpenseReport',
|
||||
'stats' =>
|
||||
array ('ExpenseReport'),
|
||||
),
|
||||
'Holiday' =>
|
||||
array (
|
||||
'groupName' => 'Holidays',
|
||||
'stats' =>
|
||||
array ('Holiday'),
|
||||
),
|
||||
);
|
||||
|
||||
|
||||
|
||||
// Calculate total nb of late
|
||||
$totallate=$totaltodo=0;
|
||||
|
||||
//Remove any invalid response
|
||||
//load_board can return an integer if failed or WorkboardResponse if OK
|
||||
$valid_dashboardlines=array();
|
||||
foreach($dashboardlines as $tmp)
|
||||
foreach($dashboardlines as $infoKey => $tmp)
|
||||
{
|
||||
if ($tmp instanceof WorkboardResponse) $valid_dashboardlines[] = $tmp;
|
||||
if ($tmp instanceof WorkboardResponse) $valid_dashboardlines[$infoKey] = $tmp;
|
||||
}
|
||||
|
||||
// We calculate $totallate. Must be defined before start of next loop because it is show in first fetch on next loop
|
||||
|
|
@ -578,14 +686,64 @@ $boxwork.='</tr>'."\n";
|
|||
$nbworkboardempty=0;
|
||||
if (! empty($valid_dashboardlines))
|
||||
{
|
||||
$openedDashBoard = '';
|
||||
|
||||
$boxwork.='<tr class="nobottom nohover"><td class="tdboxstats nohover flexcontainer centpercent"><div style="display: flex: flex-wrap: wrap">';
|
||||
|
||||
foreach($valid_dashboardlines as $board)
|
||||
foreach($dashboardgroup as $groupKey => $groupElement) {
|
||||
|
||||
$boards = array();
|
||||
foreach ($groupElement['stats'] as $infoKey)
|
||||
{
|
||||
if(!empty($valid_dashboardlines[$infoKey]))
|
||||
{
|
||||
$boards[] = $valid_dashboardlines[$infoKey];
|
||||
}
|
||||
}
|
||||
|
||||
if(!empty($boards))
|
||||
{
|
||||
$groupName = $langs->trans($groupElement['groupName']);
|
||||
$groupKeyLowerCase = strtolower($groupKey);
|
||||
|
||||
$openedDashBoard.= '<div class="box-flex-item">'."\n";
|
||||
$openedDashBoard.= ' <div class="info-box">'."\n";
|
||||
$openedDashBoard.= ' <span class="info-box-icon bg-infoxbox-'.$groupKeyLowerCase.'"><i class="fa fa-dol-'.$groupKeyLowerCase.'"></i></span>'."\n";
|
||||
$openedDashBoard.= ' <div class="info-box-content">'."\n";
|
||||
|
||||
$openedDashBoard .= ' <span class="info-box-text"><strong>'.$groupName.'</strong></span>' . "\n";
|
||||
|
||||
foreach($boards as $board) {
|
||||
$infoName = !empty($board->labelShort) ? $board->labelShort : $board->label ;
|
||||
|
||||
$textLateTitle = $langs->trans("NActionsLate", $board->nbtodolate);
|
||||
$textLateTitle.= ' ('.$langs->trans("Late").' = '.$langs->trans("DateReference").' > '.$langs->trans("DateToday").' '.(ceil($board->warning_delay) >= 0 ? '+' : '').ceil($board->warning_delay).' '.$langs->trans("days").')';
|
||||
|
||||
$textLate = img_picto($textLateTitle, "warning_white", 'class="inline-block hideonsmartphone valigntextbottom"').'';
|
||||
$textLate .= '<span class="dashboardlineindicatorlate'.($board->nbtodolate>0?' dashboardlineko':' dashboardlineok').'">';
|
||||
$textLate .= $board->nbtodolate;
|
||||
$textLate .= '</span>';
|
||||
|
||||
$openedDashBoard .= ' <span class="info-box-text">'.$infoName.' : <span class="label label-default">'.$board->nbtodo.'</span>'.$textLate.'</span>' . "\n";
|
||||
}
|
||||
|
||||
|
||||
$openedDashBoard.= ' </div><!-- /.info-box-content -->'."\n";
|
||||
$openedDashBoard.= ' </div><!-- /.info-box -->'."\n";
|
||||
$openedDashBoard.= '</div><!-- /.box-flex-item -->'."\n";
|
||||
$openedDashBoard.="\n";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
foreach($valid_dashboardlines as $infoKey => $board)
|
||||
{
|
||||
if (empty($board->nbtodo)) $nbworkboardempty++;
|
||||
|
||||
$textlate = $langs->trans("NActionsLate", $board->nbtodolate);
|
||||
$textlate.= ' ('.$langs->trans("Late").' = '.$langs->trans("DateReference").' > '.$langs->trans("DateToday").' '.(ceil($board->warning_delay) >= 0 ? '+' : '').ceil($board->warning_delay).' '.$langs->trans("days").')';
|
||||
|
||||
|
||||
|
||||
|
||||
$boxwork .='<div class="boxstatsindicator thumbstat150 nobold nounderline"><div class="boxstats130 boxstatsborder">';
|
||||
$boxwork .= '<div class="boxstatscontent">';
|
||||
|
|
@ -611,6 +769,15 @@ if (! empty($valid_dashboardlines))
|
|||
}
|
||||
$boxwork.='</div></div>';
|
||||
$boxwork .="\n";
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
$boxwork .='<div class="boxstatsindicator thumbstat150 nobold nounderline"><div class="boxstats150empty"></div></div>';
|
||||
|
|
@ -638,7 +805,7 @@ $boxwork.='</div>';
|
|||
|
||||
|
||||
print '<div class="fichecenter">';
|
||||
print $boxwork;
|
||||
print '<div class="box"><div class="box-flex-container">'.$openedDashBoard.'</div></div>';
|
||||
print '</div>';
|
||||
|
||||
print '<div class="clearboth"></div>';
|
||||
|
|
@ -654,7 +821,7 @@ $boxlist.='<div class="twocolumns">';
|
|||
|
||||
$boxlist.='<div class="firstcolumn fichehalfleft boxhalfleft" id="boxhalfleft">';
|
||||
|
||||
//$boxlist.=$boxwork;
|
||||
$boxlist.=$boxwork;
|
||||
$boxlist.=$resultboxes['boxlista'];
|
||||
|
||||
$boxlist.= '</div>';
|
||||
|
|
|
|||
|
|
@ -51,6 +51,7 @@ ListOfClosedServices=List of closed services
|
|||
ListOfRunningServices=List of running services
|
||||
NotActivatedServices=Inactive services (among validated contracts)
|
||||
BoardNotActivatedServices=Services to activate among validated contracts
|
||||
BoardNotActivatedServicesShort=Services to activate
|
||||
LastContracts=Latest %s contracts
|
||||
LastModifiedServices=Latest %s modified services
|
||||
ContractStartDate=Start date
|
||||
|
|
@ -65,7 +66,9 @@ DateEndReal=Real end date
|
|||
DateEndRealShort=Real end date
|
||||
CloseService=Close service
|
||||
BoardRunningServices=Services running
|
||||
BoardRunningServicesShort=Services running
|
||||
BoardExpiredServices=Services expired
|
||||
BoardExpiredServicesShort=Services expired
|
||||
ServiceStatus=Status of service
|
||||
DraftContracts=Drafts contracts
|
||||
CloseRefusedBecauseOneServiceActive=Contract can't be closed as there is at least one open service on it
|
||||
|
|
|
|||
|
|
@ -981,3 +981,6 @@ PaymentInformation=Payment information
|
|||
ValidFrom=Valid from
|
||||
ValidUntil=Valid until
|
||||
NoRecordedUsers=No users
|
||||
ToClose=To close
|
||||
ToProcess=To process
|
||||
ToApprove=To approve
|
||||
|
|
|
|||
|
|
@ -29,6 +29,7 @@ MenuMembersUpToDate=Up to date members
|
|||
MenuMembersNotUpToDate=Out of date members
|
||||
MenuMembersResiliated=Terminated members
|
||||
MembersWithSubscriptionToReceive=Members with subscription to receive
|
||||
MembersWithSubscriptionToReceiveShort=Subscription to receive
|
||||
DateSubscription=Subscription date
|
||||
DateEndSubscription=Subscription end date
|
||||
EndSubscription=End subscription
|
||||
|
|
@ -197,4 +198,4 @@ SendReminderForExpiredSubscriptionTitle=Send reminder by email for expired subsc
|
|||
SendReminderForExpiredSubscription=Send reminder by email to members when subscription is about to expire (parameter is number of days before end of subscription to send the remind. It can be a list of days separated by a semicolon, for example '10;5;0;-5')
|
||||
MembershipPaid=Membership paid for current period (until %s)
|
||||
YouMayFindYourInvoiceInThisEmail=You may find your invoice attached to this email
|
||||
XMembersClosed=%s member(s) closed
|
||||
XMembersClosed=%s member(s) closed
|
||||
|
|
|
|||
|
|
@ -1796,6 +1796,7 @@ class Project extends CommonObject
|
|||
$response = new WorkboardResponse();
|
||||
$response->warning_delay = $conf->projet->warning_delay/60/60/24;
|
||||
$response->label = $langs->trans("OpenedProjects");
|
||||
$response->labelShort = $langs->trans("Opened");
|
||||
if ($user->rights->projet->all->lire) $response->url = DOL_URL_ROOT.'/projet/list.php?search_status=1&mainmenu=project';
|
||||
else $response->url = DOL_URL_ROOT.'/projet/list.php?search_project_user=-1&search_status=1&mainmenu=project';
|
||||
$response->img = img_object('', "projectpub");
|
||||
|
|
|
|||
|
|
@ -2281,20 +2281,24 @@ class SupplierProposal extends CommonObject
|
|||
$resql=$this->db->query($sql);
|
||||
if ($resql)
|
||||
{
|
||||
$label = $labelShort = '';
|
||||
if ($mode == 'opened') {
|
||||
$delay_warning=$conf->supplier_proposal->cloture->warning_delay;
|
||||
$statut = self::STATUS_VALIDATED;
|
||||
$label = $langs->trans("SupplierProposalsToClose");
|
||||
$labelShort = $langs->trans("ToClose");
|
||||
}
|
||||
if ($mode == 'signed') {
|
||||
$delay_warning=$conf->supplier_proposal->facturation->warning_delay;
|
||||
$statut = self::STATUS_SIGNED;
|
||||
$label = $langs->trans("SupplierProposalsToProcess"); // May be billed or ordered
|
||||
$labelShort = $langs->trans("ToProcess");
|
||||
}
|
||||
|
||||
$response = new WorkboardResponse();
|
||||
$response->warning_delay = $delay_warning/60/60/24;
|
||||
$response->label = $label;
|
||||
$response->labelShort = $labelShort;
|
||||
$response->url = DOL_URL_ROOT.'/supplier_proposal/list.php?viewstatut='.$statut;
|
||||
$response->img = img_object('', "propal");
|
||||
|
||||
|
|
|
|||
|
|
@ -3198,7 +3198,13 @@ span.boxstatsindicator {
|
|||
font-size: 130%;
|
||||
font-weight: normal;
|
||||
line-height: 29px;
|
||||
flex-grow: 1;
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
span.dashboardlineindicator, span.dashboardlineindicatorlate {
|
||||
font-size: 130%;
|
||||
font-weight: normal;
|
||||
|
|
@ -5750,3 +5756,5 @@ div.tabsElem a.tab {
|
|||
|
||||
<?php
|
||||
include dol_buildpath($path.'/theme/'.$theme.'/dropdown.inc.php', 0);
|
||||
include dol_buildpath($path.'/theme/'.$theme.'/info-box.inc.php', 0);
|
||||
|
||||
|
|
|
|||
BIN
htdocs/theme/eldy/img/title_document.png
Normal file
BIN
htdocs/theme/eldy/img/title_document.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 570 B |
114
htdocs/theme/eldy/info-box.inc.php
Normal file
114
htdocs/theme/eldy/info-box.inc.php
Normal file
|
|
@ -0,0 +1,114 @@
|
|||
<?php
|
||||
if (! defined('ISLOADEDBYSTEELSHEET')) die('Must be call by steelsheet'); ?>
|
||||
/* <style type="text/css" > */
|
||||
|
||||
/*
|
||||
* Component: Info Box
|
||||
* -------------------
|
||||
*/
|
||||
.info-box {
|
||||
display: block;
|
||||
min-height: 90px;
|
||||
background: #fff;
|
||||
width: 100%;
|
||||
box-shadow: 0 1px 1px rgba(0, 0, 0, 0.1);
|
||||
border-radius: 2px;
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
.info-box small {
|
||||
font-size: 14px;
|
||||
}
|
||||
.info-box .progress {
|
||||
background: rgba(0, 0, 0, 0.2);
|
||||
margin: 5px -10px 5px -10px;
|
||||
height: 2px;
|
||||
}
|
||||
.info-box .progress,
|
||||
.info-box .progress .progress-bar {
|
||||
border-radius: 0;
|
||||
}
|
||||
.info-box .progress .progress-bar {
|
||||
background: #fff;
|
||||
}
|
||||
.info-box-icon {
|
||||
border-top-left-radius: 2px;
|
||||
border-top-right-radius: 0;
|
||||
border-bottom-right-radius: 0;
|
||||
border-bottom-left-radius: 2px;
|
||||
display: block;
|
||||
float: left;
|
||||
height: 90px;
|
||||
width: 90px;
|
||||
text-align: center;
|
||||
font-size: 45px;
|
||||
line-height: 90px;
|
||||
background: rgba(0, 0, 0, 0.2);
|
||||
}
|
||||
.info-box-icon > img {
|
||||
max-width: 100%;
|
||||
}
|
||||
.info-box-content {
|
||||
padding: 5px 10px;
|
||||
margin-left: 90px;
|
||||
}
|
||||
.info-box-number {
|
||||
display: block;
|
||||
font-weight: bold;
|
||||
font-size: 18px;
|
||||
}
|
||||
.progress-description,
|
||||
.info-box-text {
|
||||
display: block;
|
||||
font-size: 14px;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
.info-box-text {
|
||||
text-transform: uppercase;
|
||||
}
|
||||
.info-box-more {
|
||||
display: block;
|
||||
}
|
||||
.progress-description {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.info-box-icon {
|
||||
color: #fff !important;
|
||||
}
|
||||
|
||||
.bg-infoxbox-action{
|
||||
background-color: #d81b60 !important;
|
||||
}
|
||||
.fa-dol-action:before {
|
||||
content: "\f073";
|
||||
}
|
||||
|
||||
.bg-infoxbox-project{
|
||||
background-color: #605ca8 !important;
|
||||
}
|
||||
.fa-dol-project:before {
|
||||
content: "\f0e8";
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
.box-flex-container{
|
||||
display: flex; /* or inline-flex */
|
||||
flex-direction: row;
|
||||
flex-wrap: wrap;
|
||||
width: 100%;
|
||||
/*justify-content: space-between;*/
|
||||
}
|
||||
|
||||
.box-flex-item{
|
||||
flex-grow : 2;
|
||||
flex-shrink: 1;
|
||||
flex-basis: auto;
|
||||
|
||||
width: 280px;
|
||||
padding: 5px 10px;
|
||||
}
|
||||
BIN
htdocs/theme/md/img/title_document.png
Normal file
BIN
htdocs/theme/md/img/title_document.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 570 B |
Loading…
Reference in New Issue
Block a user