update v1.0.5.2

This commit is contained in:
sujitprasad
2016-01-29 12:49:45 +05:30
parent b1d1ebbbef
commit 0bcbc04f92
28 changed files with 1981 additions and 89 deletions

View File

@@ -15,7 +15,7 @@ class="active"
@section('content')
<?php
if(Auth::user()->role == 'agent') {
$dept = App\Model\helpdesk\Agent\Department::where('name','=',Auth::user()->primary_dpt)->first();
$dept = App\Model\helpdesk\Agent\Department::where('id','=',Auth::user()->primary_dpt)->first();
$tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('assigned_to', '>', 0)->where('dept_id','=',$dept->id)->orderBy('id', 'DESC')->paginate(20);
} else {
$tickets = App\Model\helpdesk\Ticket\Tickets::where('status', '=', 1)->where('assigned_to', '>', 0)->orderBy('id', 'DESC')->paginate(20);