mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Document Export
This commit is contained in:
parent
d1ae7d88d9
commit
ace76b8587
@ -97,6 +97,7 @@ class DocumentExport
|
||||
foreach(array_values($this->report_keys) as $key){
|
||||
|
||||
$entity[$key] = $transformed_entity[$key];
|
||||
|
||||
}
|
||||
|
||||
return $this->decorateAdvancedFields($document, $entity);
|
||||
@ -106,8 +107,11 @@ class DocumentExport
|
||||
private function decorateAdvancedFields(Document $document, array $entity) :array
|
||||
{
|
||||
|
||||
// if(array_key_exists('country_id', $entity))
|
||||
// $entity['country_id'] = $credit->client->country ? ctrans("texts.country_{$credit->client->country->name}") : "";
|
||||
if(array_key_exists('record_type', $entity))
|
||||
$entity['record_type'] = class_basename($document->documentable);
|
||||
|
||||
if(array_key_exists('record_name', $entity))
|
||||
$entity['record_name'] = $document->hashed_id;
|
||||
|
||||
return $entity;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user