feat(real-data): carga dinamica de workstations y tickets/movimientos reales desde SQL Server
This commit is contained in:
@@ -51,4 +51,10 @@ export const accessApi = {
|
||||
body: JSON.stringify({ raw_data: rawData }),
|
||||
});
|
||||
},
|
||||
|
||||
getRecentMovements: (limit: number = 30) => {
|
||||
return request<any[]>(`/access/movements/recent?limit=${limit}`, {
|
||||
method: 'GET',
|
||||
});
|
||||
},
|
||||
};
|
||||
|
||||
@@ -4,10 +4,21 @@
|
||||
import { request } from './client';
|
||||
import { WorkstationConfig } from '../types';
|
||||
|
||||
export interface WorkstationListItem {
|
||||
id: number;
|
||||
name: string;
|
||||
}
|
||||
|
||||
export const workstationApi = {
|
||||
getConfig: (workstationName: string) => {
|
||||
return request<WorkstationConfig>(`/control-posts/${encodeURIComponent(workstationName)}/config`, {
|
||||
method: 'GET',
|
||||
});
|
||||
},
|
||||
|
||||
getAvailableWorkstations: () => {
|
||||
return request<WorkstationListItem[]>('/control-posts/workstations', {
|
||||
method: 'GET',
|
||||
});
|
||||
},
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user