Changeset 2705
- Timestamp:
- 03/08/2016 01:46:55 PM (9 years ago)
- Location:
- sites/trunk/wordcamp.org/public_html/wp-content/plugins/wordcamp-payments
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordcamp.org/public_html/wp-content/plugins/wordcamp-payments/includes/reimbursement-request.php
r2683 r2705 322 322 $selected_reason = get_post_meta( $post->ID, '_wcbrr_reason', true ); 323 323 $other_reason = get_post_meta( $post->ID, '_wcbrr_reason_other', true ); 324 $date_paid = get_post_meta( $post->ID, '_wcbrr_date_paid', true ); 324 325 325 326 if ( empty ( $name_of_payer ) ) { … … 453 454 validate_and_save_text_fields( $post_id, $text_fields, $_POST ); 454 455 456 // Save payment date 457 if ( isset( $_POST['_wcbrr_date_paid'] ) && current_user_can( 'manage_network' ) ) { 458 $date_paid = sanitize_text_field( $_POST['_wcbrr_date_paid'] ); 459 $date_paid = absint( strtotime( $date_paid ) ); 460 update_post_meta( $post->ID, '_wcbrr_date_paid', $date_paid ); 461 } 462 455 463 \WordCamp_Budgets::validate_save_payment_method_fields( $post_id, 'wcbrr' ); 456 464 -
sites/trunk/wordcamp.org/public_html/wp-content/plugins/wordcamp-payments/views/reimbursement-request/metabox-general-information.php
r2683 r2705 85 85 86 86 <li> 87 <label for="_wcbrr_date_paid"> 88 <?php _e( 'Payment Release Date:', 'wordcamporg' ); ?> 89 </label> 90 91 <?php if ( $date_paid ) $date_paid = date( 'Y-m-d', $date_paid ); ?> 92 <input type="date" class="regular-text" id="_wcbrr_date_paid" name="_wcbrr_date_paid" 93 <?php if ( ! current_user_can( 'manage_network' ) ) : ?>readonly<?php endif; ?> 94 value="<?php echo esc_attr( $date_paid ); ?>" /> 95 96 <li> 87 97 <label for="_wcbrr_files"> 88 98 <?php _e( 'Files:', 'wordcamporg' ); ?>
Note: See TracChangeset
for help on using the changeset viewer.