diff --git a/application/helpers/table_helper.php b/application/helpers/table_helper.php index 663683ad2..8c636aed2 100644 --- a/application/helpers/table_helper.php +++ b/application/helpers/table_helper.php @@ -6,17 +6,26 @@ function get_sales_manage_table($sales, $controller) $table='
| '.to_currency( $sale['amount_tendered'] ).' | '; $table_data_row.=''.to_currency( $sale['amount_due'] ).' | '; $table_data_row.=''.to_currency( $sale['change_due'] ).' | '; - $table_data_row.=''.$sale['payment_type'].' | '; - $table_data_row.=''.$sale['invoice_number'].' | '; + if($CI->config->item('invoice_enable') == TRUE) + { + $table_data_row.=''.$sale['payment_type'].' | '; + $table_data_row.=''.$sale['invoice_number'].' | '; + } + else + { + // this size includes the 8% of invoice number and 5% of the invoice gliphicon, pluf of course the 12% for the field itself + $table_data_row.=''.$sale['payment_type'].' | '; + } $table_data_row.=''.anchor($controller_name."/edit/" . $sale['sale_id'], '', array('class'=>'modal-dlg modal-btn-delete modal-btn-submit print_hide', 'title'=>$CI->lang->line($controller_name.'_update'))).' | '; $table_data_row.=''.anchor($controller_name."/receipt/" . $sale['sale_id'], '', array('class'=>'print_hide', 'title'=>$CI->lang->line('sales_show_receipt'))).' | '; - $table_data_row.=''.anchor($controller_name."/invoice/" . $sale['sale_id'], '', array('class'=>'print_hide', 'title'=>$CI->lang->line('sales_show_invoice'))).' | '; + if($CI->config->item('invoice_enable') == TRUE) + { + $table_data_row.=''.anchor($controller_name."/invoice/" . $sale['sale_id'], '', array('class'=>'print_hide', 'title'=>$CI->lang->line('sales_show_invoice'))).' | '; + } $table_data_row.='