Merge github.com:Dolibarr/dolibarr into dev_add_dict_NatureOfProductType
This commit is contained in:
commit
109d1ab801
@ -79,7 +79,7 @@ class PropaleStats extends Stats
|
|||||||
$this->field = 'total_ht';
|
$this->field = 'total_ht';
|
||||||
$this->field_line = 'total_ht';
|
$this->field_line = 'total_ht';
|
||||||
|
|
||||||
$this->where .= " p.fk_statut > 0";
|
//$this->where .= " p.fk_statut > 0";
|
||||||
}
|
}
|
||||||
if ($mode == 'supplier')
|
if ($mode == 'supplier')
|
||||||
{
|
{
|
||||||
@ -91,10 +91,10 @@ class PropaleStats extends Stats
|
|||||||
$this->field = 'total_ht';
|
$this->field = 'total_ht';
|
||||||
$this->field_line = 'total_ht';
|
$this->field_line = 'total_ht';
|
||||||
|
|
||||||
$this->where .= " p.fk_statut > 0"; // Validated, accepted, refused and closed
|
//$this->where .= " p.fk_statut > 0"; // Validated, accepted, refused and closed
|
||||||
}
|
}
|
||||||
//$this->where.= " AND p.fk_soc = s.rowid AND p.entity = ".$conf->entity;
|
//$this->where.= " AND p.fk_soc = s.rowid AND p.entity = ".$conf->entity;
|
||||||
$this->where .= " AND p.entity IN (".getEntity('propal').")";
|
$this->where .= ($this->where ? ' AND ' : '')."p.entity IN (".getEntity('propal').")";
|
||||||
if (!$user->rights->societe->client->voir && !$this->socid) $this->where .= " AND p.fk_soc = sc.fk_soc AND sc.fk_user = ".$user->id;
|
if (!$user->rights->societe->client->voir && !$this->socid) $this->where .= " AND p.fk_soc = sc.fk_soc AND sc.fk_user = ".$user->id;
|
||||||
if ($this->socid)
|
if ($this->socid)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -86,7 +86,7 @@ if ($mode == 'customer')
|
|||||||
if ($mode == 'supplier')
|
if ($mode == 'supplier')
|
||||||
{
|
{
|
||||||
$picto = 'supplier_proposal';
|
$picto = 'supplier_proposal';
|
||||||
$title = $langs->trans("ProposalsStatisticsSuppliers").' ('.$langs->trans("SentToSuppliers").")";
|
$title = $langs->trans("ProposalsStatisticsSuppliers");
|
||||||
$dir = $conf->supplier_proposal->dir_temp;
|
$dir = $conf->supplier_proposal->dir_temp;
|
||||||
$cat_type = Categorie::TYPE_SUPPLIER;
|
$cat_type = Categorie::TYPE_SUPPLIER;
|
||||||
$cat_label = $langs->trans("Category").' '.lcfirst($langs->trans("Supplier"));
|
$cat_label = $langs->trans("Category").' '.lcfirst($langs->trans("Supplier"));
|
||||||
|
|||||||
@ -77,7 +77,7 @@ class CommandeStats extends Stats
|
|||||||
$this->from_line = MAIN_DB_PREFIX.$object->table_element_line." as tl";
|
$this->from_line = MAIN_DB_PREFIX.$object->table_element_line." as tl";
|
||||||
$this->field = 'total_ht';
|
$this->field = 'total_ht';
|
||||||
$this->field_line = 'total_ht';
|
$this->field_line = 'total_ht';
|
||||||
$this->where .= " c.fk_statut > 0"; // Not draft and not cancelled
|
//$this->where .= " c.fk_statut > 0"; // Not draft and not cancelled
|
||||||
} elseif ($mode == 'supplier')
|
} elseif ($mode == 'supplier')
|
||||||
{
|
{
|
||||||
$object = new CommandeFournisseur($this->db);
|
$object = new CommandeFournisseur($this->db);
|
||||||
@ -85,10 +85,10 @@ class CommandeStats extends Stats
|
|||||||
$this->from_line = MAIN_DB_PREFIX.$object->table_element_line." as tl";
|
$this->from_line = MAIN_DB_PREFIX.$object->table_element_line." as tl";
|
||||||
$this->field = 'total_ht';
|
$this->field = 'total_ht';
|
||||||
$this->field_line = 'total_ht';
|
$this->field_line = 'total_ht';
|
||||||
$this->where .= " c.fk_statut > 2"; // Only approved & ordered
|
//$this->where .= " c.fk_statut > 2"; // Only approved & ordered
|
||||||
}
|
}
|
||||||
//$this->where.= " AND c.fk_soc = s.rowid AND c.entity = ".$conf->entity;
|
//$this->where.= " AND c.fk_soc = s.rowid AND c.entity = ".$conf->entity;
|
||||||
$this->where .= ' AND c.entity IN ('.getEntity('commande').')';
|
$this->where .= ($this->where ? ' AND ' : ''). 'c.entity IN ('.getEntity('commande').')';
|
||||||
|
|
||||||
if (!$user->rights->societe->client->voir && !$this->socid) $this->where .= " AND c.fk_soc = sc.fk_soc AND sc.fk_user = ".$user->id;
|
if (!$user->rights->societe->client->voir && !$this->socid) $this->where .= " AND c.fk_soc = sc.fk_soc AND sc.fk_user = ".$user->id;
|
||||||
if ($this->socid)
|
if ($this->socid)
|
||||||
|
|||||||
@ -81,7 +81,7 @@ $dir = $conf->commande->dir_temp;
|
|||||||
if ($mode == 'supplier')
|
if ($mode == 'supplier')
|
||||||
{
|
{
|
||||||
$picto = 'supplier_order';
|
$picto = 'supplier_order';
|
||||||
$title = $langs->trans("OrdersStatisticsSuppliers").' ('.$langs->trans("SentToSuppliers").")";
|
$title = $langs->trans("OrdersStatisticsSuppliers");
|
||||||
$dir = $conf->fournisseur->commande->dir_temp;
|
$dir = $conf->fournisseur->commande->dir_temp;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -2052,7 +2052,6 @@ function dol_print_date($time, $format = '', $tzoutput = 'tzserver', $outputlang
|
|||||||
* @param boolean $fast Fast mode. deprecated.
|
* @param boolean $fast Fast mode. deprecated.
|
||||||
* @param string $forcetimezone '' to use the PHP server timezone. Or use a form like 'Europe/Paris' or '+0200' to force timezone.
|
* @param string $forcetimezone '' to use the PHP server timezone. Or use a form like 'Europe/Paris' or '+0200' to force timezone.
|
||||||
* @return array Array of informations
|
* @return array Array of informations
|
||||||
* If no fast mode:
|
|
||||||
* 'seconds' => $secs,
|
* 'seconds' => $secs,
|
||||||
* 'minutes' => $min,
|
* 'minutes' => $min,
|
||||||
* 'hours' => $hour,
|
* 'hours' => $hour,
|
||||||
@ -2061,6 +2060,7 @@ function dol_print_date($time, $format = '', $tzoutput = 'tzserver', $outputlang
|
|||||||
* 'mon' => $month,
|
* 'mon' => $month,
|
||||||
* 'year' => $year,
|
* 'year' => $year,
|
||||||
* 'yday' => floor($secsInYear/$_day_power)
|
* 'yday' => floor($secsInYear/$_day_power)
|
||||||
|
* '0' => original timestamp
|
||||||
* @see dol_print_date(), dol_stringtotime(), dol_mktime()
|
* @see dol_print_date(), dol_stringtotime(), dol_mktime()
|
||||||
*/
|
*/
|
||||||
function dol_getdate($timestamp, $fast = false, $forcetimezone = '')
|
function dol_getdate($timestamp, $fast = false, $forcetimezone = '')
|
||||||
@ -2080,7 +2080,8 @@ function dol_getdate($timestamp, $fast = false, $forcetimezone = '')
|
|||||||
'yday'=>((int) date_format($datetimeobj, 'z')),
|
'yday'=>((int) date_format($datetimeobj, 'z')),
|
||||||
'hours'=>((int) date_format($datetimeobj, 'H')),
|
'hours'=>((int) date_format($datetimeobj, 'H')),
|
||||||
'minutes'=>((int) date_format($datetimeobj, 'i')),
|
'minutes'=>((int) date_format($datetimeobj, 'i')),
|
||||||
'seconds'=>((int) date_format($datetimeobj, 's'))
|
'seconds'=>((int) date_format($datetimeobj, 's')),
|
||||||
|
'0'=>$timestamp
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
// PHP getdate is restricted to the years 1901-2038 on Unix and 1970-2038 on Windows
|
// PHP getdate is restricted to the years 1901-2038 on Unix and 1970-2038 on Windows
|
||||||
|
|||||||
@ -64,7 +64,6 @@ class FichinterStats extends Stats
|
|||||||
$this->userid = $userid;
|
$this->userid = $userid;
|
||||||
$this->cachefilesuffix = $mode;
|
$this->cachefilesuffix = $mode;
|
||||||
|
|
||||||
$this->where .= " c.entity = ".$conf->entity;
|
|
||||||
if ($mode == 'customer')
|
if ($mode == 'customer')
|
||||||
{
|
{
|
||||||
$object = new Fichinter($this->db);
|
$object = new Fichinter($this->db);
|
||||||
@ -75,6 +74,8 @@ class FichinterStats extends Stats
|
|||||||
//$this->where.= " AND c.fk_statut > 0"; // Not draft and not cancelled
|
//$this->where.= " AND c.fk_statut > 0"; // Not draft and not cancelled
|
||||||
}
|
}
|
||||||
if (!$user->rights->societe->client->voir && !$this->socid) $this->where .= " AND c.fk_soc = sc.fk_soc AND sc.fk_user = ".$user->id;
|
if (!$user->rights->societe->client->voir && !$this->socid) $this->where .= " AND c.fk_soc = sc.fk_soc AND sc.fk_user = ".$user->id;
|
||||||
|
$this->where .= ($this->where ? ' AND ' : '')."c.entity IN (".getEntity('fichinter').')';
|
||||||
|
|
||||||
if ($this->socid)
|
if ($this->socid)
|
||||||
{
|
{
|
||||||
$this->where .= " AND c.fk_soc = ".$this->socid;
|
$this->where .= " AND c.fk_soc = ".$this->socid;
|
||||||
|
|||||||
@ -2652,25 +2652,29 @@ if ($action == 'create')
|
|||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
}
|
}
|
||||||
|
|
||||||
// Intracomm report
|
// Intracomm report
|
||||||
$langs->loadLangs(array("intracommreport"));
|
if (!empty($conf->intracommreport->enabled)) {
|
||||||
print '<tr><td class="nowrap">';
|
$langs->loadLangs(array("intracommreport"));
|
||||||
print '<table width="100%" class="nobordernopadding"><tr><td class="nowrap">';
|
print '<tr><td class="nowrap">';
|
||||||
print $langs->trans('IntracommReportTransportMode');
|
print '<table width="100%" class="nobordernopadding"><tr><td class="nowrap">';
|
||||||
print '</td>';
|
print $langs->trans('IntracommReportTransportMode');
|
||||||
if ($action != 'editmode' && $user->rights->fournisseur->facture->creer) {
|
print '</td>';
|
||||||
print '<td class="right"><a href="'.$_SERVER["PHP_SELF"].'?action=editmode&id='.$object->id.'">'.img_edit($langs->trans('SetMode'), 1).'</a></td>';
|
if ($action != 'editmode' && $user->rights->fournisseur->facture->creer) {
|
||||||
}
|
print '<td class="right"><a href="'.$_SERVER["PHP_SELF"].'?action=editmode&id='.$object->id.'">'.img_edit($langs->trans('SetMode'), 1).'</a></td>';
|
||||||
print '</tr></table>';
|
}
|
||||||
print '</td><td colspan="2">';
|
print '</tr></table>';
|
||||||
if ($action == 'editmode')
|
print '</td>';
|
||||||
{
|
|
||||||
$form->formSelectTransportMode($_SERVER['PHP_SELF'].'?id='.$object->id, $object->transport_mode_id, 'transport_mode_id', 1, 1);
|
print '<td>';
|
||||||
}
|
if ($action == 'editmode')
|
||||||
else {
|
{
|
||||||
$form->formSelectTransportMode($_SERVER['PHP_SELF'].'?id='.$object->id, $object->transport_mode_id, 'none');
|
$form->formSelectTransportMode($_SERVER['PHP_SELF'].'?id='.$object->id, $object->transport_mode_id, 'transport_mode_id', 1, 1);
|
||||||
}
|
}
|
||||||
print '</td></tr>';
|
else {
|
||||||
|
$form->formSelectTransportMode($_SERVER['PHP_SELF'].'?id='.$object->id, $object->transport_mode_id, 'none');
|
||||||
|
}
|
||||||
|
print '</td></tr>';
|
||||||
|
}
|
||||||
|
|
||||||
// Other attributes
|
// Other attributes
|
||||||
$cols = 2;
|
$cols = 2;
|
||||||
|
|||||||
@ -12,6 +12,7 @@
|
|||||||
* Copyright (C) 2014-2015 Marcos García <marcosgdf@gmail.com>
|
* Copyright (C) 2014-2015 Marcos García <marcosgdf@gmail.com>
|
||||||
* Copyright (C) 2015 Raphaël Doursenaud <rdoursenaud@gpcsolutions.fr>
|
* Copyright (C) 2015 Raphaël Doursenaud <rdoursenaud@gpcsolutions.fr>
|
||||||
* Copyright (C) 2020 Demarest Maxime <maxime@indelog.fr>
|
* Copyright (C) 2020 Demarest Maxime <maxime@indelog.fr>
|
||||||
|
* Copyright (C) 2020 Charlene Benke <charlie@patas-monkey.com>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
@ -1655,8 +1656,13 @@ function top_menu($head, $title = '', $target = '', $disablejs = 0, $disablehead
|
|||||||
$helpbaseurl = '';
|
$helpbaseurl = '';
|
||||||
$helppage = '';
|
$helppage = '';
|
||||||
$mode = '';
|
$mode = '';
|
||||||
|
$helppresent = '';
|
||||||
|
|
||||||
if (empty($helppagename)) $helppagename = 'EN:User_documentation|FR:Documentation_utilisateur|ES:Documentación_usuarios';
|
if (empty($helppagename)) {
|
||||||
|
$helppagename = 'EN:User_documentation|FR:Documentation_utilisateur|ES:Documentación_usuarios';
|
||||||
|
} else {
|
||||||
|
$helppresent = 'helppresent';
|
||||||
|
}
|
||||||
|
|
||||||
// Get helpbaseurl, helppage and mode from helppagename and langs
|
// Get helpbaseurl, helppage and mode from helppagename and langs
|
||||||
$arrayres = getHelpParamFor($helppagename, $langs);
|
$arrayres = getHelpParamFor($helppagename, $langs);
|
||||||
@ -1674,7 +1680,7 @@ function top_menu($head, $title = '', $target = '', $disablejs = 0, $disablehead
|
|||||||
if ($mode == 'wiki') $text .= sprintf($helpbaseurl, urlencode(html_entity_decode($helppage)));
|
if ($mode == 'wiki') $text .= sprintf($helpbaseurl, urlencode(html_entity_decode($helppage)));
|
||||||
else $text .= sprintf($helpbaseurl, $helppage);
|
else $text .= sprintf($helpbaseurl, $helppage);
|
||||||
$text .= '">';
|
$text .= '">';
|
||||||
$text .= '<span class="fa fa-question-circle atoplogin valignmiddle"></span>';
|
$text .= '<span class="fa fa-question-circle atoplogin valignmiddle'.($helppresent ? ' '.$helppresent : '').'"></span>';
|
||||||
$text .= '</a>';
|
$text .= '</a>';
|
||||||
$toprightmenu .= @Form::textwithtooltip('', $title, 2, 1, $text, 'login_block_elem', 2);
|
$toprightmenu .= @Form::textwithtooltip('', $title, 2, 1, $text, 'login_block_elem', 2);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -2581,6 +2581,7 @@ font.vsmenudisabledmargin { margin: 1px 1px 1px 6px; }
|
|||||||
li a.vsmenudisabled, li.vsmenudisabled { color: #aaa !important; }
|
li a.vsmenudisabled, li.vsmenudisabled { color: #aaa !important; }
|
||||||
|
|
||||||
a.help:link, a.help:visited, a.help:hover, a.help:active, span.help { text-align: <?php print $left; ?>; color: #aaa; text-decoration: none; }
|
a.help:link, a.help:visited, a.help:hover, a.help:active, span.help { text-align: <?php print $left; ?>; color: #aaa; text-decoration: none; }
|
||||||
|
.helppresent, .helppresent:hover { color: #f3e4ac !important; }
|
||||||
|
|
||||||
.vmenu div.blockvmenufirst, .vmenu div.blockvmenulogo, .vmenu div.blockvmenusearchphone, .vmenu div.blockvmenubookmarks
|
.vmenu div.blockvmenufirst, .vmenu div.blockvmenulogo, .vmenu div.blockvmenusearchphone, .vmenu div.blockvmenubookmarks
|
||||||
{
|
{
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user