<?php

namespace App\Http\Controllers;

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

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

        $data4 = $data["GoogleAdsLeads"];
        $array = json_decode(json_encode($data4), true);
        return view("layouts.YoutubeAdsLeads",["youtubeAds"=>$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\YoutubeAdsLeads  $youtubeAdsLeads
     * @return \Illuminate\Http\Response
     */
    public function show(YoutubeAdsLeads $youtubeAdsLeads)
    {
        //
    }

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

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

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