fix dashboard

pull/1/head
Aji Kamaludin 3 years ago
parent da21d7c4aa
commit 38f2702d1d
No known key found for this signature in database
GPG Key ID: 670E1F26AD5A8099

@ -40,7 +40,9 @@ class DashboardController extends Controller
->get(); ->get();
$products = PayrollItem::selectRaw('product_id, SUM(quantity) as count') $products = PayrollItem::selectRaw('product_id, SUM(quantity) as count')
->whereBetween(DB::raw('DATE(created_at)'), [$startDate, $endDate]) ->whereHas('payroll', function ($query) use ($startDate, $endDate) {
return $query->whereBetween('date', [$startDate, $endDate]);
})
->groupBy('product_id') ->groupBy('product_id')
->with(['product']) ->with(['product'])
->get(); ->get();

18
public/css/app.css vendored

@ -1856,14 +1856,14 @@ html {
margin-left: auto; margin-left: auto;
margin-right: auto; margin-right: auto;
} }
.mx-1 {
margin-left: 0.25rem;
margin-right: 0.25rem;
}
.my-auto { .my-auto {
margin-top: auto; margin-top: auto;
margin-bottom: auto; margin-bottom: auto;
} }
.mx-1 {
margin-left: 0.25rem;
margin-right: 0.25rem;
}
.my-2 { .my-2 {
margin-top: 0.5rem; margin-top: 0.5rem;
margin-bottom: 0.5rem; margin-bottom: 0.5rem;
@ -1987,9 +1987,6 @@ html {
.max-h-96 { .max-h-96 {
max-height: 24rem; max-height: 24rem;
} }
.max-h-11 {
max-height: 2.75rem;
}
.min-h-screen { .min-h-screen {
min-height: 100vh; min-height: 100vh;
} }
@ -2367,12 +2364,12 @@ html {
.pb-8 { .pb-8 {
padding-bottom: 2rem; padding-bottom: 2rem;
} }
.pl-2 {
padding-left: 0.5rem;
}
.pb-4 { .pb-4 {
padding-bottom: 1rem; padding-bottom: 1rem;
} }
.pl-2 {
padding-left: 0.5rem;
}
.text-left { .text-left {
text-align: left; text-align: left;
} }
@ -2610,6 +2607,7 @@ html {
} }
} }
.react-datepicker-popper { .react-datepicker-popper {
inset: 0px 0px auto auto !important;
z-index: 40; z-index: 40;
width: 18rem; width: 18rem;
border-radius: 0.25rem; border-radius: 0.25rem;

@ -6,6 +6,7 @@
} }
.react-datepicker-popper { .react-datepicker-popper {
inset: 0px 0px auto auto !important;
@apply z-40 w-72 text-sm bg-white shadow px-3 py-2 border-2 border-gray-200 rounded; @apply z-40 w-72 text-sm bg-white shadow px-3 py-2 border-2 border-gray-200 rounded;
} }

Loading…
Cancel
Save