@joe: The following info will be useful in getting Sales Groups into all pertinent reports:
functions in includes/ui/ui_lists.inc:
sales_groups_list($name, $selected_id=null, $special_option=false)
used in function sales_groups_list_cells
sales_groups_list_cells($label, $name, $selected_id=null, $special_option=false)
used in sales_groups_list_row
sales_groups_list_row($label, $name, $selected_id=null, $special_option=false)
used in sales/manage/customer_branches.php (data entry and updation)
used in sales/manage/recurrent_invoices.php (selection for recurrent invoice generation)
functions in sales/includes/db/sales_groups_db.inc:
The following 5 functions are used only once in sales/manage/sales_groups.php
add_sales_group($description)
update_sales_group($selected_id, $description)
delete_sales_group($selected_id)
get_sales_groups($show_inactive)
get_sales_group($selected_id)
get_sales_group_name($group_no)
used in sales/manage/recurrent_invoices.php
used in sales/create_recurrent_invoices.php