<form method="post" action="/forms/organizations/{{this.org.id}}/type/" data-element="popup" data-id="org_type">
    <div class="field" data-id="org_type">
        <label>{{i18n "org_details.prop.type"}}*</label>
        <select name="org_type" class="full-width" required>
            {{#each Layout.ORG_TYPES}}
            <option value="{{this}}"{{#is ../this.org.organization_type this}} selected{{/is}}>{{this}}</option>
            {{/each}}
        </select>
    </div>
    <div class="field" data-id="client_id">
        <label data-alt="{{i18n "org_details.form.org_type_client_id.normal"}}*">{{i18n "org_details.form.org_type_client_id.extended"}}*</label>
        <input type="text" name="client_id<number>" value="{{this.org.billing.client_id}}" class="full-width">
    </div>
    <div class="field" data-id="person_id">
        <label data-alt="{{i18n "org_details.form.org_type_person_id"}}*">{{i18n "org_details.form.org_type_person_id"}}</label>
        <input type="text" name="person_id<number>" value="{{this.org.billing.person_id}}" class="full-width">
    </div>
    <div class="field" data-id="partner_id">
        {{#if Layout.partners.length}}
        <label data-alt="{{i18n "org_details.form.org_type_partner.normal"}}*">{{i18n "org_details.form.org_type_partner.extended"}}"</label>
        <select name="partner_id<number>" class="full-width">
            {{#each Layout.partners}}
            <option value="{{this.id}}"{{#is ../this.org.partner_id this.id}} selected{{/is}}>{{this.name}}</option>
            {{/each}}
        </select>
        {{else}}
        <label data-alt="{{i18n "org_details.form.org_type_partner_id.normal"}}*">{{i18n "org_details.form.org_type_partner_id.extended"}}"</label>
        <input type="text" name="partner_id<number>" value="{{this.org.partner_id}}" class="full-width">
        {{/if}}
    </div>
    <div class="field">
        <label>{{i18n "common.form.comment"}}*</label>
        <input type="text" name="comment" class="full-width" required>
    </div>
    <div class="actions">
        <button type="submit" class="highlighted" data-action="ok">{{i18n "common.action.apply"}}</button>
        <label for="unchanged_org_type" class="button" data-action="cancel">{{i18n "common.action.cancel"}}</label>
    </div>
    <input type="hidden" name="_method" value="patch">
</form>
