numerus/web/template/contacts/new.gohtml

42 lines
1.7 KiB
Plaintext
Raw Normal View History

{{ define "title" -}}
{{( pgettext "New Contact" "title" )}}
{{- end }}
{{ define "breadcrumbs" -}}
{{- /*gotype: dev.tandem.ws/tandem/numerus/pkg.contactForm*/ -}}
2023-04-02 14:10:13 +00:00
<nav data-hx-target="main" data-hx-boost="true">
2023-02-03 12:58:10 +00:00
<p>
<a href="{{ companyURI "/" }}">{{( pgettext "Home" "title" )}}</a> /
<a href="{{ companyURI "/contacts"}}">{{( pgettext "Contacts" "title" )}}</a> /
<a>{{( pgettext "New Contact" "title" )}}</a>
</p>
</nav>
{{- end }}
{{ define "content" }}
{{- /*gotype: dev.tandem.ws/tandem/numerus/pkg.contactForm*/ -}}
<section class="dialog-content" id="new-contact-dialog-content" data-hx-target="main">
<h2>{{(pgettext "New Contact" "title")}}</h2>
<form method="POST" action="{{ companyURI "/contacts" }}" data-hx-boost="true">
{{ csrfToken }}
{{ template "input-field" .BusinessName | addInputAttr "autofocus" }}
{{ template "input-field" .VATIN }}
{{ template "input-field" .TradeName }}
{{ template "input-field" .Phone }}
{{ template "input-field" .Email }}
{{ template "input-field" .Web }}
{{ template "input-field" .Address | addInputAttr `class="width-2x"` }}
{{ template "input-field" .City }}
{{ template "input-field" .Province }}
{{ template "input-field" .PostalCode }}
{{ template "select-field" .Country | addSelectAttr `class="width-fixed"` }}
{{ template "tags-field" .Tags }}
<fieldset>
2023-02-03 12:58:10 +00:00
<button class="primary" type="submit">{{( pgettext "New contact" "action" )}}</button>
</fieldset>
</form>
</section>
{{- end }}