Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <html>
- <head>
- <title><?php echo lang('sales_by_client'); ?></title>
- <link rel="stylesheet" href="<?php echo base_url(); ?>assets/default/css/reports.css" type="text/css">
- </head>
- <body>
- <h3 class="report_title"><?php echo lang('sales_by_client'); ?></h3>
- <table>
- <tr>
- <th><?php echo lang('client'); ?></th>
- <th class="amount"><?php echo lang('invoice_count'); ?></th>
- <th class="amount"><?php echo lang('sales'); ?></th>
- <th class="amount"><?php echo lang('sales_with_tax'); ?></th>
- </tr>
- <?php
- $report_inv_count= 0;
- $report_total= 0;
- $report_total_tax= 0;
- foreach ($results as $result) {
- ?>
- <tr>
- <td><?php echo $result->client_name; ?></td>
- <td class="amount"><?php echo $result->invoice_count; $report_inv_count+=$result->invoice_count; ?></td>
- <td class="amount"><?php echo format_currency($result->sales); $report_total+=$result->sales; ?></td>
- <td class="amount"><?php echo format_currency($result->sales_with_tax); $report_total_tax+=$result->sales_with_tax; ?></td>
- </tr>
- <?php } ?>
- <tr>
- <td><?php echo '<b>Total</b>'; ?></td>
- <td class="amount"><?php echo '<b>'.$report_inv_count.'</b>'; ?></td>
- <td class="amount"><?php echo '<b>'.format_currency($report_total).'</b>'; ?></td>
- <td class="amount"><?php echo '<b>'.format_currency($report_total_tax).'</b>'; ?></td>
- </tr>
- </table>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement