{% extends './vista/template/payment/billet.twig' %}

{% block scripts_before %}
  <script src="https://static.traycheckout.com.br/js/finger_print.js" type="text/javascript"></script>
{% endblock %}

{% block scripts %}
  <script>
    function initFingerPrint() {
      if (window.yapay.FingerPrint) {
        window.yapay.FingerPrint({{ environment }});
      } else {
        setTimeout(function () {
          initFingerPrint();
        }, 100);
      }
    }

    initFingerPrint();
  </script>

  <script>
    // as propriedades de aditionalData são adicionadas aos dados enviados por ajax para a api
    var aditionalData = [];
    aditionalData['payment_method_id'] = '{{ payment_method_id }}';
  </script>

  {{ parent() }}
{% endblock %}