Update
This commit is contained in:
@@ -48,6 +48,8 @@ class OrganizationController extends Controller
|
||||
public function store(Request $request)
|
||||
{
|
||||
$organization = [
|
||||
'phone' => $request->no_hp,
|
||||
'email' => $request->email,
|
||||
'code' => $request->code,
|
||||
'name' => $request->name,
|
||||
'type' => 'hospital',
|
||||
@@ -119,6 +121,8 @@ class OrganizationController extends Controller
|
||||
$update_organization = Organization::find($id);
|
||||
|
||||
$update_organization->update([
|
||||
'phone' => $request->no_hp,
|
||||
'email' => $request->email,
|
||||
'code' => $request->code,
|
||||
'name' => $request->name,
|
||||
'type' => 'hospital',
|
||||
@@ -152,7 +156,7 @@ class OrganizationController extends Controller
|
||||
'lat' => $request->lat,
|
||||
'lng' => $request->lng,
|
||||
]);
|
||||
|
||||
|
||||
$update_organization->main_address_id = $newAddres->id;
|
||||
$update_organization->save();
|
||||
|
||||
|
||||
@@ -27,12 +27,14 @@ class OrganizationResource extends JsonResource
|
||||
}
|
||||
$corporatePartner = implode(', ', $corporateName);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
$organization = [
|
||||
'id' => $this->id,
|
||||
'name' => $this->name,
|
||||
'type' => $this->type,
|
||||
'no_hp' => $this->phone,
|
||||
'email' => $this->email,
|
||||
'code' => $this->code,
|
||||
'description' => $this->description,
|
||||
'kodeRs' => $this->meta->KodeRS ?? null,
|
||||
|
||||
Reference in New Issue
Block a user