Introduces the ability to validate a stock reception by sending updated move line quantities to the backend.
This includes:
- Adding a new API call to update stock picking move lines.
- Integrating a "Validate Reception" button within the quick actions component on the reception details page.
- Implementing the logic to gather move line data and call the new API endpoint.
- Enhancing error messages on the scan page for products not expected in the current reception.
- Improving type safety for API response data.
Introduces an `isDraft` property to `StockPickingRecordEntity` to mark receptions with local modifications.
Automatically sets a reception to draft status when a product's quantity is incremented via scanning. Displays a 'Brouillon' chip on reception cards to provide visual feedback for draft operations.
Ensures reception details are refreshed after scanning to reflect the updated draft status and provides immediate error feedback when no product is found during a scan.
Adds pull-to-refresh functionality to the reception details page, allowing users to manually update the displayed information.
Ensures that when a product is scanned, both the move line and the main move entities have their quantities correctly incremented, improving data consistency.
Replaces the generic scanner route with a dedicated reception scanning page.
This change ensures the scanning process initiated from reception details is context-aware by passing the reception ID directly to the new `ReceptionScanPage`. This provides a more tailored and efficient workflow for reception operations.
Enables offline capabilities and improved data access for stock picking records.
API calls now prioritize local ObjectBox storage when offline and persist fetched data upon successful remote retrieval.
Introduces comprehensive model-to-entity conversion logic for stock picking data and its related models.
Updates UI components and state management to directly consume ObjectBox entities, optimizing data display and interaction.
Adjusts ObjectBox entity schema for improved flexibility and adds utility getters.
Moves `StockPickingCompanyModel`, `StockPickingPartnerModel`,
`StockPickingLocationModel`, and `StockPickingTypeModel` to
`stock_picking_record_model.dart`. This consolidates related schema
definitions for improved organization and clarity.
Enables the floating action button on the reception details page
to navigate to the scanner route, streamlining the workflow.
Improves JSON deserialization for product and stock picking models by
using custom `fromJson` methods and explicit `JsonKey` mappings.
This ensures robust parsing of fields like barcode, display name, and product IDs.
Adds a new `ecart` getter to calculate the difference between requested
and received quantities for stock moves.
Updates the reception details page to display a list of products
with their requested, received, and calculated difference quantities.
Removes redundant JSON-RPC fields from the `stock.picking/web_read` API call.
Refactors the product data model to primarily store `id`, `barcode`, and `displayName`. This simplifies the product structure, focusing on essential attributes for inventory and scanning operations.
Optimizes API calls for stock picking to fetch more relevant product details. Unnecessary fields are removed, and specific product attributes like `barcode` and `quantity` are now explicitly requested for stock moves.
Moves `StockPickingRecordModel` to its own dedicated file for improved code organization and maintainability. Updates all affected UI components and scanner logic to align with the revised product model.
Introduces an `isDone` extension property for stock picking records to simplify status checks.
Enhances the `StockPickingCard` to visually represent the picking's completion status with a distinct icon and color (green for 'done', grey for 'in progress'), improving clarity at a glance. Information row values are now consistently uppercased.
Conditionally displays scan-related actions (QuickActionComponent and FloatingActionButton) in the reception details page, making them available only when the picking is not yet completed. This guides users by preventing interactions on finished operations.
Performs a comprehensive project rename from 'barcode_scanner' to 'e_scan' (or 'eScan' for user-facing labels). This update spans all relevant files, including:
- Application IDs and bundle identifiers for Android, iOS, macOS, and Linux.
- VS Code launch configurations.
- Dart package import paths.
- Project names and titles in `pubspec.yaml`, `README.md`, and platform-specific configurations (e.g., CMakeLists, Info.plist, AndroidManifest).
Implements a dedicated page for viewing detailed stock picking information.
- Introduces `getStockPikingById` API call to fetch a single stock picking record by ID.
- Enhances `MainAppbarComponent` to support customizable leading widgets, enabling a back button on detail pages.
- Improves `QuickActionComponent` by allowing optional `onTap` callbacks for actions, making buttons conditionally visible and reusable across different contexts.
- Adds `margin` property to `StockPickingCard` for flexible layout adjustments.
- Refactors `ReceptionDetailsPage` to utilize the new API call and display a single stock picking's details, adapting its app bar and quick actions accordingly.
Updates the sign-in API endpoint to `/simpos/v1/sign_in`.
Captures the `set-cookie` header from successful sign-in responses and stores it as a `sessionId`.
Persists the session ID using secure storage and includes it in subsequent API requests via the `Cookie` header for improved session management.
Extends the `AuthModel` to include the new `sessionId` field.
Enables navigation from the reception list to a new reception details page, passing the selected reception's ID.
Refactors the `StockPickingCard` into a dedicated component and adds loading indicators to the reception list.