{% set sAddressTypeNameLangIdent = "C4S_B2B_ADDRESS_NAME_" ~ sAddressType %} {{ translate({ ident: sAddressTypeNameLangIdent }) }}

{% if oInvoiceAddressList|length > 0 %} {% set oInvoiceAddress = '' %} {# if only one shipping address available -> set address for address display and form #} {% if oInvoiceAddressList|length == 1 %} {% for oAddress in oInvoiceAddressList %} {% set oInvoiceAddress = oAddress %} {% endfor %} {# if more than one shipping address available -> show and handle address selection #} {% elseif oInvoiceAddressList|length > 1 %}
{# show and handle address selection if multiple shipping addresses available #} {{ script({ add: "c4s_b2b_address_handler.init('c4s-b2b-address-select-" ~ sAddressType ~ "');", dynamic: __oxid_include_dynamic }) }} {% set sSelectedAddressId = oxcmp_basket.getPartnerRole(sAddressType) %} {# #}
{% endif %} {# display actual shipping address #} {% if oInvoiceAddress %} {% block c4s_b2b_address_invoice_address %} {% endblock %} {% endif %} {# hidden form fields for fancy oxid to set actual invoice address from b2b account to checkout invoice address #} {# todo : änderung auf einbindung des standard formulars, für den fall, dass rechnundsadressen geändert werden können! #} {% if not blLoadAddressInAccountView and oInvoiceAddress %}
{# *** attention! *** #} {# don't set sal / fname / lname here, cause oxid stores these values in REAL user account!! #} {# if checkout not working cause of "Bitte Wert angeben" exception, then check param "aMustFillFields" in oxid basic config and do not incomment the fields here! #} {# #} {# #} {# #} {# **** oxuser personal fields **** #}
{% endif %} {% else %}
{{ translate({ ident: "C4S_B2B_ATTENTION_LABEL" }) }}!
{{ translate({ ident: "C4S_B2B_ATTENTION_INVOICE_ADDRESS" }) }}!
{{ script({ add: " document.addEventListener('DOMContentLoaded', function() { let userNextStepButton = document.getElementById('c4s-user-next-step-btn'); if (userNextStepButton) { userNextStepButton.remove(); } });", dynamic: __oxid_include_dynamic }) }} {% endif %}
{% if blLoadAddressInAccountView %} {% endif %}