--- ups.inc.bak	2006-11-28 10:08:23.000000000 -0800
+++ ups.inc	2006-11-28 11:05:01.000000000 -0800
@@ -127,13 +127,39 @@ function ups_settings_form(&$form) {
     '#default_value' => (variable_get('shipcalc_ups_test_url', '') ? variable_get('shipcalc_ups_test_url', '') : 'https://wwwcie.ups.com/ups.app/xml/Rate'),
     '#required' => TRUE
   );
+  $form['ups']['ups_pickuptype'] = array(
+    '#type' => 'select',
+    '#title' => t('UPS Pickup Type'),
+    '#description' => t('Select your desired pickup type.'),
+    '#default_value' => variable_get('shipcalc_ups_pickuptype', '01'),
+    '#options' => array(
+      '01' => t('Daily Pickup'),
+      '03' => t('Customer Counter'),
+      '06' => t('One Time Pickup'),
+      '07' => t('On Call Air'),
+      '11' => t('Suggested Retail Rates'),
+      '19' => t('Letter Center'),
+      '20' => t('Air Service Center'),
+    ),
+  );
+  $form['ups']['ups_classification'] = array(
+    '#type' => 'select',
+    '#title' => t('UPS Customer Classification'),
+    '#description' => t('Select your classification'),
+    '#default_value' => variable_get('shipcalc_ups_classification', 'default'),
+    '#options' => array(
+      'default' => t('Default for your pickup type'),
+      '01' => t('Wholesale - UPS account, daily pickup'),
+      '03' => t('Occasional - UPS account, no daily pickup'),
+      '04' => t('Retail - No UPS account'),
+    ),
+  );
 
   $form['ups']['test']['submit'] = array(
     '#type' => 'submit',
     '#value' => t('Test ups configuration')
   );
 }
-
 /**
  * Shipcalc _settings_form_submit hook.
  *
@@ -149,6 +175,8 @@ function ups_settings_form_submit(&$form
     variable_set('shipcalc_ups_password', $form_values['ups_password']);
     variable_set('shipcalc_ups_url', $form_values['ups_url']);
     variable_set('shipcalc_ups_test_url', $form_values['ups_test_url']);
+    variable_set('shipcalc_ups_pickuptype', $form_values['ups_pickuptype']);
+    variable_set('shipcalc_ups_classification', $form_values['ups_classification']);
   }
 
   if ($op == t('Test ups configuration')) {
@@ -327,20 +355,13 @@ function ups_RatingServiceSelectionReque
   $xml .= "    <RequestOption>shop</RequestOption>\n";
   $xml .= "  </Request>\n";
   $xml .= "  <PickupType>\n";
-  // TODO: Make Pickup Type Code configurable.
-/*
-  Default value is 01. Valid values are:
-    01 - Daily Pickup
-    03 - Customer Counter
-    06 - One Time Pickup
-    07 - On Call Air
-    11 - Suggested Retail Rates
-    19 - Letter Center
-    20 - Air Service Center
-*/
-  $xml .= "    <Code>01</Code>\n";
+  $xml .= "    <Code>". variable_get('shipcalc_ups_pickuptype', '01') ."</Code>\n";
   $xml .= "  </PickupType>\n";
-  // TODO: Optionally support CustomerClassification/Code (for now use defaults)
+  if(variable_get('shipcalc_ups_classification', 'default') != 'default') {
+    $xml .= "  <CustomerClassification>\n";
+    $xml .= "    <Code>". variable_get('shipcalc_ups_classification', 'default') ."</Code>\n";
+    $xml .= "  </CustomerClassification>\n";
+  }
   $xml .= "  <Shipment>\n";
   $xml .= "    <Shipper>\n";
   $xml .= "      <Address>\n";
