mirror of
https://github.com/donpat1to/Schichtenplaner.git
synced 2025-12-01 06:55:45 +01:00
added shiftplan generating logic
This commit is contained in:
@@ -12,13 +12,13 @@ const getAuthHeaders = () => {
|
||||
};
|
||||
|
||||
export class EmployeeService {
|
||||
async getEmployees(): Promise<Employee[]> {
|
||||
async getEmployees(includeInactive: boolean = false): Promise<Employee[]> {
|
||||
console.log('🔄 Fetching employees from API...');
|
||||
|
||||
const token = localStorage.getItem('token');
|
||||
console.log('🔑 Token exists:', !!token);
|
||||
|
||||
const response = await fetch(`${API_BASE_URL}/employees`, {
|
||||
const response = await fetch(`${API_BASE_URL}/employees?includeInactive=${includeInactive}`, {
|
||||
headers: getAuthHeaders(),
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user