<?php

namespace App\Http\Controllers;

use App\Models\FacebookAdsLeads;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\DB;

class FacebookAdsLeadsController extends Controller
{
    /**
     * Display a listing of the resource.
     *
     * @return \Illuminate\Http\Response
     */
    public function index()
    {
        $data["GoogleAdsLeads"] = DB::table('digitaladsleads')
        ->select("*")
        ->where('ChannelSource', 'FacebookAds')
        ->get();

        $data4 = $data["GoogleAdsLeads"];
        $array = json_decode(json_encode($data4), true);
        return view("layouts.FacebookAdsLeads",["facebookAds"=>$array]);
    }

    /**
     * Show the form for creating a new resource.
     *
     * @return \Illuminate\Http\Response
     */
    public function create()
    {
        //
    }

    /**
     * Store a newly created resource in storage.
     *
     * @param  \Illuminate\Http\Request  $request
     * @return \Illuminate\Http\Response
     */
    public function store(Request $request)
    {
        //
    }

    /**
     * Display the specified resource.
     *
     * @param  \App\Models\FacebookAdsLeads  $facebookAdsLeads
     * @return \Illuminate\Http\Response
     */
    public function show(FacebookAdsLeads $facebookAdsLeads)
    {
        //
    }

    /**
     * Show the form for editing the specified resource.
     *
     * @param  \App\Models\FacebookAdsLeads  $facebookAdsLeads
     * @return \Illuminate\Http\Response
     */
    public function edit(FacebookAdsLeads $facebookAdsLeads)
    {
        //
    }

    /**
     * Update the specified resource in storage.
     *
     * @param  \Illuminate\Http\Request  $request
     * @param  \App\Models\FacebookAdsLeads  $facebookAdsLeads
     * @return \Illuminate\Http\Response
     */
    public function update(Request $request, FacebookAdsLeads $facebookAdsLeads)
    {
        //
    }

    /**
     * Remove the specified resource from storage.
     *
     * @param  \App\Models\FacebookAdsLeads  $facebookAdsLeads
     * @return \Illuminate\Http\Response
     */
    public function destroy(FacebookAdsLeads $facebookAdsLeads)
    {
        //
    }
}
