app/Http/Controllers/M_template_detailsController.php
/**
     * Store a newly created resource in storage.
     *
     * @param  \Illuminate\Http\Request  $request
     * @return \Illuminate\Http\Response
     */
Store a newly created resource in storage.
Store a newly created resource in storage .
public function store(Request $request)
    {
        request()->validate([
            'template_id' => 'required',
            'description' => 'required',
        ]);
        M_template_details::create($request->all());
        return redirect()->route('m_template_details.index')
                        ->with('success','description created successfully.');
    }
public function store ( Request $ request ) { request ( ) -> validate ( [ 'template_id' => 'required' , 'description' => 'required' , ] ) ; M_template_details :: create ( $ request -> all ( ) ) ; return redirect ( ) -> route ( 'm_template_details.index' ) -> with ( 'success' , 'description created successfully.' ) ; }
Store a newly created resource in storage.
Store a newly created resource in storage .