Commit 2fb7abeb by Azhan Hannan

dashboard staff, pm, pmhod -> comment current year, display status 2,3,5,6

parent 48f027ec
...@@ -184,9 +184,9 @@ class DashboardController extends Controller ...@@ -184,9 +184,9 @@ class DashboardController extends Controller
->get(); ->get();
// dd($profile); // dd($profile);
$staffnotes = Tproject::where('tp_project_type', 3) $staffnotes = Tproject::where('tp_project_type', 3)
->where('tp_timesheet_sts','<>', 1) ->whereIn('tp_timesheet_sts', [2,3,5,6])
->where('staffid', $verifier->u_staffID) ->where('staffid', $verifier->u_staffID)
->where('tp_year', date('Y')) // ->where('tp_year', date('Y'))
->with('notes') ->with('notes')
->get(); ->get();
...@@ -205,15 +205,15 @@ class DashboardController extends Controller ...@@ -205,15 +205,15 @@ class DashboardController extends Controller
->u_staffID; ->u_staffID;
$timesheet = Ts_master::where('tm_staff_id', $staffid) $timesheet = Ts_master::where('tm_staff_id', $staffid)
->where('tm_timesheet_master_sts', '<>', 1) ->whereIn('tm_timesheet_master_sts', [2,3,5,6])
->orderby('tm_year') ->orderby('tm_year')
->orderby('tm_month', 'DESC') ->orderby('tm_month', 'DESC')
->orderby('tm_phase', 'DESC') ->orderby('tm_phase', 'DESC')
->get(); ->get();
$projects = Tproject::where('staffid', $staffid) $projects = Tproject::where('staffid', $staffid)
->where('tp_year', date('Y')) // ->where('tp_year', date('Y'))
->where('tp_timesheet_sts', '<>', 1) ->whereIn('tp_timesheet_sts', [2,3,5,6])
->with('project') ->with('project')
->with('overhead') ->with('overhead')
->with('hod') ->with('hod')
...@@ -239,9 +239,9 @@ class DashboardController extends Controller ...@@ -239,9 +239,9 @@ class DashboardController extends Controller
->get(); ->get();
// dd($profile); // dd($profile);
$staffnotes = Tproject::where('tp_project_type', 3) $staffnotes = Tproject::where('tp_project_type', 3)
// ->where('tp_timesheet_sts','<>', 1) ->whereIn('tp_timesheet_sts', [2,3,5,6])
->where('staffid', $verifier->u_staffID) ->where('staffid', $verifier->u_staffID)
->where('tp_year', date('Y')) // ->where('tp_year', date('Y'))
->with('notes') ->with('notes')
->get(); ->get();
// dd($staffnotes); // dd($staffnotes);
...@@ -268,15 +268,15 @@ class DashboardController extends Controller ...@@ -268,15 +268,15 @@ class DashboardController extends Controller
->u_staffID; ->u_staffID;
$timesheet = Ts_master::where('tm_staff_id', $staffid) $timesheet = Ts_master::where('tm_staff_id', $staffid)
->where('tm_timesheet_master_sts', '<>', 1) ->whereIn('tm_timesheet_master_sts', [2,3,5,6])
->orderby('tm_year') ->orderby('tm_year')
->orderby('tm_month', 'DESC') ->orderby('tm_month', 'DESC')
->orderby('tm_phase', 'DESC') ->orderby('tm_phase', 'DESC')
->get(); ->get();
$projects = Tproject::where('staffid', $staffid) $projects = Tproject::where('staffid', $staffid)
->where('tp_year', date('Y')) // ->where('tp_year', date('Y'))
->where('tp_timesheet_sts', '<>', 1) ->whereIn('tp_timesheet_sts', [2,3,5,6])
->with('project') ->with('project')
->with('overhead') ->with('overhead')
->with('hod') ->with('hod')
...@@ -299,15 +299,15 @@ class DashboardController extends Controller ...@@ -299,15 +299,15 @@ class DashboardController extends Controller
$staffs = Staff_info::where('status', 1)->get(); $staffs = Staff_info::where('status', 1)->get();
// dd($staffs); // dd($staffs);
$timesheet = Ts_master::where('tm_staff_id', $staffid) $timesheet = Ts_master::where('tm_staff_id', $staffid)
->where('tm_timesheet_master_sts', '<>', 1) ->whereIn('tm_timesheet_master_sts', [2,3,5,6])
->orderby('tm_year') ->orderby('tm_year')
->orderby('tm_month', 'DESC') ->orderby('tm_month', 'DESC')
->orderby('tm_phase', 'DESC') ->orderby('tm_phase', 'DESC')
->get(); ->get();
$projects = Tproject::where('staffid', $staffid) $projects = Tproject::where('staffid', $staffid)
->where('tp_year', date('Y')) // ->where('tp_year', date('Y'))
->where('tp_timesheet_sts', '<>', 1) ->whereIn('tp_timesheet_sts', [2,3,5,6])
->with('project') ->with('project')
->with('overhead') ->with('overhead')
->with('hod') ->with('hod')
...@@ -316,9 +316,9 @@ class DashboardController extends Controller ...@@ -316,9 +316,9 @@ class DashboardController extends Controller
// dd($projects); // dd($projects);
$staffnotes = Tproject::where('tp_project_type', 3) $staffnotes = Tproject::where('tp_project_type', 3)
->where('tp_timesheet_sts','<>', 1) ->whereIn('tp_timesheet_sts', [2,3,5,6])
->where('staffid', $staffid) ->where('staffid', $staffid)
->where('tp_year', date('Y')) // ->where('tp_year', date('Y'))
->with('notes') ->with('notes')
->get(); ->get();
// dd($staffnotes); // dd($staffnotes);
...@@ -335,7 +335,7 @@ class DashboardController extends Controller ...@@ -335,7 +335,7 @@ class DashboardController extends Controller
->get(); ->get();
// dd($profile); // dd($profile);
$details = Tproject::where('tp_project_type', 3) $details = Tproject::where('tp_project_type', 3)
->where('tp_timesheet_sts','<>', 1) ->whereIn('tp_timesheet_sts', [2,3,5,6])
->where('tp_pm', $verifier->id) ->where('tp_pm', $verifier->id)
->with('notes') ->with('notes')
->get(); ->get();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment