mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/exchange-2.0.git
synced 2026-08-19 04:23:55 +00:00
show all service for currency suppliers
This commit is contained in:
@@ -4,7 +4,6 @@ namespace App\Models;
|
||||
use App\Classes\General\Interfaces\Documentable;
|
||||
use App\Classes\Modules\ServiceTypes\DataTransferObjects\ServiceConfigurationsObject;
|
||||
use App\Classes\ValueObjects\Constants\ApprovalStatus;
|
||||
use App\Classes\ValueObjects\Constants\BusinessType;
|
||||
use App\Classes\ValueObjects\Constants\SegmentConstants;
|
||||
use Illuminate\Database\Eloquent\Builder;
|
||||
use Illuminate\Database\Eloquent\Relations\BelongsToMany;
|
||||
@@ -136,7 +135,7 @@ class Company extends AbstractModel implements Documentable
|
||||
return $this->services()->get()->map(function($service) {
|
||||
return new ServiceConfigurationsObject($service,
|
||||
$service->constants->where('reference', SegmentConstants::SERVICE_TYPE)->first(),
|
||||
$this->type === BusinessType::CURRENCY_VENDOR ? $service->constants->where('reference', SegmentConstants::CUSTOM_SERVICE_TYPE) : $service->constants->where('reference', SegmentConstants::CUSTOM_SERVICE_TYPE)->whereIn('segment_id', $this->segments->pluck('id')));
|
||||
$service->constants->where('reference', SegmentConstants::CUSTOM_SERVICE_TYPE)->whereIn('segment_id', $this->segments->pluck('id')));
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user