projects
/
timetracker.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
da435f0
)
Refactoring. Replacing getKey() with get().
author
Nik Okuntseff
<support@anuko.com>
Fri, 23 Mar 2018 15:03:09 +0000
(15:03 +0000)
committer
Nik Okuntseff
<support@anuko.com>
Fri, 23 Mar 2018 15:03:09 +0000
(15:03 +0000)
WEB-INF/lib/I18n.class.php
patch
|
blob
|
history
WEB-INF/lib/form/Calendar.class.php
patch
|
blob
|
history
WEB-INF/lib/form/CheckboxGroup.class.php
patch
|
blob
|
history
WEB-INF/lib/form/DateField.class.php
patch
|
blob
|
history
WEB-INF/lib/ttAdmin.class.php
patch
|
blob
|
history
WEB-INF/lib/ttImportHelper.class.php
patch
|
blob
|
history
WEB-INF/lib/ttInvoiceHelper.class.php
patch
|
blob
|
history
WEB-INF/lib/ttRegistrator.class.php
patch
|
blob
|
history
WEB-INF/templates/footer.tpl
patch
|
blob
|
history
diff --git
a/WEB-INF/lib/I18n.class.php
b/WEB-INF/lib/I18n.class.php
index
7155edb
..
ed7497d
100644
(file)
--- a/
WEB-INF/lib/I18n.class.php
+++ b/
WEB-INF/lib/I18n.class.php
@@
-35,23
+35,28
@@
class I18n {
var $holidays;
var $keys = array(); // These are our localized strings.
var $holidays;
var $keys = array(); // These are our localized strings.
- //
The getKey obtains localized keyword value
.
- function get
Key($kword
) {
+ //
get - obtains a localized value from $keys array
.
+ function get
($key
) {
$value = '';
$value = '';
- $pos = strpos($k
word
, '.'); // Keywords can have separating dots such as in form.login.about.
+ $pos = strpos($k
ey
, '.'); // Keywords can have separating dots such as in form.login.about.
if (!($pos === false)) {
if (!($pos === false)) {
- $words = explode('.', $k
word
);
+ $words = explode('.', $k
ey
);
$str = '';
foreach ($words as $word) {
$str .= "['".$word."']";
}
eval("\$value = \$this->keys".$str.";");
} else {
$str = '';
foreach ($words as $word) {
$str .= "['".$word."']";
}
eval("\$value = \$this->keys".$str.";");
} else {
- $value = $this->keys[$k
word
];
+ $value = $this->keys[$k
ey
];
}
return $value;
}
}
return $value;
}
+ // getKey is a legacy function that we are replacing with get.
+ function getKey($kword) {
+ return $this->get($kword);
+ }
+
// TODO: refactoring ongoing down from here...
function getWeekDayName($id) {
$id = (int) $id;
// TODO: refactoring ongoing down from here...
function getWeekDayName($id) {
$id = (int) $id;
diff --git
a/WEB-INF/lib/form/Calendar.class.php
b/WEB-INF/lib/form/Calendar.class.php
index
555b6e1
..
4c835f6
100644
(file)
--- a/
WEB-INF/lib/form/Calendar.class.php
+++ b/
WEB-INF/lib/form/Calendar.class.php
@@
-207,7
+207,7
@@
class Calendar extends FormElement {
$str .= "</TR>\n";
}
$str .= "</TR>\n";
}
- $str .= "<tr><td colspan=\"7\" align=\"center\"><a id=\"today_link\" href=\"?".$this->controlName."=".strftime(DB_DATEFORMAT)."\" tabindex=\"-1\">".$i18n->get
Key
('label.today')."</a></td></tr>\n";
+ $str .= "<tr><td colspan=\"7\" align=\"center\"><a id=\"today_link\" href=\"?".$this->controlName."=".strftime(DB_DATEFORMAT)."\" tabindex=\"-1\">".$i18n->get('label.today')."</a></td></tr>\n";
$str .= "</table>\n";
$str .= "<input type=\"hidden\" name=\"$this->controlName\" value=\"$indate\">\n";
$str .= "</table>\n";
$str .= "<input type=\"hidden\" name=\"$this->controlName\" value=\"$indate\">\n";
diff --git
a/WEB-INF/lib/form/CheckboxGroup.class.php
b/WEB-INF/lib/form/CheckboxGroup.class.php
index
810c963
..
9488b5c
100644
(file)
--- a/
WEB-INF/lib/form/CheckboxGroup.class.php
+++ b/
WEB-INF/lib/form/CheckboxGroup.class.php
@@
-60,8
+60,8
@@
class CheckboxGroup extends FormElement {
function localize() {
global $i18n;
function localize() {
global $i18n;
- $this->lSelAll = $i18n->get
Key
('label.select_all');
- $this->lSelNone = $i18n->get
Key
('label.select_none');
+ $this->lSelAll = $i18n->get('label.select_all');
+ $this->lSelNone = $i18n->get('label.select_none');
}
function getHtml() {
}
function getHtml() {
diff --git
a/WEB-INF/lib/form/DateField.class.php
b/WEB-INF/lib/form/DateField.class.php
index
f8eef8c
..
9016dff
100644
(file)
--- a/
WEB-INF/lib/form/DateField.class.php
+++ b/
WEB-INF/lib/form/DateField.class.php
@@
-52,9
+52,9
@@
class DateField extends TextField {
$this->mMonthNames = $i18n->monthNames;
$this->mWeekDayShortNames = $i18n->weekdayShortNames;
$this->mMonthNames = $i18n->monthNames;
$this->mWeekDayShortNames = $i18n->weekdayShortNames;
- $this->lToday = $i18n->get
Key
('label.today');
- $this->lCalendarButtons['today'] = $i18n->get
Key
('label.today');
- $this->lCalendarButtons['close'] = $i18n->get
Key
('button.close');
+ $this->lToday = $i18n->get('label.today');
+ $this->lCalendarButtons['today'] = $i18n->get('label.today');
+ $this->lCalendarButtons['close'] = $i18n->get('button.close');
$this->mDateFormat = $user->date_format;
$this->mWeekStartDay = $user->week_start;
$this->mDateFormat = $user->date_format;
$this->mWeekStartDay = $user->week_start;
diff --git
a/WEB-INF/lib/ttAdmin.class.php
b/WEB-INF/lib/ttAdmin.class.php
index
d4b72e2
..
fbcabd4
100644
(file)
--- a/
WEB-INF/lib/ttAdmin.class.php
+++ b/
WEB-INF/lib/ttAdmin.class.php
@@
-189,42
+189,42
@@
class ttAdmin {
$result = true;
if (!ttValidString($fields['group_name'], true)) {
$result = true;
if (!ttValidString($fields['group_name'], true)) {
- $this->err->add($i18n->get
Key('error.field'), $i18n->getKey
('label.team_name'));
+ $this->err->add($i18n->get
('error.field'), $i18n->get
('label.team_name'));
$result = false;
}
if (!ttValidString($fields['user_name'])) {
$result = false;
}
if (!ttValidString($fields['user_name'])) {
- $this->err->add($i18n->get
Key('error.field'), $i18n->getKey
('label.manager_name'));
+ $this->err->add($i18n->get
('error.field'), $i18n->get
('label.manager_name'));
$result = false;
}
if (!ttValidString($fields['new_login'])) {
$result = false;
}
if (!ttValidString($fields['new_login'])) {
- $this->err->add($i18n->get
Key('error.field'), $i18n->getKey
('label.manager_login'));
+ $this->err->add($i18n->get
('error.field'), $i18n->get
('label.manager_login'));
$result = false;
}
// If we change login, it must be unique.
if ($fields['new_login'] != $fields['old_login']) {
if (ttUserHelper::getUserByLogin($fields['new_login'])) {
$result = false;
}
// If we change login, it must be unique.
if ($fields['new_login'] != $fields['old_login']) {
if (ttUserHelper::getUserByLogin($fields['new_login'])) {
- $this->err->add($i18n->get
Key
('error.user_exists'));
+ $this->err->add($i18n->get('error.user_exists'));
$result = false;
}
}
if (!$auth->isPasswordExternal() && ($fields['password1'] || $fields['password2'])) {
if (!ttValidString($fields['password1'])) {
$result = false;
}
}
if (!$auth->isPasswordExternal() && ($fields['password1'] || $fields['password2'])) {
if (!ttValidString($fields['password1'])) {
- $this->err->add($i18n->get
Key('error.field'), $i18n->getKey
('label.password'));
+ $this->err->add($i18n->get
('error.field'), $i18n->get
('label.password'));
$result = false;
}
if (!ttValidString($fields['password2'])) {
$result = false;
}
if (!ttValidString($fields['password2'])) {
- $this->err->add($i18n->get
Key('error.field'), $i18n->getKey
('label.confirm_password'));
+ $this->err->add($i18n->get
('error.field'), $i18n->get
('label.confirm_password'));
$result = false;
}
if ($fields['password1'] !== $fields['password2']) {
$result = false;
}
if ($fields['password1'] !== $fields['password2']) {
- $this->err->add($i18n->get
Key('error.not_equal'), $i18n->getKey('label.password'), $i18n->getKey
('label.confirm_password'));
+ $this->err->add($i18n->get
('error.not_equal'), $i18n->get('label.password'), $i18n->get
('label.confirm_password'));
$result = false;
}
}
if (!ttValidEmail($fields['email'], true)) {
$result = false;
}
}
if (!ttValidEmail($fields['email'], true)) {
- $this->err->add($i18n->get
Key('error.field'), $i18n->getKey
('label.email'));
+ $this->err->add($i18n->get
('error.field'), $i18n->get
('label.email'));
$result = false;
}
$result = false;
}
@@
-271,36
+271,36
@@
class ttAdmin {
$result = true;
if (!ttValidString($fields['name'])) {
$result = true;
if (!ttValidString($fields['name'])) {
- $this->err->add($i18n->get
Key('error.field'), $i18n->getKey
('label.person_name'));
+ $this->err->add($i18n->get
('error.field'), $i18n->get
('label.person_name'));
$result = false;
}
if (!ttValidString($fields['login'])) {
$result = false;
}
if (!ttValidString($fields['login'])) {
- $this->err->add($i18n->get
Key('error.field'), $i18n->getKey
('label.login'));
+ $this->err->add($i18n->get
('error.field'), $i18n->get
('label.login'));
$result = false;
}
// If we change login, it must be unique.
if ($fields['login'] != $user->login) {
if (ttUserHelper::getUserByLogin($fields['login'])) {
$result = false;
}
// If we change login, it must be unique.
if ($fields['login'] != $user->login) {
if (ttUserHelper::getUserByLogin($fields['login'])) {
- $this->err->add($i18n->get
Key
('error.user_exists'));
+ $this->err->add($i18n->get('error.user_exists'));
$result = false;
}
}
if (!$auth->isPasswordExternal() && ($fields['password1'] || $fields['password2'])) {
if (!ttValidString($fields['password1'])) {
$result = false;
}
}
if (!$auth->isPasswordExternal() && ($fields['password1'] || $fields['password2'])) {
if (!ttValidString($fields['password1'])) {
- $this->err->add($i18n->get
Key('error.field'), $i18n->getKey
('label.password'));
+ $this->err->add($i18n->get
('error.field'), $i18n->get
('label.password'));
$result = false;
}
if (!ttValidString($fields['password2'])) {
$result = false;
}
if (!ttValidString($fields['password2'])) {
- $this->err->add($i18n->get
Key('error.field'), $i18n->getKey
('label.confirm_password'));
+ $this->err->add($i18n->get
('error.field'), $i18n->get
('label.confirm_password'));
$result = false;
}
if ($fields['password1'] !== $fields['password2']) {
$result = false;
}
if ($fields['password1'] !== $fields['password2']) {
- $this->err->add($i18n->get
Key('error.not_equal'), $i18n->getKey('label.password'), $i18n->getKey
('label.confirm_password'));
+ $this->err->add($i18n->get
('error.not_equal'), $i18n->get('label.password'), $i18n->get
('label.confirm_password'));
$result = false;
}
}
if (!ttValidEmail($fields['email'], true)) {
$result = false;
}
}
if (!ttValidEmail($fields['email'], true)) {
- $this->err->add($i18n->get
Key('error.field'), $i18n->getKey
('label.email'));
+ $this->err->add($i18n->get
('error.field'), $i18n->get
('label.email'));
$result = false;
}
$result = false;
}
@@
-326,7
+326,7
@@
class ttAdmin {
$sql = 'update tt_users set '.$login_part.$password_part.$name_part.$email_part.$modified_part.'where id = '.$user_id;
$affected = $mdb2->exec($sql);
if (is_a($affected, 'PEAR_Error')) {
$sql = 'update tt_users set '.$login_part.$password_part.$name_part.$email_part.$modified_part.'where id = '.$user_id;
$affected = $mdb2->exec($sql);
if (is_a($affected, 'PEAR_Error')) {
- $this->err->add($i18n->get
Key
('error.db'));
+ $this->err->add($i18n->get('error.db'));
return false;
}
return false;
}
diff --git
a/WEB-INF/lib/ttImportHelper.class.php
b/WEB-INF/lib/ttImportHelper.class.php
index
55fd154
..
ca717ca
100644
(file)
--- a/
WEB-INF/lib/ttImportHelper.class.php
+++ b/
WEB-INF/lib/ttImportHelper.class.php
@@
-371,13
+371,13
@@
class ttImportHelper {
// If the file is compressed - uncompress it.
if ($compressed) {
if (!$this->uncompress($_FILES['xmlfile']['tmp_name'], $filename)) {
// If the file is compressed - uncompress it.
if ($compressed) {
if (!$this->uncompress($_FILES['xmlfile']['tmp_name'], $filename)) {
- $this->errors->add($i18n->get
Key
('error.sys'));
+ $this->errors->add($i18n->get('error.sys'));
return;
}
unlink($_FILES['xmlfile']['tmp_name']);
} else {
if (!move_uploaded_file($_FILES['xmlfile']['tmp_name'], $filename)) {
return;
}
unlink($_FILES['xmlfile']['tmp_name']);
} else {
if (!move_uploaded_file($_FILES['xmlfile']['tmp_name'], $filename)) {
- $this->errors->add($i18n->get
Key
('error.upload'));
+ $this->errors->add($i18n->get('error.upload'));
return;
}
}
return;
}
}
@@
-397,7
+397,7
@@
class ttImportHelper {
xml_get_current_line_number($parser)));
}
if (!$this->canImport) {
xml_get_current_line_number($parser)));
}
if (!$this->canImport) {
- $this->errors->add($i18n->get
Key
('error.user_exists'));
+ $this->errors->add($i18n->get('error.user_exists'));
break;
}
}
break;
}
}
diff --git
a/WEB-INF/lib/ttInvoiceHelper.class.php
b/WEB-INF/lib/ttInvoiceHelper.class.php
index
fd701fe
..
d58bc11
100644
(file)
--- a/
WEB-INF/lib/ttInvoiceHelper.class.php
+++ b/
WEB-INF/lib/ttInvoiceHelper.class.php
@@
-429,16
+429,16
@@
class ttInvoiceHelper {
$body .= '<body>';
// Output title.
$body .= '<body>';
// Output title.
- $body .= '<p style="'.$style_title.'">'.$i18n->get
Key
('title.invoice').' '.htmlspecialchars($invoice['name']).'</p>';
+ $body .= '<p style="'.$style_title.'">'.$i18n->get('title.invoice').' '.htmlspecialchars($invoice['name']).'</p>';
// Output comment.
if($comment) $body .= '<p>'.htmlspecialchars($comment).'</p>';
// Output invoice info.
$body .= '<table>';
// Output comment.
if($comment) $body .= '<p>'.htmlspecialchars($comment).'</p>';
// Output invoice info.
$body .= '<table>';
- $body .= '<tr><td><b>'.$i18n->get
Key
('label.date').':</b> '.$invoice['date'].'</td></tr>';
- $body .= '<tr><td><b>'.$i18n->get
Key
('label.client').':</b> '.htmlspecialchars($client['name']).'</td></tr>';
- $body .= '<tr><td><b>'.$i18n->get
Key
('label.client_address').':</b> '.htmlspecialchars($client['address']).'</td></tr>';
+ $body .= '<tr><td><b>'.$i18n->get('label.date').':</b> '.$invoice['date'].'</td></tr>';
+ $body .= '<tr><td><b>'.$i18n->get('label.client').':</b> '.htmlspecialchars($client['name']).'</td></tr>';
+ $body .= '<tr><td><b>'.$i18n->get('label.client_address').':</b> '.htmlspecialchars($client['address']).'</td></tr>';
$body .= '</table>';
$body .= '<p></p>';
$body .= '</table>';
$body .= '<p></p>';
@@
-446,15
+446,15
@@
class ttInvoiceHelper {
// Output invoice items.
$body .= '<table border="0" cellpadding="4" cellspacing="0" width="100%">';
$body .= '<tr>';
// Output invoice items.
$body .= '<table border="0" cellpadding="4" cellspacing="0" width="100%">';
$body .= '<tr>';
- $body .= '<td style="'.$style_tableHeader.'">'.$i18n->get
Key
('label.date').'</td>';
- $body .= '<td style="'.$style_tableHeader.'">'.$i18n->get
Key
('form.invoice.person').'</td>';
+ $body .= '<td style="'.$style_tableHeader.'">'.$i18n->get('label.date').'</td>';
+ $body .= '<td style="'.$style_tableHeader.'">'.$i18n->get('form.invoice.person').'</td>';
if (MODE_PROJECTS == $user->tracking_mode || MODE_PROJECTS_AND_TASKS == $user->tracking_mode)
if (MODE_PROJECTS == $user->tracking_mode || MODE_PROJECTS_AND_TASKS == $user->tracking_mode)
- $body .= '<td style="'.$style_tableHeader.'">'.$i18n->get
Key
('label.project').'</td>';
+ $body .= '<td style="'.$style_tableHeader.'">'.$i18n->get('label.project').'</td>';
if (MODE_PROJECTS_AND_TASKS == $user->tracking_mode)
if (MODE_PROJECTS_AND_TASKS == $user->tracking_mode)
- $body .= '<td style="'.$style_tableHeader.'">'.$i18n->get
Key
('label.task').'</td>';
- $body .= '<td style="'.$style_tableHeader.'">'.$i18n->get
Key
('label.note').'</td>';
- $body .= '<td style="'.$style_tableHeaderCentered.'" width="5%">'.$i18n->get
Key
('label.duration').'</td>';
- $body .= '<td style="'.$style_tableHeaderCentered.'" width="5%">'.$i18n->get
Key
('label.cost').'</td>';
+ $body .= '<td style="'.$style_tableHeader.'">'.$i18n->get('label.task').'</td>';
+ $body .= '<td style="'.$style_tableHeader.'">'.$i18n->get('label.note').'</td>';
+ $body .= '<td style="'.$style_tableHeaderCentered.'" width="5%">'.$i18n->get('label.duration').'</td>';
+ $body .= '<td style="'.$style_tableHeaderCentered.'" width="5%">'.$i18n->get('label.cost').'</td>';
$body .= '</tr>';
foreach ($invoice_items as $item) {
$body .= '<tr>';
$body .= '</tr>';
foreach ($invoice_items as $item) {
$body .= '<tr>';
@@
-477,15
+477,15
@@
class ttInvoiceHelper {
$colspan += 2;
$body .= '<tr><td> </td></tr>';
if ($tax) {
$colspan += 2;
$body .= '<tr><td> </td></tr>';
if ($tax) {
- $body .= '<tr><td colspan="'.$colspan.'" align="right"><b>'.$i18n->get
Key
('label.subtotal').':</b></td><td nowrap align="right">'.$subtotal.'</td></tr>';
- $body .= '<tr><td colspan="'.$colspan.'" align="right"><b>'.$i18n->get
Key
('label.tax').':</b></td><td nowrap align="right">'.$tax.'</td></tr>';
+ $body .= '<tr><td colspan="'.$colspan.'" align="right"><b>'.$i18n->get('label.subtotal').':</b></td><td nowrap align="right">'.$subtotal.'</td></tr>';
+ $body .= '<tr><td colspan="'.$colspan.'" align="right"><b>'.$i18n->get('label.tax').':</b></td><td nowrap align="right">'.$tax.'</td></tr>';
}
}
- $body .= '<tr><td colspan="'.$colspan.'" align="right"><b>'.$i18n->get
Key
('label.total').':</b></td><td nowrap align="right">'.$total.'</td></tr>';
+ $body .= '<tr><td colspan="'.$colspan.'" align="right"><b>'.$i18n->get('label.total').':</b></td><td nowrap align="right">'.$total.'</td></tr>';
$body .= '</table>';
// Output footer.
if (!defined('REPORT_FOOTER') || !(REPORT_FOOTER == false))
$body .= '</table>';
// Output footer.
if (!defined('REPORT_FOOTER') || !(REPORT_FOOTER == false))
- $body .= '<p style="text-align: center;">'.$i18n->get
Key
('form.mail.footer').'</p>';
+ $body .= '<p style="text-align: center;">'.$i18n->get('form.mail.footer').'</p>';
// Finish creating email body.
$body .= '</body></html>';
// Finish creating email body.
$body .= '</body></html>';
diff --git
a/WEB-INF/lib/ttRegistrator.class.php
b/WEB-INF/lib/ttRegistrator.class.php
index
71f49e6
..
7082e6b
100644
(file)
--- a/
WEB-INF/lib/ttRegistrator.class.php
+++ b/
WEB-INF/lib/ttRegistrator.class.php
@@
-62,21
+62,21
@@
class ttRegistrator {
global $i18n;
if (!ttValidString($this->group_name, true))
global $i18n;
if (!ttValidString($this->group_name, true))
- $this->err->add($i18n->get
Key('error.field'), $i18n->getKey
('label.team_name'));
+ $this->err->add($i18n->get
('error.field'), $i18n->get
('label.team_name'));
if (!ttValidString($this->currency, true))
if (!ttValidString($this->currency, true))
- $this->err->add($i18n->get
Key('error.field'), $i18n->getKey
('label.currency'));
+ $this->err->add($i18n->get
('error.field'), $i18n->get
('label.currency'));
if (!ttValidString($this->user_name))
if (!ttValidString($this->user_name))
- $this->err->add($i18n->get
Key('error.field'), $i18n->getKey
('label.manager_name'));
+ $this->err->add($i18n->get
('error.field'), $i18n->get
('label.manager_name'));
if (!ttValidString($this->login))
if (!ttValidString($this->login))
- $this->err->add($i18n->get
Key('error.field'), $i18n->getKey
('label.manager_login'));
+ $this->err->add($i18n->get
('error.field'), $i18n->get
('label.manager_login'));
if (!ttValidString($this->password1))
if (!ttValidString($this->password1))
- $this->err->add($i18n->get
Key('error.field'), $i18n->getKey
('label.password'));
+ $this->err->add($i18n->get
('error.field'), $i18n->get
('label.password'));
if (!ttValidString($this->password2))
if (!ttValidString($this->password2))
- $this->err->add($i18n->get
Key('error.field'), $i18n->getKey
('label.confirm_password'));
+ $this->err->add($i18n->get
('error.field'), $i18n->get
('label.confirm_password'));
if ($this->password1 !== $this->password2)
if ($this->password1 !== $this->password2)
- $this->err->add($i18n->get
Key('error.not_equal'), $i18n->getKey('label.password'), $i18n->getKey('label.confirm_password'));
+ $this->err->add($i18n->get
('error.not_equal'), $i18n->get('label.password'), $i18n->get('label.confirm_password'));
if (!ttValidEmail($this->email, true))
if (!ttValidEmail($this->email, true))
- $this->err->add($i18n->get
Key('error.field'), $i18n->getKey
('label.email'));
+ $this->err->add($i18n->get
('error.field'), $i18n->get
('label.email'));
}
// The register function registers a user in Time Tracker.
}
// The register function registers a user in Time Tracker.
@@
-88,27
+88,27
@@
class ttRegistrator {
import('ttUserHelper');
if (ttUserHelper::getUserByLogin($this->login)) {
// User login already exists.
import('ttUserHelper');
if (ttUserHelper::getUserByLogin($this->login)) {
// User login already exists.
- $this->err->add($i18n->get
Key
('error.user_exists'));
+ $this->err->add($i18n->get('error.user_exists'));
return false;
}
// Create a new group.
$this->group_id = $this->createGroup();
if (!$this->group_id) {
return false;
}
// Create a new group.
$this->group_id = $this->createGroup();
if (!$this->group_id) {
- $this->err->add($i18n->get
Key
('error.db'));
+ $this->err->add($i18n->get('error.db'));
return false;
}
import('ttRoleHelper');
if (!ttRoleHelper::createPredefinedRoles($this->group_id, $this->lang)) {
return false;
}
import('ttRoleHelper');
if (!ttRoleHelper::createPredefinedRoles($this->group_id, $this->lang)) {
- $err->add($i18n->get
Key
('error.db'));
+ $err->add($i18n->get('error.db'));
return false;
}
$this->role_id = ttRoleHelper::getTopManagerRoleID();
$this->user_id = $this->createUser();
if (!$this->user_id) {
return false;
}
$this->role_id = ttRoleHelper::getTopManagerRoleID();
$this->user_id = $this->createUser();
if (!$this->user_id) {
- $err->add($i18n->get
Key
('error.db'));
+ $err->add($i18n->get('error.db'));
return false;
}
return false;
}
@@
-171,7
+171,7
@@
class ttRegistrator {
$sql = "update tt_teams set created_by = $user_id where id = $this->group_id";
$affected = $mdb2->exec($sql);
if (is_a($affected, 'PEAR_Error')) {
$sql = "update tt_teams set created_by = $user_id where id = $this->group_id";
$affected = $mdb2->exec($sql);
if (is_a($affected, 'PEAR_Error')) {
- $this->err->add($i18n->get
Key
('error.db'));
+ $this->err->add($i18n->get('error.db'));
return false;
}
return false;
}
@@
-179,7
+179,7
@@
class ttRegistrator {
$sql = "update tt_users set created_by = $user_id where id = $user_id and team_id = $this->group_id";
$affected = $mdb2->exec($sql);
if (is_a($affected, 'PEAR_Error')) {
$sql = "update tt_users set created_by = $user_id where id = $user_id and team_id = $this->group_id";
$affected = $mdb2->exec($sql);
if (is_a($affected, 'PEAR_Error')) {
- $this->err->add($i18n->get
Key
('error.db'));
+ $this->err->add($i18n->get('error.db'));
return false;
}
return false;
}
diff --git
a/WEB-INF/templates/footer.tpl
b/WEB-INF/templates/footer.tpl
index
881616e
..
d92f371
100644
(file)
--- a/
WEB-INF/templates/footer.tpl
+++ b/
WEB-INF/templates/footer.tpl
@@
-12,7
+12,7
@@
<br>
<table cellspacing="0" cellpadding="4" width="100%" border="0">
<tr>
<br>
<table cellspacing="0" cellpadding="4" width="100%" border="0">
<tr>
- <td align="center"> Anuko Time Tracker 1.17.67.414
1
| Copyright © <a href="https://www.anuko.com/lp/tt_3.htm" target="_blank">Anuko</a> |
+ <td align="center"> Anuko Time Tracker 1.17.67.414
2
| Copyright © <a href="https://www.anuko.com/lp/tt_3.htm" target="_blank">Anuko</a> |
<a href="https://www.anuko.com/lp/tt_4.htm" target="_blank">{$i18n.footer.credits}</a> |
<a href="https://www.anuko.com/lp/tt_5.htm" target="_blank">{$i18n.footer.license}</a> |
<a href="https://www.anuko.com/lp/tt_7.htm" target="_blank">{$i18n.footer.improve}</a>
<a href="https://www.anuko.com/lp/tt_4.htm" target="_blank">{$i18n.footer.credits}</a> |
<a href="https://www.anuko.com/lp/tt_5.htm" target="_blank">{$i18n.footer.license}</a> |
<a href="https://www.anuko.com/lp/tt_7.htm" target="_blank">{$i18n.footer.improve}</a>