Permalink
Browse files

Merge pull request #34 from JacksonRiver/springboard_compliance

added Springboard Compliance module
  • Loading branch information...
2 parents 6a434c7 + 5396508 commit f2197e07f918628f8540c42be47f19336c17f46b @afreemannc afreemannc committed Apr 18, 2012
View
5 springboard_compliance/springboard_compliance.info
@@ -0,0 +1,5 @@
+core = "6.x"
+name = "Springboard Compliance"
+package = "Jackson River Springboard - extras"
+project = ""
+version = "6.x-dev"
View
8 springboard_compliance/springboard_compliance.install
@@ -0,0 +1,8 @@
+<?php
+
+/**
+ * @file installation file for Springboard Compliance module
+ */
+function springboard_compliance_install() {
+ variable_set('uc_credit_debug', FALSE);
+}
View
19 springboard_compliance/springboard_compliance.module
@@ -0,0 +1,19 @@
+<?php
+
+/**
+ * @file
+ * Springboard Compliance module
+ */
+
+/**
+ * Implements hook_form_alter().
+ *
+ * Disables UC credit card debug mode checkbox.
+ */
+function springboard_compliance_form_alter(&$form, $form_state, $form_id) {
+ if (!strcmp($form_id, 'uc_payment_methods_form')) {
+ $form['method_credit']['cc_security']['uc_credit_debug']['#disabled'] = TRUE;
+ $form['method_credit']['cc_security']['uc_credit_debug']['#default_value'] = 0;
+ $form['method_credit']['cc_security']['uc_credit_debug']['#description'] .= '<br /><strong>' . t('This option has been disabled to ensure PCI compliance') . '</strong>';
+ }
+}

0 comments on commit f2197e0

Please sign in to comment.