diff --git a/src/app/(dashboard)/absensi/page.tsx b/src/app/(dashboard)/absensi/page.tsx index 5bcfc9e..059f7d7 100644 --- a/src/app/(dashboard)/absensi/page.tsx +++ b/src/app/(dashboard)/absensi/page.tsx @@ -59,13 +59,13 @@ export default function AbsensiPage() {
-
Kehadiran Non Staff
+
Kehadiran Pemanen
Data belum tersedia
-
Kehadiran Non Staff
+
Kehadiran Perawatan
Data belum tersedia
diff --git a/src/app/(dashboard)/layout.tsx b/src/app/(dashboard)/layout.tsx index 67225e6..ed9b6ad 100644 --- a/src/app/(dashboard)/layout.tsx +++ b/src/app/(dashboard)/layout.tsx @@ -22,6 +22,7 @@ export default function DashboardLayout({children}:{children: React.ReactNode}) const dispatch = useAppDispatch(); const filter = useAppSelector((state) => state.filter.filter); const {data: filterOptions } = useGetFilterOptionsQuery(filter); + const [region, setRegion] = React.useState(""); return (
@@ -32,7 +33,7 @@ export default function DashboardLayout({children}:{children: React.ReactNode})
Halaman
- + @@ -103,20 +104,34 @@ export default function DashboardLayout({children}:{children: React.ReactNode}) onChange={(date) => dispatch(setFilter({...filter, end_date: format(date ?? new Date(), "yyyy-MM-dd")}))} />
-
+
option.name} renderInput={(params) => } - onChange={(e, value) => dispatch(setFilter({...filter, organization_code: value?.codes ?? ""}))} + onChange={(e, value) => { + dispatch(setFilter({...filter, organization_code: value?.codes ?? ""})); + setRegion(value?.codes ?? ""); + }} + /> + option.name} + renderInput={(params) => } + onChange={(e, value) => { + dispatch(setFilter({...filter, organization_code: value?.code ?? ""})); + if (value?.code == undefined) dispatch(setFilter({...filter, organization_code: region})); + }} + /> + option.name} + renderInput={(params) => } + onChange={(e, value) => dispatch(setFilter({...filter, estate_name: value?.name ?? ""}))} /> - - Semua Lokasi - Lokasi 1 - Lokasi 2 - Lokasi 3 -
dispatch(setFilter({...filter, job_name: e.target.value}))}> diff --git a/src/app/(dashboard)/turnover/page.tsx b/src/app/(dashboard)/turnover/page.tsx index 3f39f0b..25d8c8f 100644 --- a/src/app/(dashboard)/turnover/page.tsx +++ b/src/app/(dashboard)/turnover/page.tsx @@ -159,7 +159,7 @@ export default function TurnoverPage() {
-
Jenis Pemutusan Hubungan Kerja
+
Alasan Pemutusan Hubungan Kerja
{resignReason && resignReason.map((resign, index) => (
diff --git a/src/services/api.ts b/src/services/api.ts index a2c53d8..6bff3bb 100644 --- a/src/services/api.ts +++ b/src/services/api.ts @@ -3,7 +3,7 @@ import { AttendanceRange, AttendanceSummary, EmployeeSummary, FilterOptions, Mon import { Response , Filter} from './types' export const api = createApi({ - baseQuery: fetchBaseQuery({ baseUrl: 'http://localhost:8080' }), + baseQuery: fetchBaseQuery({ baseUrl: 'https://erp.julongindonesia.com:8443/api' }), endpoints: (builder) => ({ getFilterOptions: builder.query({ query: (params) => ({ url: '/dashboard/filter-options', params }),