Skip to content

Instantly share code, notes, and snippets.

@PureSingh
Created March 25, 2016 18:40
Show Gist options
  • Save PureSingh/b0581dfdf3d4e2aa99fd to your computer and use it in GitHub Desktop.
Save PureSingh/b0581dfdf3d4e2aa99fd to your computer and use it in GitHub Desktop.
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use App\Http\Requests;
use App\Http\Controllers\Controller;
use Cache;
// use Zendesk\API\HttpClient as Zendesk;
use Flash;
use Facades;
//use Huddle\Zendesk\Services\ZendeskService;
use Huddle\Zendesk\Facades\Zendesk as Zendesk;
use Teamwork;
class HomeController extends Controller
{
public function __construct() {
//$this->zendesk_service = $zendesk_service;
}
public function index() {
$page_title = "Home";
$page_description = "This is the home page";
// $x = Teamwork::people()->all();
$ztickets = Zendesk::tickets()->findAll();
//$this->zendesk_service->tickets()->findAll();
$tickets = $ztickets->tickets;
$ticket = '';
return view('home', compact('page_title', 'page_description', 'tickets'));
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment