mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2026-01-06 17:13:03 +01:00
Compare commits
18 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
7c0a6946a7 | ||
|
|
1ecc1afa9e | ||
|
|
ceb1e699b7 | ||
|
|
c028819cab | ||
|
|
d59b1bb0c6 | ||
|
|
9d582a53ca | ||
|
|
3d85407619 | ||
|
|
ca1e3b4d55 | ||
|
|
94bb1ac511 | ||
|
|
8893d8d59f | ||
|
|
9253fed754 | ||
|
|
8000777864 | ||
|
|
141df52dd6 | ||
|
|
01a3787664 | ||
|
|
8ac7dd8e9a | ||
|
|
3793ae323a | ||
|
|
e61bcd03ed | ||
|
|
3295498e9e |
@@ -126,10 +126,10 @@ before_script:
|
||||
echo "Set timezone"
|
||||
echo 'date.timezone = "Europe/Paris"' >> ~/.phpenv/versions/$PHP_VERSION_NAME/etc/php.ini
|
||||
if [ "$TRAVIS_PHP_VERSION" = '5.3' ] || [ "$TRAVIS_PHP_VERSION" = '5.4' ]; then
|
||||
echo
|
||||
echo "Enabling APC for PHP <= 5.4"
|
||||
#echo
|
||||
#echo "Enabling APC for PHP <= 5.4"
|
||||
# Documentation says it should be available for PHP <= 5.6 but it's not for 5.5 and 5.6!
|
||||
echo 'extension = apc.so' >> ~/.phpenv/versions/$PHP_VERSION_NAME/etc/php.ini
|
||||
#echo 'extension = apc.so' >> ~/.phpenv/versions/$PHP_VERSION_NAME/etc/php.ini
|
||||
echo
|
||||
echo "Enabling Memcached for PHP <= 5.4"
|
||||
# Documentation says it should be available for all PHP versions but it's not for 5.5 and 5.6, 7.0 and nightly!
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
* Copyright (C) 2005 Marc Barilley / Ocebo <marc@ocebo.com>
|
||||
* Copyright (C) 2005-2011 Regis Houssin <regis.houssin@capnetworks.com>
|
||||
* Copyright (C) 2013 Cédric Salvador <csalvador@gpcsolutions.fr>
|
||||
* Copyright (C) 2017 Frédéric France <frederic.france@netlogic.fr>
|
||||
*
|
||||
* 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
|
||||
@@ -164,6 +165,6 @@ else
|
||||
print $langs->trans("ErrorUnknown");
|
||||
}
|
||||
|
||||
$db->close();
|
||||
|
||||
llxFooter();
|
||||
|
||||
$db->close();
|
||||
|
||||
@@ -762,7 +762,7 @@ function projectLinesPerWeek(&$inc, $firstdaytoshow, $fuser, $parent, $lines, &$
|
||||
|
||||
// Time spent by user
|
||||
print '<td align="right">';
|
||||
$tmptimespent=$taskstatic->getSummaryOfTimeSpent();
|
||||
$tmptimespent=$taskstatic->getSummaryOfTimeSpent('', $fuser->id);
|
||||
if ($tmptimespent['total_duration']) print convertSecondToTime($tmptimespent['total_duration'],'allhourmin');
|
||||
else print '--:--';
|
||||
print "</td>\n";
|
||||
|
||||
@@ -1099,6 +1099,7 @@ class CommandeFournisseur extends CommonOrder
|
||||
$this->lines[$i]->remise_percent,
|
||||
'HT',
|
||||
0,
|
||||
$this->lines[$i]->product_type,
|
||||
$this->lines[$i]->info_bits
|
||||
);
|
||||
if ($result < 0)
|
||||
|
||||
@@ -911,9 +911,10 @@ class Task extends CommonObject
|
||||
* Calculate total of time spent for task
|
||||
*
|
||||
* @param int $id Id of object (here task)
|
||||
* @param int $user_id Filter on user time
|
||||
* @return array Array of info for task array('min_date', 'max_date', 'total_duration')
|
||||
*/
|
||||
function getSummaryOfTimeSpent($id='')
|
||||
function getSummaryOfTimeSpent($id='', $user_id='')
|
||||
{
|
||||
global $langs;
|
||||
|
||||
@@ -927,6 +928,7 @@ class Task extends CommonObject
|
||||
$sql.= " SUM(t.task_duration) as total_duration";
|
||||
$sql.= " FROM ".MAIN_DB_PREFIX."projet_task_time as t";
|
||||
$sql.= " WHERE t.fk_task = ".$id;
|
||||
if(!empty($user_id)) $sql.= " AND t.fk_user = ".$user_id;
|
||||
|
||||
dol_syslog(get_class($this)."::getSummaryOfTimeSpent", LOG_DEBUG);
|
||||
$resql=$this->db->query($sql);
|
||||
|
||||
Reference in New Issue
Block a user