php - Modify array json api response laravel
one text
Solution:
You have to use basic Laravel Transform for this.
$services->transform(function($q){
$q->image = 'https://google.com/avatars/' . $q->image;
return $q;
});
Sourceone text
You have to use basic Laravel Transform for this.
$services->transform(function($q){
$q->image = 'https://google.com/avatars/' . $q->image;
return $q;
});
Source