<?php

namespace App\Http\Controllers\Api\V1\Admin;

use App\Bimbingan;
use App\Http\Controllers\Controller;
use App\Http\Requests\StoreBimbinganRequest;
use App\Http\Requests\UpdateBimbinganRequest;

class BimbinganApiController extends Controller
{
    public function index()
    {
        $bimbingans = Bimbingan::all();

        return $bimbingans;
    }

    public function store(StoreBimbinganRequest $request)
    {
        return Bimbingan::create($request->all());
    }

    public function update(UpdateBimbinganRequest $request, Bimbingan $bimbingan)
    {
        return $bimbingan->update($request->all());
    }

    public function show(Bimbingan $bimbingan)
    {
        return $bimbingan;
    }

    public function destroy(Bimbingan $bimbingan)
    {
        return $bimbingan->delete();
    }
}
