0
0
mirror of https://github.com/go-gitea/gitea.git synced 2024-11-30 18:55:17 +01:00
gitea/templates/repo/settings/hook_history.tmpl

67 lines
2.3 KiB
Cheetah
Raw Normal View History

2015-08-26 18:30:06 +02:00
{{if .PageIsSettingsHooksEdit}}
2015-08-26 19:04:23 +02:00
<h4 class="ui top attached header">
{{.i18n.Tr "repo.settings.recent_deliveries"}}
</h4>
2015-08-27 17:06:14 +02:00
<div class="ui attached table segment">
<div class="ui hook history list">
{{range .History}}
<div class="item">
<div class="meta">
{{if .IsSucceed}}
<span class="text green"><i class="octicon octicon-check"></i></span>
{{else}}
<span class="text red"><i class="octicon octicon-alert"></i></span>
{{end}}
<a class="ui blue sha label toggle button" data-target="#info-{{.ID}}">{{.UUID}}</a>
<div class="ui right">
<span class="text grey time">
{{.DeliveredString}}
</span>
</div>
</div>
<div class="info hide" id="info-{{.ID}}">
<div class="ui top attached tabular menu">
<a class="item active" data-tab="request-{{.ID}}">{{$.i18n.Tr "repo.settings.webhook.request"}}</a>
<a class="item" data-tab="response-{{.ID}}">
{{$.i18n.Tr "repo.settings.webhook.response"}}
{{if .ResponseInfo}}
{{if .IsSucceed}}
<span class="ui green label">{{.ResponseInfo.Status}}</span>
{{else}}
2015-08-28 17:36:13 +02:00
<span class="ui red label">{{.ResponseInfo.Status}}</span>
2015-08-27 17:06:14 +02:00
{{end}}
{{else}}
<span class="ui label">N/A</span>
{{end}}
</a>
</div>
<div class="ui bottom attached tab segment active" data-tab="request-{{.ID}}">
{{if .RequestInfo}}
<h5>{{$.i18n.Tr "repo.settings.webhook.headers"}}</h5>
<pre class="raw"><strong>Request URL:</strong> {{.URL}}
<strong>Request method:</strong> POST
{{ range $key, $val := .RequestInfo.Headers }}<strong>{{$key}}:</strong> {{$val}}
{{end}}</pre>
<h5>{{$.i18n.Tr "repo.settings.webhook.payload"}}</h5>
2015-08-27 17:58:50 +02:00
<pre class="raw"><code class="json">{{.PayloadContent}}</code></pre>
2015-08-27 17:06:14 +02:00
{{else}}
N/A
{{end}}
</div>
<div class="ui bottom attached tab segment" data-tab="response-{{.ID}}">
{{if .ResponseInfo}}
<h5>{{$.i18n.Tr "repo.settings.webhook.headers"}}</h5>
<pre class="raw">{{ range $key, $val := .ResponseInfo.Headers }}<strong>{{$key}}:</strong> {{$val}}
{{end}}</pre>
<h5>{{$.i18n.Tr "repo.settings.webhook.body"}}</h5>
2015-08-27 17:58:50 +02:00
<pre class="raw"><code>{{.ResponseInfo.Body}}</code></pre>
2015-08-27 17:06:14 +02:00
{{else}}
N/A
{{end}}
</div>
</div>
</div>
{{end}}
</div>
2015-08-26 18:30:06 +02:00
</div>
{{end}}