Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue/1847 #1863

Merged
merged 30 commits into from
Jul 17, 2017
Merged

Issue/1847 #1863

merged 30 commits into from
Jul 17, 2017

Conversation

mehul0810
Copy link
Contributor

Description

This PR is for #1847

How Has This Been Tested?

I've tested it with various list page to make sure the pagination works properly as well as works on jumping to a specific page number. Also, checked that there is no confirmation popup on jumping to a specific page number on Donations page.

  • Donations
  • Donors
  • Reports > Forms
  • Reports > Donors
  • Tools > Logs > Donations
  • Tools > Logs > Payment Errors
  • Tools > Logs > API Requests

Also, Taken care of long urls with _wp_http_referrer included with listing of Logs.

Screenshots

donations_gif

Types of changes

Bug fix (non-breaking change which fixes an issue)

Checklist:

  • My code is tested.
  • My code follows the WordPress code style.
  • My code has proper inline documentation.

var status = 'Pre-approval';

// Check if admin did not select any payment.
if ( ! parseInt( $payments ) ) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please attempt to optimize this into one function. DRYer.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@DevinWalker Optimised the script. Please check.

$give_table->prepare_items();
$give_table->display();
?>
<form class="give-forms-reports-filter" method="get">
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mehul0810 Instead of directly putting form tag around the table, We can achieve this by setting api because these pages are generated by setting api

For ref:
https://github.com/WordImpress/Give/blob/master/includes/admin/reporting/class-settings-forms.php#L53
https://github.com/WordImpress/Give/blob/master/includes/admin/views/html-admin-settings.php#L21

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ravinderk I've implemented the changes as per your suggestions.

do_action( 'give_logs_donations_top' );
?>

<form class="give-logs-sales-filter" method="get" action="<?php echo 'edit.php?post_type=give_forms&page=give-tools&tab=logs'; ?>">
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mehul0810 Check my comment on line number 223

@DevinWalker DevinWalker dismissed ravinderk’s stale review July 17, 2017 17:51

I see you've marked this as ready

status = 'preapproval';
}
// Get message on basis of payment count.
confirm_action_notice = ( 1 < $payments ) ?
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice!

@DevinWalker DevinWalker merged commit 234c378 into impress-org:release/1.8.12 Jul 17, 2017
@mehul0810 mehul0810 deleted the issue/1847 branch December 8, 2017 10:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants