- Created a new component for managing warehouse inventory exits (WarehouseOutInventory.vue). - Implemented inventory movement services to handle API requests for inventory movements. - Added new interfaces for inventory movements and stock management. - Updated routing to include the new inventory exit page. - Enhanced existing services to support inventory exit functionality. - Added validation and user feedback for inventory exit operations.
16 lines
643 B
TypeScript
16 lines
643 B
TypeScript
import api from "@/services/api";
|
|
import type { InventoryMovementsPaginatedResponse } from "../types/inventory-movements.interfaces";
|
|
|
|
export class InventoryMovementsServices {
|
|
|
|
async getInventoryMovements(warehouse: number): Promise<InventoryMovementsPaginatedResponse> {
|
|
try {
|
|
const response = await api.get(`/api/inventory-movements?warehouse=${warehouse}`);
|
|
console.log('📦 Inventory Movements response:', response.data);
|
|
return response.data;
|
|
} catch (error) {
|
|
console.error('❌ Error fetching inventory movements:', error);
|
|
throw error;
|
|
}
|
|
}
|
|
} |