app/Http/Controllers/PerusahaanController.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)
    {
        Perusahaan::create([
            'user_id' => $request->user_id,
            'nama_perusahaan' => $request->nama_perusahaan,
            'alamat_perusahaan'=>$request->alamat_perusahaan,
            'notelp_perusahaan' => $request->notelp_perusahaan,
            'nama_penanggungjawab' => $request->nama_penanggungjawab,
            'notelp_penanggungjawab' => $request->notelp_penanggungjawab
                ]);
        return redirect()->route('perusahaan.index')
        ->with('message', 'Data berhasil diinput');
    }
public function store ( Request $ request ) { Perusahaan :: create ( [ 'user_id' => $ request -> user_id , 'nama_perusahaan' => $ request -> nama_perusahaan , 'alamat_perusahaan' => $ request -> alamat_perusahaan , 'notelp_perusahaan' => $ request -> notelp_perusahaan , 'nama_penanggungjawab' => $ request -> nama_penanggungjawab , 'notelp_penanggungjawab' => $ request -> notelp_penanggungjawab ] ) ; return redirect ( ) -> route ( 'perusahaan.index' ) -> with ( 'message' , 'Data berhasil diinput' ) ; }
Store a newly created resource in storage.
Store a newly created resource in storage .