<?php

namespace App\Http\Controllers\Admin\Shop;

use App\Http\Controllers\Controller;
use App\Repositories\Shop\Taxes;
use Illuminate\Http\Request;

class TaxController extends Controller
{
    public function index(TaxesDataTable $dataTable)
    {
        return $dataTable->render('Admin.Shop.Taxes.list');
    }

    public function create()
    {
        return view('Admin.Shop.Taxes.create');
    }

    public function store(Request $request)
    {
        $ret = Taxes::store($request->all());

        return redirect()->route('Admin.Shop.Taxes.index');
    }

    public function show($id)
    {
        $data = Taxes::get($id);

        return view('Admin.Shop.Taxes.view', $data);
    }

    public function edit($id)
    {
        $data = Taxes::get($id);

        return view('Admin.Shop.Taxes.edit', $data);
    }

    public function destroy($id)
    {
        return Taxes::destroy($id);
    }
}
