Browse Source

[Refactor] Disable Log Info

Dev-Fuad
Fuad Hadisurya 5 months ago
parent
commit
17970a63c6
  1. 10
      app/Console/Commands/ScheduleHealth.php
  2. 2
      app/Http/Controllers/DashboardBoDController.php

10
app/Console/Commands/ScheduleHealth.php

@ -42,13 +42,13 @@ class ScheduleHealth extends Command
public function handle()
{
echo "\n------------------------------------------\n";
echo "Command Start. \n";
Log::info("Command Start.");
// echo "\n------------------------------------------\n";
// echo "Command Start. \n";
// Log::info("Command Start.");
$projects = Project::get();
$totalProjects = $projects->count();
$updatedProjects = [];
Log::info($totalProjects);
// Log::info($totalProjects);
foreach ($projects as $index => $project) {
$project->scurve = MasterFunctionsHelper::getSCurve($project->id);
@ -62,7 +62,7 @@ class ScheduleHealth extends Command
$scheduleHealth = ($selisihProgress > 0 && $selisihProgress <= 20) ? 'warning' : (($selisihProgress == 0) ? 'on-schedule' : 'behind-schedule');
Log::info("Updating project with ID: " . $project->id . " - Schedule Health: " . $scheduleHealth);
// Log::info("Updating project with ID: " . $project->id . " - Schedule Health: " . $scheduleHealth);
$project->update(['schedule_health' => $scheduleHealth]);
$updatedProjects[] = $project->id;
}

2
app/Http/Controllers/DashboardBoDController.php

@ -43,7 +43,7 @@ class DashboardBoDController extends Controller
DB::raw('SUM(CAST(COALESCE(NULLIF(REPLACE(income_year, \'.\', \'\'), \'\'), \'0\') AS DOUBLE PRECISION)) AS total_income_year')
)->first();
$projects = Project::get();
Log::info(['dataTotal' => $totalBudgets]);
// Log::info(['dataTotal' => $totalBudgets]);
} else {
$totalBudgets = Project::where('created_by_id', $hierarchy)
->select(

Loading…
Cancel
Save