Making WordPress.org


Ignore:
Timestamp:
02/26/2016 06:17:34 PM (11 years ago)
Author:
kovshenin
Message:

WordCamp Budgets: Allow network admins to mark requests as pending payment via the dashboard.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordcamp.org/public_html/wp-content/plugins/wordcamp-payments-network/includes/payment-requests-list-table.php

    r2632 r2641  
    150150
    151151                if ( $request->post_status == 'wcb-pending-approval' ) {
    152                         $approve_url = wp_nonce_url( add_query_arg( array(
     152                        $action_url = wp_nonce_url( add_query_arg( array(
    153153                                'wcb-approve' => sprintf( '%d-%d', $blog_id, $request->ID ),
    154154                        ) ), sprintf( 'wcb-approve-%d-%d', $blog_id, $request->ID ) );
    155155
    156                         $actions['wcb-approve'] = sprintf( '<a style="color: green;" onclick="return confirm(\'Approve this payment request?\');" href="%s">Approve</a>', esc_url( $approve_url ) );
     156                        $actions['wcb-approve'] = sprintf( '<a style="color: green;" onclick="return confirm(\'Approve this payment request?\');" href="%s">Approve</a>', esc_url( $action_url ) );
     157
     158                } elseif ( $request->post_status == 'wcb-approved' ) {
     159                        $action_url = wp_nonce_url( add_query_arg( array(
     160                                'wcb-set-pending-payment' => sprintf( '%d-%d', $blog_id, $request->ID ),
     161                        ) ), sprintf( 'wcb-set-pending-payment-%d-%d', $blog_id, $request->ID ) );
     162
     163                        $actions['wcb-set-pending-payment'] = sprintf( '<a style="color: green;" onclick="return confirm(\'Set this request as pending payment?\');" href="%s">Set as Pending Payment</a>', esc_url( $action_url ) );
    157164                }
    158165
Note: See TracChangeset for help on using the changeset viewer.