New layout pages.
[wolnelektury.git] / src / wolnelektury / static / 2021 / scripts / main.js
index 99a7fc7..1ffea17 100644 (file)
 
 })();
 
-//Switch
 (function() {
-  let $switchOnce = $('#switch-once');
-  let $switchMonthly = $('#switch-monthly');
-
-  $switchMonthly.on('click', function() {
-      $('.payments-once').hide();
-      $('.payments-recurring').show();
-  });
-
-  $switchOnce.on('click', function() {
-      $('.payments-recurring').hide();
-      $('.payments-once').show();
-  });
-})();
-
-
-(function() {
-
     $('.l-checkout__payments__box button').on('click', function() {
         let container = $(this).closest('.l-checkout__payments');
-        $('input', container).val($(this).attr('data-amount'));
+        $('input', container).val($(this).val());
         $('.is-active', container).removeClass('is-active');
         $(this).closest('.l-checkout__payments__box').addClass('is-active');
         $('#kwota').val('');