app/Http/Controllers/FirmController.php
/**
     * Remove the specified resource from storage.
     *
     * @param  \App\Models\Firm  $firm
     * @return \Illuminate\Http\Response
     */
Remove the specified resource from storage.
Remove the specified resource from storage .
public function destroy($firm)
    {
        $check = Firm::where('id', $firm)->delete();
        if($check){
            $data['success'] = true;
            $data['message'] = "Firm deleted successfully";
            return response()->json($data, 200);
        }
        $data['success'] = false;
        $data['message'] = "Something went wrong";
        return response()->json($data, 200);
    }
public function destroy ( $ firm ) { $ check = Firm :: where ( 'id' , $ firm ) -> delete ( ) ; if ( $ check ) { $ data [ 'success' ] = true ; $ data [ 'message' ] = " Firm deleted successfully " ; return response ( ) -> json ( $ data , 200 ) ; } $ data [ 'success' ] = false ; $ data [ 'message' ] = " Something went wrong " ; return response ( ) -> json ( $ data , 200 ) ; }
Remove the specified resource from storage.
Remove the specified resource from storage .