heizervr6 Posted November 27, 2007 Posted November 27, 2007 We are in the process of installing the Beanstream Module into a heavily modified version of XT-Commerce on a multi-shop platform and have a problem that arises when setting up the configuration script in MySQL. XTC needs additional information that is not provided in the Beanstream module and I need help determining what script needs to be inserted. The following is where we are running into the problem: tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Enable Beanstream Module', 'MODULE_PAYMENT_BEANSTREAM_USD_STATUS', 'True', 'Do you want to accept Beanstream payments?', '6', '0', 'tep_cfg_select_option(array(\'True\', \'False\'), ', now())"); tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Login/Store Number', 'MODULE_PAYMENT_BEANSTREAM_USD_LOGIN', '99999', 'Login/Store Number used for the Beanstream service', '6', '0', now())"); tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Transaction Mode', 'MODULE_PAYMENT_BEANSTREAM_USD_TESTMODE', 'Test', 'Transaction mode used for the Beanstream service', '6', '0', 'tep_cfg_select_option(array(\'Test\', \'Production\'), ', now())"); tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Merchant Notifications', 'MODULE_PAYMENT_BEANSTREAM_USD_EMAIL_MERCHANT', 'True', 'Should Beanstream e-mail a receipt to the store owner?', '6', '0', 'tep_cfg_select_option(array(\'True\', \'False\'), ', now())"); tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Sort order of display.', 'MODULE_PAYMENT_BEANSTREAM_USD_SORT_ORDER', '0', 'Sort order of display. Lowest is displayed first.', '6', '0', now())"); tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added) values ('Payment Zone', 'MODULE_PAYMENT_BEANSTREAM_USD_ZONE', '0', 'If a zone is selected, only enable this payment method for that zone.', '6', '2', 'tep_get_zone_class_title', 'tep_cfg_pull_down_zone_classes(', now())"); tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, use_function, date_added) values ('Set Order Status', 'MODULE_PAYMENT_BEANSTREAM_USD_ORDER_STATUS_ID', '0', 'Set the status of orders made with this payment module to this value', '6', '0', 'tep_cfg_pull_down_order_statuses(', 'tep_get_order_status_name', now())"); The following is how we have changed it for our purpose and is what we have so far - you will note that "tep" has been changed to "xtc" for our purposes: xtc_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_id, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Enable Beanstream Module', 'MODULE_PAYMENT_BEANSTREAM_USD_STATUS', 'True', 'Do you want to accept Beanstream payments?', '6', '0', 'xtc_cfg_select_option(array(\'True\', \'False\'), ', now())"); //Ergänzt MODULE_PAYMENT_BEANSTREAM_USD_ALLOWED xtc_db_query("insert into ".TABLE_CONFIGURATION." ( configuration_key, configuration_value, configuration_group_id, sort_order, date_added) values ('MODULE_PAYMENT_BEANSTREAM_USD_ALLOWED', '', '6', '0', now())"); xtc_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_id, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Login/Store Number', 'MODULE_PAYMENT_BEANSTREAM_USD_LOGIN', '99999', 'Login/Store Number used for the Beanstream service', '6', '0', now())"); xtc_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_id, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Transaction Mode', 'MODULE_PAYMENT_BEANSTREAM_USD_TESTMODE', 'Test', 'Transaction mode used for the Beanstream service', '6', '0', 'xtc_cfg_select_option(array(\'Test\', \'Production\'), ', now())"); xtc_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_id, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Merchant Notifications', 'MODULE_PAYMENT_BEANSTREAM_USD_EMAIL_MERCHANT', 'True', 'Should Beanstream e-mail a receipt to the store owner?', '6', '0', 'xtc_cfg_select_option(array(\'True\', \'False\'), ', now())"); xtc_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_id, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Sort order of display.', 'MODULE_PAYMENT_BEANSTREAM_USD_SORT_ORDER', '0', 'Sort order of display. Lowest is displayed first.', '6', '0', now())"); xtc_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_id, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added) values ('Payment Zone', 'MODULE_PAYMENT_BEANSTREAM_USD_ZONE', '0', 'If a zone is selected, only enable this payment method for that zone.', '6', '2', 'xtc_get_zone_class_title', 'xtc_cfg_pull_down_zone_classes(', now())"); xtc_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_id, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, use_function, date_added) values ('Set Order Status', 'MODULE_PAYMENT_BEANSTREAM_USD_ORDER_STATUS_ID', '0', 'Set the status of orders made with this payment module to this value', '6', '0', 'xtc_cfg_pull_down_order_statuses(', 'xtc_get_order_status_name', now())"); Our problem is that something in the above script is missing so as to allow this to work in XT-Commerce. Would anyone have any ideas that they care to share? Additionally, this is the original Beanstream script that was provided: define('MODULE_PAYMENT_BEANSTREAM_USD_TEXT_TITLE', 'Beanstream secure online payment service, payment in USD'); define('MODULE_PAYMENT_BEANSTREAM_USD_TEXT_DESCRIPTION', 'Credit Card Test Info:<br><br>CC#: 5100000010001004<br>Expiry: 12/4'); define('MODULE_PAYMENT_BEANSTREAM_USD_TEXT_CREDIT_CARD_OWNER', 'Credit Card Owner:'); define('MODULE_PAYMENT_BEANSTREAM_USD_TEXT_CREDIT_CARD_NUMBER', 'Credit Card Number:'); define('MODULE_PAYMENT_BEANSTREAM_USD_TEXT_CREDIT_CARD_EXPIRES', 'Credit Card Expiry Date:'); define('MODULE_PAYMENT_BEANSTREAM_USD_TEXT_TYPE', 'Type:'); define('MODULE_PAYMENT_BEANSTREAM_USD_TEXT_JS_CC_OWNER', '* The credit card owner must be at least ' . CC_OWNER_MIN_LENGTH . ' characters.\n'); define('MODULE_PAYMENT_BEANSTREAM_USD_TEXT_JS_CC_NUMBER', '* The credit card number must be at least ' . CC_NUMBER_MIN_LENGTH . ' characters.\n'); define('MODULE_PAYMENT_BEANSTREAM_USD_TEXT_ERROR_MESSAGE', 'There has been an error processing you credit card, please contact us.'); define('MODULE_PAYMENT_BEANSTREAM_USD_TEXT_ERROR', 'Error!'); And this is how we've added/modified it: define('MODULE_PAYMENT_BEANSTREAM_USD_STATUS_TITLE', 'Beanstream USD Payment Modul'); define('MODULE_PAYMENT_BEANSTREAM_USD_STATUS_DESC', 'Do you want to accept beanstream credit card module order payments?'); define('MODULE_PAYMENT_BEANSTREAM_USD_LOGIN_TITLE', 'USD_LOGIN_TITLE'); define('MODULE_PAYMENT_BEANSTREAM_USD_LOGIN_DESC', 'USD_LOGIN_DESC'); define('MODULE_PAYMENT_BEANSTREAM_USD_TESTMODE_TITLE', 'USD_TESTMODE_TITLE'); define('MODULE_PAYMENT_BEANSTREAM_USD_TESTMODE_DESC', 'USD_TESTMODE_DESC'); define('MODULE_PAYMENT_BEANSTREAM_USD_EMAIL_MERCHANT_TITLE', 'USD_EMAIL_MERCHANT_TITLE'); define('MODULE_PAYMENT_BEANSTREAM_USD_EMAIL_MERCHANT_DESC', 'USD_EMAIL_MERCHANT_DESC'); define('MODULE_PAYMENT_BEANSTREAM_USD_ZONE_TITLE', 'Zahlungszone'); define('MODULE_PAYMENT_BEANSTREAM_USD_ZONE_DESC', 'Wenn eine Zone ausgewählt ist, gilt die Zahlungsmethode nur für diese Zone.'); define('MODULE_PAYMENT_BEANSTREAM_USD_ORDER_STATUS_ID_TITLE', 'Bestellstatus festlegen'); define('MODULE_PAYMENT_BEANSTREAM_USD_ORDER_STATUS_ID_DESC', 'Bestellungen, welche mit diesem Modul gemacht werden, auf diesen Status setzen'); define('MODULE_PAYMENT_BEANSTREAM_USD_SORT_ORDER_TITLE', 'Module Sort order of display.'); define('MODULE_PAYMENT_BEANSTREAM_USD_SORT_ORDER_DESC', 'Sort order of display. Lowest is displayed first.'); define('MODULE_PAYMENT_BEANSTREAM_USD_ALLOWED', 'USD_ALLOWED'); define('MODULE_PAYMENT_BEANSTREAM_USD_ALLOWED_TITLE', 'USD_ALLOWED'); define('MODULE_PAYMENT_BEANSTREAM_USD_ALLOWED_DESC', 'USD_ALLOWED'); Any help would be greatly appreciated. Please keep in mind that a lot of this is over my head and calling my self a newbie is an understatement. Thanks! Christian
Recommended Posts
Archived
This topic is now archived and is closed to further replies.