Adamw has uploaded a new change for review.
https://gerrit.wikimedia.org/r/80302
Change subject: remove all the 2nd personality fields.
......................................................................
remove all the 2nd personality fields.
Leave supplemental_address_2, but now it is meant to hold extra extra address
lines.
Change-Id: Ie2c01b291f0733a2c8f02716f5d6b06ec9e1b92d
---
M sites/all/modules/globalcollect_audit/globalcollect_audit.module
M sites/all/modules/paypal_audit/paypal_audit.module
M sites/all/modules/queue2civicrm/queue2civicrm_stomp.inc
M sites/all/modules/queue2civicrm/recurring/recurring.module
M sites/all/modules/queue2civicrm/tests/data/base_transaction.inc
5 files changed, 3 insertions(+), 40 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm
refs/changes/02/80302/1
diff --git a/sites/all/modules/globalcollect_audit/globalcollect_audit.module
b/sites/all/modules/globalcollect_audit/globalcollect_audit.module
index 68bcd54..bdcf33c 100644
--- a/sites/all/modules/globalcollect_audit/globalcollect_audit.module
+++ b/sites/all/modules/globalcollect_audit/globalcollect_audit.module
@@ -676,13 +676,6 @@
'state' => array( 'donor_data', 'STATE' ),
'country' => array( 'donor_data', 'COUNTRYCODE' ),
'zip' => array( 'donor_data', 'ZIP' ),
- 'fname2' => array( 'donor_data', 'FIRSTNAME' ),
- 'lname2' => array( 'donor_data', 'SURNAME' ),
- 'street2' => array( 'donor_data', 'STREET' ),
- 'city2' => array( 'donor_data', 'CITY' ),
- 'state2' => array( 'donor_data', 'STATE' ),
- 'country2' => array( 'donor_data', 'COUNTRYCODE' ),
- 'zip2' => array( 'donor_data', 'ZIP' ),
'gateway_txn_id' => array( 'donor_data', 'ORDERID' ),
'response', //? Maybe some dummy value for "found it in the
audit phase"
'currency_code' => array( 'donor_data', 'CURRENCYCODE' ),
diff --git a/sites/all/modules/paypal_audit/paypal_audit.module
b/sites/all/modules/paypal_audit/paypal_audit.module
index 1a397b7..13208d2 100644
--- a/sites/all/modules/paypal_audit/paypal_audit.module
+++ b/sites/all/modules/paypal_audit/paypal_audit.module
@@ -205,7 +205,7 @@
$trxns_formatted = array();
/**
- *
{"contribution_tracking_id":"4983928","optout":"0","anonymous":"1","comment":null,"email":"[email protected]","size":null,"premium_language":null,"first_name":"Xavier","last_name":"Marquez
Barreto","street_address":"Pto Azul Mz A-5 Villa
3","supplemental_address_1":null,"city":"Guayaquil","state_province":"Guayas","country":"EC","postal_code":"752","last_name_2":"Barreto","first_name_2":"Xavier
Marquez","street_address_2":"Pto Azul Mz A-5 Villa
3","supplemental_address_2":null,"city_2":"Guayaquil","state_province_2":"Guayas","country_2":"EC","postal_code_2":"752","gateway":"paypal","gateway_txn_id":"6N71347241984711L","original_currency":"USD","original_gross":"3.00","fee":"0.39","gross":"3.00","net":2.61,"date":1303195718}
+ *
{"contribution_tracking_id":"4983928","optout":"0","anonymous":"1","comment":null,"email":"[email protected]","size":null,"premium_language":null,"first_name":"Xavier","last_name":"Marquez
Barreto","street_address":"Pto Azul Mz A-5 Villa
3","supplemental_address_1":null,"city":"Guayaquil","state_province":"Guayas","country":"EC","postal_code":"752","gateway":"paypal","gateway_txn_id":"6N71347241984711L","original_currency":"USD","original_gross":"3.00","fee":"0.39","gross":"3.00","net":2.61,"date":1303195718}
*/
$fields = array( 'Billing Country', 'Shipping Country', 'Transaction ID',
'PayPal Transaction ID', 'Currency Symbol', 'Amount', 'Time');
$columns = $report_obj->getReportResponse()->findColumnNumber( $fields );
diff --git a/sites/all/modules/queue2civicrm/queue2civicrm_stomp.inc
b/sites/all/modules/queue2civicrm/queue2civicrm_stomp.inc
index e48dce2..f9ed946 100644
--- a/sites/all/modules/queue2civicrm/queue2civicrm_stomp.inc
+++ b/sites/all/modules/queue2civicrm/queue2civicrm_stomp.inc
@@ -109,6 +109,7 @@
'last_name' => "",
'street_address' => "",
'supplemental_address_1' => '',
+ 'supplemental_address_2' => '',
'city' => "",
'state_province' => "",
'country' => "",
@@ -127,16 +128,6 @@
// override all defaults with actual values, if they exist
$msg = array_merge( $message_defaults, $msg );
-
- // why we do this, no one knows
- $msg['first_name_2'] = $msg['first_name'];
- $msg['last_name_2'] = $msg['last_name'];
- $msg['street_address_2'] = $msg['street_address'];
- $msg['supplemental_address_2'] = $msg['supplemental_address_1'];
- $msg['city_2'] = $msg['city'];
- $msg['state_province_2'] = $msg['state_province'];
- $msg['country_2'] = $msg['country'];
- $msg['postal_code_2'] = $msg['postal_code'];
//if these two are the unfilled default value, assign them the value of
the required 'gross' field.
if ( $msg['original_gross'] === $message_defaults['original_gross'] ){
diff --git a/sites/all/modules/queue2civicrm/recurring/recurring.module
b/sites/all/modules/queue2civicrm/recurring/recurring.module
index 3c3f337..779385e 100644
--- a/sites/all/modules/queue2civicrm/recurring/recurring.module
+++ b/sites/all/modules/queue2civicrm/recurring/recurring.module
@@ -647,20 +647,6 @@
$msg_normalized[ 'state_province' ] = $msg[ 'address_state' ];
$msg_normalized[ 'country' ] = $msg[ 'address_country_code' ];
$msg_normalized[ 'postal_code' ] = $msg[ 'address_zip' ];
-
- // Shipping info (address same as above since PayPal only passes 1
address)
- $split = split(" ", $msg[ 'address_name' ]);
- $msg_normalized[ 'last_name_2' ] = array_pop($split);
- $msg_normalized[ 'first_name_2' ] = implode(" ", $split);
- $split = split("\n", str_replace("\r", '', $msg[ 'address_street' ]));
- $msg_normalized[ 'street_address_2' ] = $split[0];
- if ( count( $split ) > 1 ) {
- $msg_normalized[ 'supplemental_address_2' ] = $split[1];
- }
- $msg_normalized[ 'city_2' ] = $msg[ 'address_city' ];
- $msg_normalized[ 'state_province_2' ] = $msg[ 'address_state' ];
- $msg_normalized[ 'country_2' ] = $msg[ 'address_country_code' ];
- $msg_normalized[ 'postal_code_2' ] = $msg[ 'address_zip' ];
}
// payment-specific message handling
diff --git a/sites/all/modules/queue2civicrm/tests/data/base_transaction.inc
b/sites/all/modules/queue2civicrm/tests/data/base_transaction.inc
index 0672fe3..c8d5c04 100644
--- a/sites/all/modules/queue2civicrm/tests/data/base_transaction.inc
+++ b/sites/all/modules/queue2civicrm/tests/data/base_transaction.inc
@@ -18,18 +18,11 @@
"last_name" => "laast",
"street_address" => "ss",
"supplemental_address_1" => "",
+ "supplemental_address_2" => "",
"city" => "cc",
"state_province" => "Haifa",
"country" => "IL",
"postal_code" => "11122",
- "first_name_2" => "b",
- "last_name_2" => "w",
- "street_address_2" => "st 2nd.",
- "supplemental_address_2" => "",
- "city_2" => "cc",
- "state_province_2" => "AL",
- "country_2" => "DE",
- "postal_code_2" => "11122",
"gateway" => "globalcollect",
//"gateway_txn_id" => "3611204184",
"payment_method" => "cc",
--
To view, visit https://gerrit.wikimedia.org/r/80302
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie2c01b291f0733a2c8f02716f5d6b06ec9e1b92d
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: master
Gerrit-Owner: Adamw <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits