From 287c3ce6650465d7bde9bf105cdfeb8dd880a214 Mon Sep 17 00:00:00 2001 From: Remco Tolsma <869674+remcotolsma@users.noreply.github.com> Date: Tue, 17 Jan 2023 10:30:32 +0100 Subject: [PATCH 01/38] Fill payment feed status confirmation settings server-side. --- views/html-admin-feed-settings.php | 29 +++++++++++++++++++++++++---- 1 file changed, 25 insertions(+), 4 deletions(-) diff --git a/views/html-admin-feed-settings.php b/views/html-admin-feed-settings.php index e982c2e..bdcc36b 100644 --- a/views/html-admin-feed-settings.php +++ b/views/html-admin-feed-settings.php @@ -425,9 +425,10 @@ function( $action ) { links[ $name ] ) ) { $link = $pay_feed->links[ $name ]; @@ -459,11 +460,31 @@ function( $action ) { ', + ''; + ?>
  • From 5d20a9102b4f22faa5b9ab7bef903bd4cc80f928 Mon Sep 17 00:00:00 2001 From: Remco Tolsma <869674+remcotolsma@users.noreply.github.com> Date: Tue, 17 Jan 2023 10:30:53 +0100 Subject: [PATCH 02/38] More descriptive first empty choice option. --- views/html-admin-feed-settings.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/views/html-admin-feed-settings.php b/views/html-admin-feed-settings.php index bdcc36b..5028aaf 100644 --- a/views/html-admin-feed-settings.php +++ b/views/html-admin-feed-settings.php @@ -499,7 +499,7 @@ function( $action ) { [ 'selected' => esc_attr( $page_id ), 'name' => esc_attr( '_pronamic_pay_gf_links[' . $name . '][page_id]' ), - 'show_option_none' => esc_html__( '— Select —', 'pronamic_ideal' ), + 'show_option_none' => esc_html__( '— Select Page —', 'pronamic_ideal' ), ] ); From 02a23cebfc3d4e407def6db292f5d0a95702ed42 Mon Sep 17 00:00:00 2001 From: Remco Tolsma <869674+remcotolsma@users.noreply.github.com> Date: Tue, 17 Jan 2023 10:33:16 +0100 Subject: [PATCH 03/38] Remove unused `updateConfirmationFields` function, is now handled server side. --- js/admin.js | 38 -------------------------------------- js/admin.min.js | 2 +- js/admin.min.js.map | 2 +- 3 files changed, 2 insertions(+), 40 deletions(-) diff --git a/js/admin.js b/js/admin.js index abafcaa..bf5f189 100644 --- a/js/admin.js +++ b/js/admin.js @@ -17,7 +17,6 @@ elements.formId = $element.find( '#_pronamic_pay_gf_form_id' ); elements.configId = $element.find( '#gf_ideal_config_id' ); elements.delayPostCreationItem = $element.find( '#gf_ideal_delay_post_creation_item' ); - elements.confirmationSelectFields = $element.find( '.gf_ideal_confirmation_select' ); elements.userRoleFieldId = $element.find( '#gf_ideal_user_role_field_id' ); elements.delayNotifications = $element.find( '#gf_ideal_delay_notifications' ); elements.fieldSelectFields = $element.find( 'select.field-select' ); @@ -58,42 +57,6 @@ elements.delayPostCreationItem.toggle( display ); }; - /** - * Update confirmations - */ - this.updateConfirmationFields = function() { - elements.confirmationSelectFields.empty(); - $( '
  • ").appendTo(r.delayNotifications),n="pronamic-pay-gf-notification-"+i.id,d('').attr("id",n).val(i.id).prop("checked",0<=d.inArray(i.id,s.delayNotificationIds)).appendTo(t),t.append(" "),d("
  • ").appendTo(r.delayNotifications),n="pronamic-pay-gf-notification-"+i.id,d('').attr("id",n).val(i.id).prop("checked",0<=d.inArray(i.id,s.delayNotificationIds)).appendTo(t),t.append(" "),d("
  • ").appendTo(r.delayNotifications),n="pronamic-pay-gf-notification-"+i.id,d('').attr("id",n).val(i.id).prop("checked",0<=d.inArray(i.id,s.delayNotificationIds)).appendTo(t),t.append(" "),d("
  • ' ).appendTo( elements.delayNotifications ); - - var fieldId = 'pronamic-pay-gf-notification-' + notification.id; - - $( '' ) - .attr( 'id', fieldId ) - .val( notification.id ) - .prop( 'checked', $.inArray( notification.id, feed.delayNotificationIds ) >= 0 ) - .appendTo( item ); - - item.append( ' ' ); - - $( '