Commit 10cbb645 by hannan

coding checking before update to dev

parent b2b277ba
......@@ -103,7 +103,7 @@ input[type=number] {
->where('tm_phase',$phase)
->first();
$total += $valuehour->td_hours;
$total += data_get($valuehour,'td_hours');
}
?>
......
......@@ -130,7 +130,7 @@ input[type=number] {
->where('tm_phase',$phase)
->first();
$total += $valuehour->td_hours;
$total += data_get($valuehour,'td_hours');
}
?>
......
......@@ -58,7 +58,7 @@ input[type=number] {
</th>
</tr>
<tr>
<th class="single line">Project Name</th>
<th class="single line">Task</th>
@if($phase == 1)
@for($i = 0; $i < 15 ; $i++)
......
......@@ -634,7 +634,7 @@ class DashboardController extends Controller
//update hours to null
$checkTimesheetDetail->td_hours = $valuehour;
$checkTimesheetDetail->updated_by = $userI;
$checkTimesheetDetail->updated_by = $userId;
$checkTimesheetDetail->update();
} //kalau takde, isi semua.
......@@ -645,7 +645,7 @@ class DashboardController extends Controller
$tmdetail->td_date = $date;
$tmdetail->td_project = $projectid;
$tmdetail->fk_tm_id = $tmasterid;
$tmdetail->tm_staff_id = $userI;
$tmdetail->tm_staff_id = $userId;
$tmdetail->tm_month = $check->tm_month;
$tmdetail->tm_year = $check->tm_year;
$tmdetail->tm_phase = $check->tm_phase;
......@@ -656,7 +656,7 @@ class DashboardController extends Controller
$tmdetail->td_project_name = $project->p_project_description;
$tmdetail->td_hours = $valuehour;
$tmdetail->updated_by = $userI;
$tmdetail->updated_by = $userId;
$tmdetail->save();
//$tmdetail -> kjhdiwhdf;
......@@ -696,7 +696,7 @@ class DashboardController extends Controller
->u_staffID;
// check table master. untuk total chargeable hours.
$check = Ts_master::where('tm_staff_id', $userI)
$check = Ts_master::where('tm_staff_id', $userId)
->where('tm_year', $request->year)
->where('tm_month', $request->month)
->where('tm_phase', $request->phase)
......@@ -713,11 +713,11 @@ class DashboardController extends Controller
else
{
$check = new Ts_master;
$check->tm_staff_id = $userI;
$check->tm_staff_id = $userId;
$check->tm_year = $request->year;
$check->tm_month = $request->month;
$check->tm_phase = $request->phase;
$check->updated_by = $userI;
$check->updated_by = $userId;
// $check ->tm_chargeable_hrs = ;
$check->save();
......@@ -756,7 +756,7 @@ class DashboardController extends Controller
//update hours to null
$checkTimesheetDetail->td_hours = $valuehour;
$checkTimesheetDetail->updated_by = $userI;
$checkTimesheetDetail->updated_by = $userId;
$checkTimesheetDetail->update();
} //kalau takde, isi semua.
......@@ -767,12 +767,12 @@ class DashboardController extends Controller
$tmdetail->td_date = $date;
$tmdetail->fk_o_id = $projectid;
$tmdetail->fk_tm_id = $tmasterid;
$tmdetail->tm_staff_id = $userI;
$tmdetail->tm_staff_id = $userId;
$tmdetail->tm_month = $check->tm_month;
$tmdetail->tm_year = $check->tm_year;
$tmdetail->tm_phase = $check->tm_phase;
$tmdetail->td_project_type = $overhead;
$tmdetail->updated_by = $userI;
$tmdetail->updated_by = $userId;
$project = Overhead::where('id', $projectid)
->first();
......@@ -841,7 +841,7 @@ class DashboardController extends Controller
$data = new Overhead;
$data->o_overhead_desc = $request->overheadlookup;
$data->o_overhead_sts = $request->status;
$data->updated_by = $userI;
$data->updated_by = $userId;
$data->save();
return redirect()->route('timesheet::dashboard.senaraiOverhead')
......
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