diff options
Diffstat (limited to 'templates/repo')
-rw-r--r-- | templates/repo/activity.tmpl | 12 | ||||
-rw-r--r-- | templates/repo/branch/list.tmpl | 2 | ||||
-rw-r--r-- | templates/repo/issue/list.tmpl | 2 | ||||
-rw-r--r-- | templates/repo/issue/milestones.tmpl | 2 | ||||
-rw-r--r-- | templates/repo/issue/view_content.tmpl | 2 | ||||
-rw-r--r-- | templates/repo/issue/view_content/comments.tmpl | 2 | ||||
-rw-r--r-- | templates/repo/issue/view_title.tmpl | 4 | ||||
-rw-r--r-- | templates/repo/release/list.tmpl | 4 | ||||
-rw-r--r-- | templates/repo/settings/deploy_keys.tmpl | 2 | ||||
-rw-r--r-- | templates/repo/settings/options.tmpl | 2 | ||||
-rw-r--r-- | templates/repo/user_cards.tmpl | 2 | ||||
-rw-r--r-- | templates/repo/wiki/pages.tmpl | 2 |
12 files changed, 19 insertions, 19 deletions
diff --git a/templates/repo/activity.tmpl b/templates/repo/activity.tmpl index eb761ff492..cd528582fb 100644 --- a/templates/repo/activity.tmpl +++ b/templates/repo/activity.tmpl @@ -86,7 +86,7 @@ {{if not .IsTag}} <a class="title has-emoji" href="{{$.Repository.HTMLURL}}/src/{{.TagName}}">{{.Title}}</a> {{end}} - {{TimeSince .Created $.Lang}} + {{TimeSinceUnix .CreatedUnix $.Lang}} </p> {{end}} </div> @@ -102,7 +102,7 @@ <p class="desc"> <div class="ui purple label">{{$.i18n.Tr "repo.activity.merged_prs_label"}}</div> #{{.Index}} <a class="title has-emoji" href="{{$.Repository.HTMLURL}}/pulls/{{.Index}}">{{.Issue.Title}}</a> - {{TimeSince .Merged $.Lang}} + {{TimeSinceUnix .MergedUnix $.Lang}} </p> {{end}} </div> @@ -118,7 +118,7 @@ <p class="desc"> <div class="ui green label">{{$.i18n.Tr "repo.activity.opened_prs_label"}}</div> #{{.Index}} <a class="title has-emoji" href="{{$.Repository.HTMLURL}}/pulls/{{.Index}}">{{.Issue.Title}}</a> - {{TimeSince .Issue.Created $.Lang}} + {{TimeSinceUnix .Issue.CreatedUnix $.Lang}} </p> {{end}} </div> @@ -134,7 +134,7 @@ <p class="desc"> <div class="ui red label">{{$.i18n.Tr "repo.activity.closed_issue_label"}}</div> #{{.Index}} <a class="title has-emoji" href="{{$.Repository.HTMLURL}}/issues/{{.Index}}">{{.Title}}</a> - {{TimeSince .Updated $.Lang}} + {{TimeSinceUnix .UpdatedUnix $.Lang}} </p> {{end}} </div> @@ -150,7 +150,7 @@ <p class="desc"> <div class="ui green label">{{$.i18n.Tr "repo.activity.new_issue_label"}}</div> #{{.Index}} <a class="title has-emoji" href="{{$.Repository.HTMLURL}}/issues/{{.Index}}">{{.Title}}</a> - {{TimeSince .Created $.Lang}} + {{TimeSinceUnix .CreatedUnix $.Lang}} </p> {{end}} </div> @@ -174,7 +174,7 @@ {{else}} <a class="title has-emoji" href="{{$.Repository.HTMLURL}}/issues/{{.Index}}">{{.Title}}</a> {{end}} - {{TimeSince .Updated $.Lang}} + {{TimeSinceUnix .UpdatedUnix $.Lang}} </p> {{end}} </div> diff --git a/templates/repo/branch/list.tmpl b/templates/repo/branch/list.tmpl index a1bbc17677..bc00d0d717 100644 --- a/templates/repo/branch/list.tmpl +++ b/templates/repo/branch/list.tmpl @@ -39,7 +39,7 @@ <td> {{if .IsDeleted}} <s>{{.Name}}</s> - <p class="time">{{$.i18n.Tr "repo.branch.deleted_by" .DeletedBranch.DeletedBy.Name}} {{TimeSince .DeletedBranch.Deleted $.i18n.Lang}}</p> + <p class="time">{{$.i18n.Tr "repo.branch.deleted_by" .DeletedBranch.DeletedBy.Name}} {{TimeSinceUnix .DeletedBranch.DeletedUnix $.i18n.Lang}}</p> {{else}} {{.Name}} <p class="time">{{$.i18n.Tr "org.repo_updated"}} {{TimeSince .Commit.Committer.When $.i18n.Lang}}</p> diff --git a/templates/repo/issue/list.tmpl b/templates/repo/issue/list.tmpl index bb6170a881..dec2881be8 100644 --- a/templates/repo/issue/list.tmpl +++ b/templates/repo/issue/list.tmpl @@ -163,7 +163,7 @@ <div class="issue list"> {{range .Issues}} - {{ $timeStr:= TimeSince .Created $.Lang }} + {{ $timeStr:= TimeSinceUnix .CreatedUnix $.Lang }} <li class="item"> <div class="ui checkbox issue-checkbox"> <input type="checkbox" data-issue-id={{.ID}}></input> diff --git a/templates/repo/issue/milestones.tmpl b/templates/repo/issue/milestones.tmpl index 3703301e19..de52bd42f0 100644 --- a/templates/repo/issue/milestones.tmpl +++ b/templates/repo/issue/milestones.tmpl @@ -50,7 +50,7 @@ </div> </div> <div class="meta"> - {{ $closedDate:= TimeSince .ClosedDate $.Lang }} + {{ $closedDate:= TimeSinceUnix .ClosedDateUnix $.Lang }} {{if .IsClosed}} <span class="octicon octicon-clock"></span> {{$.i18n.Tr "repo.milestones.closed" $closedDate|Str2html}} {{else}} diff --git a/templates/repo/issue/view_content.tmpl b/templates/repo/issue/view_content.tmpl index 795844d5d3..4343aec9fc 100644 --- a/templates/repo/issue/view_content.tmpl +++ b/templates/repo/issue/view_content.tmpl @@ -8,7 +8,7 @@ {{template "repo/issue/view_title" .}} {{end}} - {{ $createdStr:= TimeSince .Issue.Created $.Lang }} + {{ $createdStr:= TimeSinceUnix .Issue.CreatedUnix $.Lang }} <div class="twelve wide column comment-list"> <ui class="ui comments"> <div class="comment"> diff --git a/templates/repo/issue/view_content/comments.tmpl b/templates/repo/issue/view_content/comments.tmpl index f073fe8108..49a0216e83 100644 --- a/templates/repo/issue/view_content/comments.tmpl +++ b/templates/repo/issue/view_content/comments.tmpl @@ -1,5 +1,5 @@ {{range .Issue.Comments}} - {{ $createdStr:= TimeSince .Created $.Lang }} + {{ $createdStr:= TimeSinceUnix .CreatedUnix $.Lang }} <!-- 0 = COMMENT, 1 = REOPEN, 2 = CLOSE, 3 = ISSUE_REF, 4 = COMMIT_REF, 5 = COMMENT_REF, 6 = PULL_REF, 7 = COMMENT_LABEL, 12 = START_TRACKING, 13 = STOP_TRACKING, 14 = ADD_TIME_MANUAL --> {{if eq .Type 0}} diff --git a/templates/repo/issue/view_title.tmpl b/templates/repo/issue/view_title.tmpl index 4650ba4c80..d69f699ac1 100644 --- a/templates/repo/issue/view_title.tmpl +++ b/templates/repo/issue/view_title.tmpl @@ -26,7 +26,7 @@ {{if .Issue.IsPull}} {{if .Issue.PullRequest.HasMerged}} - {{ $mergedStr:= TimeSince .Issue.PullRequest.Merged $.Lang }} + {{ $mergedStr:= TimeSinceUnix .Issue.PullRequest.MergedUnix $.Lang }} <a {{if gt .Issue.PullRequest.Merger.ID 0}}href="{{.Issue.PullRequest.Merger.HomeLink}}"{{end}}>{{.Issue.PullRequest.Merger.Name}}</a> <span class="pull-desc">{{$.i18n.Tr "repo.pulls.merged_title_desc" .NumCommits .HeadTarget .BaseTarget $mergedStr | Str2html}}</span> {{else}} @@ -34,7 +34,7 @@ <span class="pull-desc">{{$.i18n.Tr "repo.pulls.title_desc" .NumCommits .HeadTarget .BaseTarget | Str2html}}</span> {{end}} {{else}} - {{ $createdStr:= TimeSince .Issue.Created $.Lang }} + {{ $createdStr:= TimeSinceUnix .Issue.CreatedUnix $.Lang }} <span class="time-desc"> {{if gt .Issue.Poster.ID 0}} {{$.i18n.Tr "repo.issues.opened_by" $createdStr .Issue.Poster.HomeLink .Issue.Poster.Name | Safe}} diff --git a/templates/repo/release/list.tmpl b/templates/repo/release/list.tmpl index 2fed9ae588..0a3af5a844 100644 --- a/templates/repo/release/list.tmpl +++ b/templates/repo/release/list.tmpl @@ -18,7 +18,7 @@ <li class="ui grid"> <div class="ui four wide column meta"> {{if .IsTag}} - {{if .Created}}<span class="time">{{TimeSince .Created $.Lang}}</span>{{end}} + {{if .CreatedUnix}}<span class="time">{{TimeSinceUnix .CreatedUnix $.Lang}}</span>{{end}} {{else}} {{if .IsDraft}} <span class="ui yellow label">{{$.i18n.Tr "repo.release.draft"}}</span> @@ -55,7 +55,7 @@ <img class="img-10" src="{{.Publisher.RelAvatarLink}}"> <a href="{{AppSubUrl}}/{{.Publisher.Name}}">{{.Publisher.Name}}</a> </span> - {{if .Created}}<span class="time">{{TimeSince .Created $.Lang}}</span>{{end}} + {{if .CreatedUnix}}<span class="time">{{TimeSinceUnix .CreatedUnix $.Lang}}</span>{{end}} <span class="ahead">{{$.i18n.Tr "repo.release.ahead" .NumCommitsBehind .Target | Str2html}}</span> </p> <div class="markdown desc"> diff --git a/templates/repo/settings/deploy_keys.tmpl b/templates/repo/settings/deploy_keys.tmpl index caf9f29ce5..3b22be532b 100644 --- a/templates/repo/settings/deploy_keys.tmpl +++ b/templates/repo/settings/deploy_keys.tmpl @@ -31,7 +31,7 @@ {{.Fingerprint}} </div> <div class="activity meta"> - <i>{{$.i18n.Tr "settings.add_on"}} <span>{{DateFmtShort .Created}}</span> — <i class="octicon octicon-info"></i> {{if .HasUsed}}{{$.i18n.Tr "settings.last_used"}} <span {{if .HasRecentActivity}}class="green"{{end}}>{{DateFmtShort .Updated}}</span>{{else}}{{$.i18n.Tr "settings.no_activity"}}{{end}}</i> + <i>{{$.i18n.Tr "settings.add_on"}} <span>{{.CreatedUnix.FormatShort}}</span> — <i class="octicon octicon-info"></i> {{if .HasUsed}}{{$.i18n.Tr "settings.last_used"}} <span {{if .HasRecentActivity}}class="green"{{end}}>{{.UpdatedUnix.FormatShort}}</span>{{else}}{{$.i18n.Tr "settings.no_activity"}}{{end}}</i> </div> </div> </div> diff --git a/templates/repo/settings/options.tmpl b/templates/repo/settings/options.tmpl index ee738cc9e9..41a91ea26e 100644 --- a/templates/repo/settings/options.tmpl +++ b/templates/repo/settings/options.tmpl @@ -76,7 +76,7 @@ <input type="hidden" name="action" value="mirror-sync"> <div class="inline field"> <label>{{.i18n.Tr "repo.mirror_last_synced"}}</label> - <span>{{.Mirror.Updated}}</span> + <span>{{.Mirror.UpdatedUnix.AsTime}}</span> </div> <div class="field"> <button class="ui blue button">{{$.i18n.Tr "repo.settings.sync_mirror"}}</button> diff --git a/templates/repo/user_cards.tmpl b/templates/repo/user_cards.tmpl index c22caf2576..5288d05ef9 100644 --- a/templates/repo/user_cards.tmpl +++ b/templates/repo/user_cards.tmpl @@ -16,7 +16,7 @@ {{else if .Location}} <span class="octicon octicon-location"></span> {{.Location}} {{else}} - <span class="octicon octicon-clock"></span> {{$.i18n.Tr "user.join_on"}} {{DateFmtShort .Created}} + <span class="octicon octicon-clock"></span> {{$.i18n.Tr "user.join_on"}} {{.CreatedUnix.FormatShort}} {{end}} </div> </li> diff --git a/templates/repo/wiki/pages.tmpl b/templates/repo/wiki/pages.tmpl index 8437e9b6b3..2829b61374 100644 --- a/templates/repo/wiki/pages.tmpl +++ b/templates/repo/wiki/pages.tmpl @@ -18,7 +18,7 @@ <i class="octicon octicon-file-text"></i> <a href="{{$.RepoLink}}/wiki/{{.SubURL}}">{{.Name}}</a> </td> - {{$timeSince := TimeSince .Updated $.Lang}} + {{$timeSince := TimeSinceUnix .UpdatedUnix $.Lang}} <td class="text right grey">{{$.i18n.Tr "repo.wiki.last_updated" $timeSince | Safe}}</td> </tr> {{end}} |