WordPress.org

Making WordPress.org

Changeset 1032


Ignore:
Timestamp:
12/10/2014 05:27:05 PM (6 years ago)
Author:
kovshenin
Message:

WordCamp.org: Allow reminders to be sent to Sponsor Wranglers.

Fixes #690.
Props nvwd.

Location:
sites/trunk/wordcamp.org/public_html/wp-content/plugins/wordcamp-organizer-reminders
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordcamp.org/public_html/wp-content/plugins/wordcamp-organizer-reminders/wcor-mailer.php

    r859 r1032  
    245245
    246246            $recipient = $multi_event_sponsors->get_sponsor_emails( $multi_event_sponsors->get_wordcamp_me_sponsors( $wordcamp_id ) );
     247        } elseif ( 'wcor_send_sponsor_wrangler' == $send_where ) {
     248           
     249            // If the Sponsor Wrangler email is invalid, use the default email address.
     250            if ( is_email( get_post_meta( $wordcamp_id, 'Sponsor Wrangler E-mail Address', true ) ) ) {
     251                $recipient = get_post_meta( $wordcamp_id, 'Sponsor Wrangler E-mail Address', true );
     252            } else {
     253                $recipient = get_post_meta( $wordcamp_id, 'Email Address', true );
     254            }
     255
    247256        } else {
    248257            $email_address_key = wcpt_key_to_str( 'E-mail Address', 'wcpt_' );
  • sites/trunk/wordcamp.org/public_html/wp-content/plugins/wordcamp-organizer-reminders/wcor-reminder.php

    r844 r1032  
    105105
    106106                <tr>
     107                    <th><input id="wcor_send_sponsor_wrangler" name="wcor_send_where" type="radio" value="wcor_send_sponsor_wrangler" <?php checked( $send_where, 'wcor_send_sponsor_wrangler' ); ?>></th>
     108                    <td colspan="2"><label for="wcor_send_sponsor_wrangler">The Sponsor Wrangler</label></td>
     109                </tr>
     110
     111                <tr>
    107112                    <th><input id="wcor_send_mes" name="wcor_send_where" type="radio" value="wcor_send_mes" <?php checked( $send_where, 'wcor_send_mes' ); ?>></th>
    108113                    <td colspan="2"><label for="wcor_send_mes">The WordCamp's Multi-Event Sponsors</label></td>
     
    358363    protected function save_post_meta( $post, $new_meta ) {
    359364        if ( isset( $new_meta['wcor_send_where'] ) ) {
    360             if ( in_array( $new_meta['wcor_send_where'], array( 'wcor_send_organizers', 'wcor_send_mes', 'wcor_send_custom' ) ) ) {
     365            if ( in_array( $new_meta['wcor_send_where'], array( 'wcor_send_organizers', 'wcor_send_sponsor_wrangler', 'wcor_send_mes', 'wcor_send_custom' ) ) ) {
    361366                update_post_meta( $post->ID, 'wcor_send_where', $new_meta['wcor_send_where'] );
    362367            }
Note: See TracChangeset for help on using the changeset viewer.