Files
EasyDNS-Web/internal/server/web/templates/pages/replace-zone.gohtml
T
Mateusz Gruszczyński 8c4d463f1e
Go quality gates / test (push) Waiting to run
first commit
2026-11-30 11:37:40 +01:00

4 lines
1.9 KiB
Go Template

{{define "content"}}<div class="form-layout"><section class="panel"><div class="panel-head"><div><h2>Full zone-file replacement</h2><p>{{.Data.Zone.Name}} · submit complete replacement content</p></div></div><div class="panel-body"><div class="notice danger"><strong>Destructive replacement.</strong> The EasyDNS API does not return original zone file text. Paste a complete replacement file that you already possess.</div></div>
<form class="form-body" method="post" action="{{.Data.ZoneURL}}/replace"><input type="hidden" name="_csrf" value="{{.CSRF}}"><input type="hidden" name="etag" value="{{.Data.ETag}}"><div class="field-row"><label class="field-label" for="zoneFull">Complete zone file <span class="required">*</span></label><textarea class="field code-input mono" id="zoneFull" rows="15" spellcheck="false" name="zone_file" required placeholder="Paste the full zone file here. Nothing is preloaded.">{{selectval .Data.Form "zone_file"}}</textarea></div><div class="field-row"><label class="field-label" for="replaceConfirm">Type REPLACE to confirm <span class="required">*</span></label><input id="replaceConfirm" name="confirm" class="field mono" required pattern="REPLACE" autocomplete="off" placeholder="REPLACE"></div><div class="form-actions"><a class="btn-ui" href="{{.Data.ZoneURL}}">Cancel</a><button class="btn-ui btn-danger-ui" type="submit">Replace zone contents</button></div></form></section>
<aside class="panel guide"><div class="panel-head"><h2>Before you continue</h2></div><div class="panel-body"><p>Back up the original zone from its source outside this panel. The API validates the full replacement, calculates the diff, updates the serial and sends NOTIFY where configured.</p><div class="data-row"><span>Current serial</span><strong class="mono">{{.Data.Zone.SerialText}}</strong></div><div class="data-row"><span>Conflict</span><strong>412</strong></div><div class="data-row"><span>Invalid content</span><strong>422</strong></div></div></aside></div>{{end}}