mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/shipping-portal.git
synced 2026-08-19 04:24:12 +00:00
Merge branch 'create-new-filter-to-order-by-arrival-dates'
# Conflicts: # routes/api.php
This commit is contained in:
@@ -28,16 +28,11 @@ class CompanyResource extends JsonResource
|
||||
'business_type' => (int) $this->business_type,
|
||||
'status' => (int) $this->status,
|
||||
'contact' => new ContactResource ($this->when($this->has('contacts'), $this->contacts->first())),
|
||||
'employee' => new UserResource($companyModule ? $companyModule->employees()->first() : null),
|
||||
'employee' => new UserResource($companyModule->employees()->first()),
|
||||
'company_module' => new CompanyModuleResource($companyModule),
|
||||
'last_order' => new OrderResource($companyModule ? $companyModule->orders()->orderBy('id', 'DESC')->first(): null),
|
||||
<<<<<<< HEAD
|
||||
// 'order_count' => $this->orders()->count(),
|
||||
'identification' => new DocumentResource($this->documents->whereIn('document_type', DocumentType::IDENTIFICATION_DOCUMENTS)->first()),
|
||||
=======
|
||||
'order_count' => $this->orders()->count(),
|
||||
'identification' => new DocumentResource($this->documents->whereIn('document_type', DocumentType::IDENTIFICATION_DOCUMENTS)->whereIn('status', [ApprovalStatus::PENDING_VERIFICATION, ApprovalStatus::APPROVED])->first()),
|
||||
>>>>>>> origin/master
|
||||
'created_at' => $this->created_at->format('d-m-Y')
|
||||
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user