Index: civicrm/trunk/sites/all/modules/queue2civicrm/recurring/recurring.module |
— | — | @@ -99,7 +99,7 @@ |
100 | 100 | } |
101 | 101 | |
102 | 102 | if ($recurring_processed > 0) { |
103 | | - watchdog('recurring', 'Successfully processed ' . $recurring_processed . ' contribution(s).'); |
| 103 | + watchdog('recurring', 'Successfully processed ' . $recurring_processed . ' subscription messages.'); |
104 | 104 | } |
105 | 105 | else { |
106 | 106 | watchdog('recurring', 'No contributions processed.'); |
— | — | @@ -398,7 +398,7 @@ |
399 | 399 | } |
400 | 400 | |
401 | 401 | $query = "UPDATE {civicrm.civicrm_contribution_recur} SET end_date='%s' WHERE trxn_id=%d"; |
402 | | - $result = db_query( $query, date( 'Y-m-d H:i:s', $msg[ 'end_date' ] ), date( 'Y-m-d H:i:s', $msg[ 'subscr_id' ] )); |
| 402 | + $result = db_query( $query, date( 'Y-m-d H:i:s', $msg[ 'end_date' ] ), $msg[ 'subscr_id' ] ); |
403 | 403 | if ( !$result ) { |
404 | 404 | watchdog( 'recurring', 'There was a problem updating the subscription for EOT for subscription id: %subscr_id', array( '%subscr_id' => print_r( $msg[ 'subscr_id' ], true )), WATCHDOG_NOTICE ); |
405 | 405 | return 0; |
— | — | @@ -627,15 +627,15 @@ |
628 | 628 | |
629 | 629 | if ( isset( $msg[ 'subscr_date' ] ) ) { |
630 | 630 | if ( $msg[ 'txn_type' ] == 'subscr_signup' ) { |
631 | | - $msg[ 'create_date' ] = strtotime( $msg[ 'subscr_date' ] ); |
632 | | - $msg[ 'start_date' ] = strtotime( $msg[ 'subscr_date' ] ); |
| 631 | + $msg_normalized[ 'create_date' ] = strtotime( $msg[ 'subscr_date' ] ); |
| 632 | + $msg_normalized[ 'start_date' ] = strtotime( $msg[ 'subscr_date' ] ); |
633 | 633 | } elseif( $msg[ 'txn_type' ] == 'subscr_cancel' ) { |
634 | | - $msg[ 'cancel_date' ] = strtotime( $msg[ 'subscr_date' ] ); |
| 634 | + $msg_normalized[ 'cancel_date' ] = strtotime( $msg[ 'subscr_date' ] ); |
635 | 635 | } |
636 | 636 | } |
637 | 637 | |
638 | 638 | if ( $msg[ 'txn_type' ] == 'subscr_modify' ) { |
639 | | - $msg[ 'modified_date' ] = $msg[ 'subscr_effective' ]; |
| 639 | + $msg_normalized[ 'modified_date' ] = $msg[ 'subscr_effective' ]; |
640 | 640 | } |
641 | 641 | |
642 | 642 | if ( $msg[ 'txn_type' ] == 'subscr_failed' ) { |