app/Plugin/Paid4/Resource/template/default/Entry/index.twig line 1

Open in your IDE?
  1. {#
  2. Copyright(c) 2020 RACCOON HOLDINGS, Inc. All rights reserved.
  3. https://paid.jp/
  4. #}
  5. <div hidden>
  6.     <div id="paid-h-adr" class="h-adr">
  7.         <span id="paid-p-country-name" class="p-country-name" style="display:none;">Japan</span>
  8.         <input id="paid-p-postal-code" type="text" class="p-postal-code" size="8" maxlength="8"><br>
  9.         {{ form_widget(form.paid_p_region) }}
  10.         <input id="paid-p-locality" type="text" class="p-locality p-street-address p-extended-address"/><br>
  11.     </div>
  12. </div>
  13. {% if is_paid_form_area %}
  14.     <div id="insert_area">
  15.         <div class="paid-form">
  16.             {{ form_widget(form.paid_register_check) }} <label >一緒に<a href="https://paid.jp/v/contents/pre/buyer/" target="_blank">Paid</a>決済の申込登録をする</label>
  17.             {{ form_errors(form.paid_register_check) }}
  18.             <div class="hidden_show">
  19.                 {{ include('@Paid4/entry_form.twig', {'paid_form': form.PaidCustomer} ,ignore_missing=true) }}
  20.                 {{ include('@Paid4/entry_copy_script.twig' ,ignore_missing=true) }}
  21.             </div>
  22.         </div>
  23.     </div>
  24. {% block javascript %}
  25.     <script>
  26.         $(function () {
  27.             $('.ec-borderedDefs').append($('#insert_area').html());
  28.             $('#insert_area').remove();
  29.         });
  30.         function setZipCode() {
  31.             entry_PaidCustomer_zip_code = document.getElementById("entry_PaidCustomer_zip_code");
  32.             target = document.getElementById("paid-p-postal-code");
  33.             target.value = entry_PaidCustomer_zip_code.value;
  34.             var $eventObject = document.createEvent( "HTMLEvents" );
  35.             $eventObject.initEvent( "keyup", true, true );
  36.             target.dispatchEvent( $eventObject );
  37.         }
  38.         function  getAddress() {
  39.             region = document.getElementById("entry_paid_p_region");
  40.             locality = document.getElementById("paid-p-locality");
  41.             entry_PaidCustomer_address_prefecture
  42.                 = document.getElementById("entry_PaidCustomer_address_prefecture");
  43.             entry_PaidCustomer_address_address1
  44.                 = document.getElementById("entry_PaidCustomer_address_address1");
  45.             entry_PaidCustomer_address_prefecture.value = region.value;
  46.             entry_PaidCustomer_address_address1.value = locality.value;
  47.         }
  48.     </script>
  49. {% endblock javascript %}
  50.     <style type="text/css">
  51.         /*中身を非表示にしておく*/
  52.         .hidden_show {
  53.             height: 0;
  54.             padding: 0;
  55.             overflow: hidden;
  56.             opacity: 0;
  57.             transition: 0.8s;
  58.         }
  59.         #entry_paid_register_check:checked  ~ .hidden_show {
  60.             padding: 10px 0;
  61.             height: auto;
  62.             opacity: 1;
  63.         }
  64.     </style>
  65. {% endif %}