mirror of
				https://github.com/invoiceninja/invoiceninja.git
				synced 2025-11-03 22:57:32 -05:00 
			
		
		
		
	Add invoice item description in product report
This commit is contained in:
		
							parent
							
								
									fb92a3cfbc
								
							
						
					
					
						commit
						ff5911ff60
					
				@ -2,6 +2,7 @@
 | 
			
		||||
 | 
			
		||||
namespace App\Ninja\Presenters;
 | 
			
		||||
 | 
			
		||||
use Str;
 | 
			
		||||
use stdClass;
 | 
			
		||||
 | 
			
		||||
class InvoiceItemPresenter extends EntityPresenter
 | 
			
		||||
@ -16,4 +17,9 @@ class InvoiceItemPresenter extends EntityPresenter
 | 
			
		||||
 | 
			
		||||
        return $data;
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public function notes()
 | 
			
		||||
    {
 | 
			
		||||
        return Str::limit($this->entity->notes);
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
@ -13,6 +13,7 @@ class ProductReport extends AbstractReport
 | 
			
		||||
        'invoice_number',
 | 
			
		||||
        'invoice_date',
 | 
			
		||||
        'product',
 | 
			
		||||
        'description',
 | 
			
		||||
        'qty',
 | 
			
		||||
        'cost',
 | 
			
		||||
        //'tax_rate1',
 | 
			
		||||
@ -45,6 +46,7 @@ class ProductReport extends AbstractReport
 | 
			
		||||
                        $this->isExport ? $invoice->invoice_number : $invoice->present()->link,
 | 
			
		||||
                        $invoice->present()->invoice_date,
 | 
			
		||||
                        $item->product_key,
 | 
			
		||||
                        $this->isExport ? $item->notes : $item->present()->notes,
 | 
			
		||||
                        Utils::roundSignificant($item->qty, 0),
 | 
			
		||||
                        Utils::roundSignificant($item->cost, 2),
 | 
			
		||||
                    ];
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user