184 lines
6.1 KiB
HTML
184 lines
6.1 KiB
HTML
{{ define "ticket-search-result" }}
|
|
|
|
{{ if .Found }}
|
|
|
|
<h1>Ticket</h1>
|
|
|
|
<table id="ticket-table" class="mt-2 mb-4 w-100">
|
|
<tr>
|
|
<th>Hash</th>
|
|
<td>
|
|
<a href="{{ txURL .Ticket.Hash }}">
|
|
{{ .Ticket.Hash }}
|
|
</a>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Status</th>
|
|
{{ if .Ticket.Confirmed }}
|
|
<td>
|
|
Confirmed (purchase height:
|
|
<a href="{{ blockURL .Ticket.PurchaseHeight }}">{{ .Ticket.PurchaseHeight }}</a>)
|
|
</td>
|
|
{{ else }}
|
|
<td>Not confirmed</td>
|
|
{{ end }}
|
|
</tr>
|
|
<tr>
|
|
<th>Ticket Outcome</th>
|
|
<td>{{ .Ticket.Outcome }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Voting WIF</th>
|
|
<td>{{ .Ticket.VotingWIF }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Commitment Address</th>
|
|
<td>
|
|
<a href="{{ addressURL .Ticket.CommitmentAddress }}">
|
|
{{ .Ticket.CommitmentAddress }}
|
|
</a>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
|
|
<h1>Fee</h1>
|
|
|
|
<table id="ticket-table" class="mt-2 mb-4 w-100">
|
|
<tr>
|
|
<th>Fee Address</th>
|
|
<td>
|
|
<a href="{{ addressURL .Ticket.FeeAddress }}">
|
|
{{ .Ticket.FeeAddress }}
|
|
</a>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Fee Address Index</th>
|
|
<td>{{ .Ticket.FeeAddressIndex }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Fee Amount</th>
|
|
<td>{{ atomsToDCR .Ticket.FeeAmount }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Fee Expiration</th>
|
|
<td>{{ .Ticket.FeeExpiration }} ({{ dateTime .Ticket.FeeExpiration }}) </td>
|
|
</tr>
|
|
<tr>
|
|
<th>Fee Tx Hash</th>
|
|
<td>
|
|
<a href="{{ txURL .Ticket.FeeTxHash }}">
|
|
{{ .Ticket.FeeTxHash }}
|
|
</a>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Fee Tx</th>
|
|
<td>{{ .Ticket.FeeTxHex }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Fee Tx Status</th>
|
|
<td>{{ .Ticket.FeeTxStatus }}</td>
|
|
</tr>
|
|
</table>
|
|
|
|
<h1>Vote Choices</h1>
|
|
|
|
<table id="ticket-table" class="mt-2 mb-4 w-100">
|
|
<tr>
|
|
<th>Consensus Vote Choices</th>
|
|
<td>
|
|
{{ range $key, $value := .Ticket.VoteChoices }}
|
|
{{ $key }}: {{ $value }} <br />
|
|
{{ end }}
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>
|
|
Vote Choice Changes<br />
|
|
<em>({{ .MaxVoteChanges }} most recent)</em>
|
|
</th>
|
|
<td>
|
|
{{ range $key, $value := .VoteChanges }}
|
|
<details>
|
|
<summary>
|
|
{{ if eq $key 0}}
|
|
Initial choices
|
|
{{ else }}
|
|
Change {{ $key }}
|
|
{{ end }}
|
|
</summary>
|
|
<table class="my-2">
|
|
<tr>
|
|
<th>Request</th>
|
|
<td>{{ indentJSON $value.Request }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Request<br />Signature</th>
|
|
<td>{{ $value.RequestSignature }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Response</th>
|
|
<td>{{ indentJSON $value.Response }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Response<br />Signature</th>
|
|
<td>{{ $value.ResponseSignature }}</td>
|
|
</tr>
|
|
</table>
|
|
</details>
|
|
{{end}}
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
|
|
<h1>Alternate Signing Address</h1>
|
|
|
|
<table id="ticket-table" class="mt-2 mb-4 w-100">
|
|
<tr>
|
|
<th>Alternate Signing Address</th>
|
|
<td>
|
|
{{if .AltSignAddrData}}
|
|
<a href="{{ addressURL .AltSignAddrData.AltSignAddr }}">
|
|
{{ .AltSignAddrData.AltSignAddr }}
|
|
</a>
|
|
{{end}}
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>
|
|
AltSignAddress Change
|
|
</th>
|
|
<td>
|
|
{{if .AltSignAddrData}}
|
|
<details>
|
|
<table class="my-2">
|
|
<tr>
|
|
<th>Request</th>
|
|
<td>{{ indentJSON .AltSignAddrData.Req }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Request<br />Signature</th>
|
|
<td>{{ .AltSignAddrData.ReqSig }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Response</th>
|
|
<td>{{ indentJSON .AltSignAddrData.Resp }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Response<br />Signature</th>
|
|
<td>{{ .AltSignAddrData.RespSig }}</td>
|
|
</tr>
|
|
</table>
|
|
</details>
|
|
{{end}}
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
|
|
{{ else }}
|
|
<p>No ticket found with hash <span class="code">{{ .Hash }}</span></p>
|
|
{{ end }}
|
|
{{ end }}
|