<?php

namespace App\Http\Controllers;

use App\Models\module;
use Illuminate\Http\Request;

class ModuleController extends Controller
{
    // use ModuleTraits;
    public function index(module $module, Request $request)
    {
        return $this->getLatestData($module, $request);
    }

    /**
     * Store a newly created resource in storage.
     */
    public function store(Request $request)
    {
        return $this->storeModule($request);
    }

    /**
     * Display the specified resource.
     */
    public function show($module)
    {
        return $this->showModule($module);
    }

    /**
     * Update the specified resource in storage.
     */
    public function update(Request $request)
    {
        return $this->updateModule($request);
    }


    /**
     * Remove the specified resource from storage.
     */
    public function destroy($module)
    {
        return $this->destroyModule($module);
    }
}
