diff --git a/src/IDF/Commit.php b/src/IDF/Commit.php
index 87032c1..98e1137 100644
--- a/src/IDF/Commit.php
+++ b/src/IDF/Commit.php
@@ -172,6 +172,8 @@ class IDF_Commit extends Pluf_Model
$out = '
'.
Pluf_esc(Pluf_Template_dateAgo($this->creation_dtime, 'without')).
' | ';
+ $stag = new IDF_Template_ShowUser();
+ $user = $stag->start($this->get_author(), $request, $this->origauthor, false);
$tag = new IDF_Template_IssueComment();
$out .= $tag->start($this->summary, $request, false);
if (0 && $this->fullmessage) {
@@ -181,7 +183,7 @@ class IDF_Commit extends Pluf_Model
|
';
+'.__('Commit').'
'.$this->scm_id.', '.__('by').' '.$user.'
';
return Pluf_Template::markSafe($out);
}
diff --git a/src/IDF/Issue.php b/src/IDF/Issue.php
index 0e0ee59..22642b8 100644
--- a/src/IDF/Issue.php
+++ b/src/IDF/Issue.php
@@ -188,11 +188,12 @@ class IDF_Issue extends Pluf_Model
$out = ''.
Pluf_esc(Pluf_Template_dateAgo($this->creation_dtime, 'without')).
' | ';
- $submitter = $this->get_submitter();
+ $stag = new IDF_Template_ShowUser();
+ $user = $stag->start($this->get_submitter(), $request, '', false);
$ic = (in_array($this->status, $request->project->getTagIdsByStatus('closed'))) ? 'issue-c' : 'issue-o';
$out .= sprintf(__('Issue %3$d, %4$s'), $url, $ic, $this->id, Pluf_esc($this->summary)).' | ';
$out .= "\n".'
';
+'.sprintf(__('Creation of
issue %d'), $url, $ic, $this->id).', '.__('by').' '.$user.'
';
return Pluf_Template::markSafe($out);
}
diff --git a/src/IDF/IssueComment.php b/src/IDF/IssueComment.php
index 17a21ad..fc002dc 100644
--- a/src/IDF/IssueComment.php
+++ b/src/IDF/IssueComment.php
@@ -136,7 +136,9 @@ class IDF_IssueComment extends Pluf_Model
$out = "\n".''.
Pluf_esc(Pluf_Template_dateAgo($this->creation_dtime, 'without')).
' | ';
- $submitter = $this->get_submitter();
+ $stag = new IDF_Template_ShowUser();
+ $user = $stag->start($this->get_submitter(), $request, '', false);
+
$ic = (in_array($issue->status, $request->project->getTagIdsByStatus('closed'))) ? 'issue-c' : 'issue-o';
$out .= sprintf(__('Issue %3$d, %4$s'), $url, $ic, $issue->id, Pluf_esc($issue->summary));
@@ -168,7 +170,7 @@ class IDF_IssueComment extends Pluf_Model
$out .= "\n".' |
';
+'.sprintf(__('Comment on
issue %d'), $url, $ic, $issue->id).', '.__('by').' '.$user.'
';
return Pluf_Template::markSafe($out);
}
diff --git a/src/IDF/Middleware.php b/src/IDF/Middleware.php
index e21658a..48eda3e 100644
--- a/src/IDF/Middleware.php
+++ b/src/IDF/Middleware.php
@@ -85,6 +85,7 @@ class IDF_Middleware
'issuetext' => 'IDF_Template_IssueComment',
'timeline' => 'IDF_Template_TimelineFragment',
'markdown' => 'IDF_Template_Markdown',
+ 'showuser' => 'IDF_Template_ShowUser',
));
$params['modifiers'] = array_merge($params['modifiers'],
array(
diff --git a/src/IDF/Template/ShowUser.php b/src/IDF/Template/ShowUser.php
new file mode 100644
index 0000000..148bf38
--- /dev/null
+++ b/src/IDF/Template/ShowUser.php
@@ -0,0 +1,66 @@
+login));
+ if (!$user->isAnonymous() and $user->id == $request->user->id) {
+ $utext = __('Me');
+ } else {
+ $utext = Pluf_esc($user);
+ }
+ $out = sprintf('%s',
+ $url, $utext);
+ }
+ if ($echo) echo $out;
+ else return $out;
+ }
+}
diff --git a/src/IDF/Upload.php b/src/IDF/Upload.php
index da18d03..254d5cb 100644
--- a/src/IDF/Upload.php
+++ b/src/IDF/Upload.php
@@ -177,11 +177,12 @@ class IDF_Upload extends Pluf_Model
$out = ''.
Pluf_esc(Pluf_Template_dateAgo($this->creation_dtime, 'without')).
' | ';
- $submitter = $this->get_submitter();
+ $stag = new IDF_Template_ShowUser();
+ $user = $stag->start($this->get_submitter(), $request, '', false);
$out .= sprintf(__('Download %2$d, %3$s'), $url, $this->id, Pluf_esc($this->summary)).' | ';
$out .= '
';
$out .= "\n".'';
+'.sprintf(__('Addition of
download %d'), $url, $this->id).', '.__('by').' '.$user.'
';
return Pluf_Template::markSafe($out);
}
diff --git a/src/IDF/WikiPage.php b/src/IDF/WikiPage.php
index 82b2957..04cacf8 100644
--- a/src/IDF/WikiPage.php
+++ b/src/IDF/WikiPage.php
@@ -192,10 +192,11 @@ class IDF_WikiPage extends Pluf_Model
$out = ''.
Pluf_esc(Pluf_Template_dateAgo($this->creation_dtime, 'without')).
' | ';
- $submitter = $this->get_submitter();
+ $stag = new IDF_Template_ShowUser();
+ $user = $stag->start($this->get_submitter(), $request, '', false);
$out .= sprintf(__('%2$s, %3$s'), $url, Pluf_esc($this->title), Pluf_esc($this->summary)).' | ';
$out .= "\n".'
';
+'.sprintf(__('Creation of
page %s'), $url, Pluf_esc($this->title)).', '.__('by').' '.$user.'
';
return Pluf_Template::markSafe($out);
}
diff --git a/src/IDF/WikiRevision.php b/src/IDF/WikiRevision.php
index d85a390..ecc6181 100644
--- a/src/IDF/WikiRevision.php
+++ b/src/IDF/WikiRevision.php
@@ -162,9 +162,9 @@ class IDF_WikiRevision extends Pluf_Model
$out = "\n".''.
Pluf_esc(Pluf_Template_dateAgo($this->creation_dtime, 'without')).
' | ';
- $submitter = $this->get_submitter();
+ $stag = new IDF_Template_ShowUser();
+ $user = $stag->start($this->get_submitter(), $request, '', false);
$out .= sprintf(__('%2$s, %3$s'), $url, Pluf_esc($page->title), Pluf_esc($this->summary));
- //$out .= ''.__('Summary:').' '.Pluf_esc($this->summary).' ';
if ($this->changedRevision()) {
$out .= ' ';
$changes = $this->changes;
@@ -186,7 +186,7 @@ class IDF_WikiRevision extends Pluf_Model
}
$out .= ' |
';
$out .= "\n".'';
+'.sprintf(__('Change of
%s'), $url, Pluf_esc($page->title)).', '.__('by').' '.$user.'
';
return Pluf_Template::markSafe($out);
}