mirror of
https://github.com/crater-invoice/crater.git
synced 2025-10-27 11:41:09 -04:00
fix custom field invoice issue
This commit is contained in:
@ -46,6 +46,7 @@ class InvoiceResource extends JsonResource
|
||||
'base_due_amount' => $this->base_due_amount,
|
||||
'currency_id' => $this->currency_id,
|
||||
'formatted_created_at' => $this->formattedCreatedAt,
|
||||
'formatted_notes' => $this->formattedNotes,
|
||||
'invoice_pdf_url' => $this->invoicePdfUrl,
|
||||
'formatted_invoice_date' => $this->formattedInvoiceDate,
|
||||
'formatted_due_date' => $this->formattedDueDate,
|
||||
|
||||
@ -166,6 +166,11 @@ class Invoice extends Model implements HasMedia
|
||||
}
|
||||
}
|
||||
|
||||
public function getFormattedNotesAttribute($value)
|
||||
{
|
||||
return $this->getNotes();
|
||||
}
|
||||
|
||||
public function getFormattedCreatedAtAttribute($value)
|
||||
{
|
||||
$dateFormat = CompanySetting::getSetting('carbon_date_format', $this->company_id);
|
||||
|
||||
Reference in New Issue
Block a user