projects
/
timetracker.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
A fix for work units in totals only report.
[timetracker.git]
/
WEB-INF
/
lib
/
ttUser.class.php
diff --git
a/WEB-INF/lib/ttUser.class.php
b/WEB-INF/lib/ttUser.class.php
index
2d7f1c9
..
9de260b
100644
(file)
--- a/
WEB-INF/lib/ttUser.class.php
+++ b/
WEB-INF/lib/ttUser.class.php
@@
-144,7
+144,7
@@
class ttUser {
$this->allow_overlap = $config->getDefinedValue('allow_overlap');
$this->future_entries = $config->getDefinedValue('future_entries');
if ($this->isPluginEnabled('wu')) {
$this->allow_overlap = $config->getDefinedValue('allow_overlap');
$this->future_entries = $config->getDefinedValue('future_entries');
if ($this->isPluginEnabled('wu')) {
- $minutes_in_unit = $config->getIntValue('minutes_in_unit');
+ $minutes_in_unit = $config->getIntValue('minutes_in_unit'
, 15
);
if ($minutes_in_unit) $this->minutes_in_unit = $minutes_in_unit;
$first_unit_threshold = $config->getIntValue('1st_unit_threshold');
if ($first_unit_threshold) $this->first_unit_threshold = $first_unit_threshold;
if ($minutes_in_unit) $this->minutes_in_unit = $minutes_in_unit;
$first_unit_threshold = $config->getIntValue('1st_unit_threshold');
if ($first_unit_threshold) $this->first_unit_threshold = $first_unit_threshold;
@@
-235,6
+235,12
@@
class ttUser {
return $config->getDefinedValue($name);
}
return $config->getDefinedValue($name);
}
+ // getConfigInt retruns an integer value defined in a group, or false.
+ function getConfigInt($name, $defaultVal) {
+ $config = new ttConfigHelper($this->getConfig());
+ return $config->getIntValue($name, $defaultVal);
+ }
+
// can - determines whether user has a right to do something.
function can($do_something) {
return in_array($do_something, $this->rights);
// can - determines whether user has a right to do something.
function can($do_something) {
return in_array($do_something, $this->rights);