- Added CreateOrderDto and CreateOrderItemDto for order creation.
- Developed PosOrdersController to handle order-related endpoints.
- Created PosOrdersService for business logic related to orders.
- Implemented PosOrdersWorkflow for order processing workflows.
- Established Prisma integration for database operations in orders.
- Introduced SalesInvoicesModule and related DTOs for sales invoice management.
- Enhanced SalesInvoicesService and SalesInvoicesWorkflow for invoice processing.
- Removed old DTOs for creating and updating purchase receipts.
- Updated purchase receipts controller and service to use new DTOs and workflows.
- Introduced transaction helper for managing database transactions.
- Added new workflows for handling purchase receipt payments and supplier ledgers.
- Implemented new logic for managing purchase receipt items and payments.
- Enhanced error handling for payment processing in workflows.
- Updated supplier ledger management to reflect changes in purchase receipts.
feat(pos): update sale invoice creation to include customer and item details
feat(pos): enhance POS account service to include today's sales information
feat(pos): refactor order DTO to create sale invoice with detailed item structure
feat(products): add minimum stock alert level to product creation and update DTOs
fix(triggers): implement stock validation and movement logging for sales invoice items
refactor(database): update sales invoices schema to include posAccountId and remove inventoryId
- Removed old supplier DTOs and controller, replacing them with new implementations.
- Introduced new CreateSupplierDto and UpdateSupplierDto in the index directory.
- Updated SuppliersController to handle new routes and methods.
- Implemented SuppliersService with updated logic for creating, finding, updating, and removing suppliers.
- Added new invoices module with corresponding controller and service for handling invoice-related operations.
- Created new DTOs for handling receipt payments and updated the service to manage payment creation and retrieval.
- Updated Prisma migrations to reflect changes in the database schema, including dropping unnecessary columns.
feat: enhance PosAccountsService to include inventoryBankAccount details in responses
refactor: modify PosService to return structured inventory and bank account data
chore: remove isSettled field from CreatePurchaseReceiptDto and adjust related logic
feat: add payments selection in SuppliersService for better payment tracking
chore: apply database migrations to adjust decimal types and enforce constraints
chore: create index on Pos_Accounts for improved query performance
feat: define Supplier and SupplierLedger models in Prisma schema for better data management
refactor(migration): update Stock_Movements table to include counterInventoryId and customerId, add foreign key constraints, and implement triggers for inventory management
feat(pos): add POS controller and service for order creation and stock retrieval
refactor(pos): enhance stock and product category retrieval with pagination and mapping
- Created initial database schema with tables for Users, Roles, Products, and related entities.
- Added foreign key constraints to maintain data integrity across tables.
- Implemented triggers for managing stock movements on insert, update, and delete operations.
- Developed scripts to dump existing triggers and pull trigger definitions from the database.