diff options
author | wxiaoguang <wxiaoguang@gmail.com> | 2023-04-26 03:48:30 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-04-25 15:48:30 -0400 |
commit | 0e8045d8ea51b1bf856cfd9c57cabd8187a3a2ab (patch) | |
tree | 90294cc32a89f4354ed3ad76d328dd2973b50fbf /templates/admin/cron.tmpl | |
parent | 9219534447411f6ffe507fee64f89c619c29d501 (diff) | |
download | gitea-0e8045d8ea51b1bf856cfd9c57cabd8187a3a2ab.tar.gz gitea-0e8045d8ea51b1bf856cfd9c57cabd8187a3a2ab.zip |
Fix template function DateTime (#24317)
Before, 500 error

Diffstat (limited to 'templates/admin/cron.tmpl')
-rw-r--r-- | templates/admin/cron.tmpl | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/templates/admin/cron.tmpl b/templates/admin/cron.tmpl index 5dd6314944..267da00759 100644 --- a/templates/admin/cron.tmpl +++ b/templates/admin/cron.tmpl @@ -21,8 +21,8 @@ <td><button type="submit" class="ui green button" name="op" value="{{.Name}}" title="{{$.locale.Tr "admin.dashboard.operation_run"}}">{{svg "octicon-triangle-right"}}</button></td> <td>{{$.locale.Tr (printf "admin.dashboard.%s" .Name)}}</td> <td>{{.Spec}}</td> - <td>{{DateTime "full" (DateFmtLong .Next) (DateFmtLong .Next)}}</td> - <td>{{if gt .Prev.Year 1}}{{DateTime "full" (DateFmtLong .Prev) (DateFmtLong .Prev)}}{{else}}N/A{{end}}</td> + <td>{{DateTime "full" (DateFmtLong .Next)}}</td> + <td>{{if gt .Prev.Year 1}}{{DateTime "full" .Prev}}{{else}}N/A{{end}}</td> <td>{{.ExecTimes}}</td> <td {{if ne .Status ""}}data-tooltip-content="{{.FormatLastMessage $.locale}}"{{end}} >{{if eq .Status ""}}—{{else if eq .Status "finished"}}{{svg "octicon-check" 16}}{{else}}{{svg "octicon-x" 16}}{{end}}</td> </tr> |