charges calculation error and invoice code option