New layout pages.
[wolnelektury.git] / src / club / templates / payu / rec_widget.html
diff --git a/src/club/templates/payu/rec_widget.html b/src/club/templates/payu/rec_widget.html
new file mode 100644 (file)
index 0000000..89b114b
--- /dev/null
@@ -0,0 +1,26 @@
+<h3>Podaj dane karty pĹ‚atniczej</h3>
+<div class="iframe">
+  <form id="theform" method='POST'>
+    {% csrf_token %}
+    {{ form }}
+  </form>
+
+  <script>
+   function paymentcallback(data) {
+       $("#theform #id_token").val(data.value);
+       $("#theform").submit()
+   }
+  </script>
+
+  <div id="payu-widget"></div>
+  <script
+      src="{{ pos.get_api_host }}/front/widget/js/payu-bootstrap.js"
+
+      {% for k, v in widget_args.items %}
+          {{ k }}="{{ v }}"
+      {% endfor %}
+
+      success-callback="paymentcallback"
+      sig="{{ widget_sig }}">
+  </script>
+</div>